[4.6.2] problem compiling templates

Bogdan Slusarczyk Bogdan.Slusarczyk@aldec.com.pl
Tue Nov 29 14:03:00 GMT 2011


Hello everybody,

I noticed strange problem using gcc4.6.2, see please attached file.

Compiling this file I get:

In member function 'void Test<_enum>::foo()':
error: declaration of 'Predicate _enum'
error:  shadows template parm 'Enum _enum'

However it's enough to create intermediate object to avoid this problem 
(it also compiles ok with gcc3.4.3).

Am I doing wrong something here or this is known problem?

Regards,
Bogdan


-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: test.cpp
URL: <https://gcc.gnu.org/pipermail/gcc-help/attachments/20111129/fb000ddb/attachment.ksh>


More information about the Gcc-help mailing list