From: khan AT xraylith DOT wisc DOT edu (Mumit Khan) Subject: (none) 2 Dec 1998 07:33:25 -0800 Message-ID: <199812011828.MAA26282.cygnus.gnu-win32@modi.xraylith.wisc.edu> References: <082566CC DOT 0080CE49 DOT 00 AT svdatsmtpmta DOT dp DOT beckman DOT com> To: "Jack A Walker" Cc: gnu-win32 AT cygnus DOT com "Jack A Walker" writes: > When I try to compile a test program that includes my lamer fixed capacity > string > template I get the following error from egcs: Thanks for the bug report. It's a bug in egcs-1.1, and still in the upcoming egcs-1.1.1 release. It has to do with the following construct: template struct Template { typedef char Foo [sz + 1]; // it's the ``+1'' that causes it. typedef char Foo2 [sz]; // OK }; I'll send a simplified testcase to the egcs folks. A temporary workaround is to use a static const size_t member and initialize that to `sz + 1' and use that in the typedef. btw, the identifier _String is reserved by the implementation and the compiler is not required to issue a diagnostic (and free to do anything it wants with your code ;-). See section 17.4.1.3 in the standard. Library reserved namespace: - any identifier prefixed with double underscore. - any identifier prefixed with a single underscore and followed by an uppercase letter. In addition, - each identifier that begins with an underscore is reserved to be used in the global namespace. So, please don't used names prefixed with _; you can always use _ suffix. Regards, Mumit - For help on using this list (especially unsubscribing), send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".