Compile error: classes and typedefs

Martin v. Loewis martin@mira.isdn.cs.tu-berlin.de
Fri Jun 18 00:29:00 GMT 1999


> Isn't that strange ? Or is the code illegal ? Other compilers are
> happy with it.
>   Group group(Obj(Int(1)), Obj(Int(1)));

This is a well-known bug in egcs; egcs mistakes this for a declaration
of a variable Int of type Obj. The work around is simple

   Group group((Obj(Int(1))), Obj(Int(1)));

Regards,
Martin


More information about the Gcc-bugs mailing list