This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: g++ bug report (egcs-971016)
- To: egcs-bugs at cygnus dot com, naeher at infsn dot informatik dot uni-halle dot de
- Subject: Re: g++ bug report (egcs-971016)
- From: mrs at wrs dot com (Mike Stump)
- Date: Wed, 22 Oct 1997 15:18:07 -0700
While it would be nice to make g++ accept this with a warning, this
isn't exactly a deviation from the ANSI C++ standard.
> Date: Wed, 22 Oct 1997 17:34:37 +0200 (MET DST)
> From: Stefan Naeher <naeher@infsn.informatik.uni-halle.de>
> To: egcs-bugs@cygnus.com
> the following piece of code compiles with g++-2.7.2
> however, with g++ snapshot 971016 it produces the
> error message:
> bug.c: In function `void test(T &)':
> bug.c:17: parse error before `0'
> class xyz {
> typedef char* ptr_type;
> public:
> void func(ptr_type);
> };
> template<class T>
> void test(T& x) {
> x.func((T::ptr_type)0);
> }