egcs 1.0.3 template and typedef bug

Alexandre Oliva
Thu Oct 1 21:34:00 GMT 1998

Pavlos Papageorgiou <> writes:

> It seems that egcs-1.0.3 does not support typedefs within classes
> that are used as template parameters.

Actually, it requires you to comply with the C++ Standard, and precede 
such template-dependent type names with the keyword `typename':

>         Traits::Integer i = 3;

 typename Traits::Integer i = 3; // this compiles fine

In some cases, it will recognize that you mean a type name, but not in 
this particular case.

Alexandre Oliva
Universidade Estadual de Campinas, SP, Brasil

More information about the Gcc-bugs mailing list