Inheritance in Templates

Hi,

I have a very basic question.
Does compiler while compiling template classes (template expansion by name decoration) understands inheritance.

//------Inheritance hierarchy--------
class base
{
.....
};
class derived: public base
{
.....
};

//----- Some template class-------
template <class T>
class templateClass
{
....
};

Will the compiler understand the following line of code
templateClass<base *> * pTemplateClass = new templateClass<derived *> () ;


closed account (S6k9GNh0)
Why don't you make an example and see?
Topic archived. No new replies allowed.