This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Static members in templates in egcs-1.0.1
- To: dhm at paradigm dot webvision dot com (dave madden)
- Subject: Re: Static members in templates in egcs-1.0.1
- From: Joe Buck <jbuck at synopsys dot com>
- Date: Thu, 15 Jan 98 12:58:13 PST
- Cc: mmitchell at usa dot net, egcs at cygnus dot com
> I've been trying to find out for a while: does the C++ spec allow you
> to define static consts in the class definition? Egcs & g++ do, but
> all the compilers I've tried on NT complain.
Yes (the standard does allow it), but it is a fairly recent change
(meaning that it isn't widely portable yet).
If you need your code to compile on a variety of C++ compilers I'm
afraid you can't use that feature yet.