Correction to - Problem with "typename" in base class list

Will e1wwater@dingo.cc.uq.edu.au
Sun Feb 20 09:31:00 GMT 2000


Although handled previously by EGCS 1.1.x, GCC 2.95.2 cannot handle the
keyword "typename" within the base class list of a class definition.  To

see what I mean, try compiling the following:

class EncapClass
{
};

template <class A>
class BaseTemplate
{
public:
    typedef EncapClass
        Type;
};

template <class A, template <class B> class BaseTemp>
class DerivedTemplate :
public typename BaseTemp <A>::Type                    // Problem is
caused by this line
{
};

int main()
{
}







More information about the Gcc-bugs mailing list