dubious template friend => internal error 9
Mark Mitchell
mmitchell@usa.net
Sun Dec 7 14:58:00 GMT 1997
>>>>> "Anthony" == Anthony Heading <ajrh@woland.demon.co.uk> writes:
Anthony> Hi,
Anthony> This soi-disant "program":
Anthony> class A { template <class T> friend A& f<T>(); };
Anthony> when compiled with gcc version egcs-2.90.21 971202
Anthony> (egcs-1.00) under Linux
Anthony> c++ -c crash.c gives
Anthony> crash.c:1: Internal compiler error 9. crash.c:1: Please
Anthony> submit a full bug report to `egcs-bugs@cygnus.com'.
One of the patches I posted earlier today cause the following output
instead:
supernova% test-g++ -c test.cc
test.cc:1: specialization does not match any template declaration
test.cc:1: invalid member template declaration
which is at least an improvement.
--
Mark Mitchell mmitchell@usa.net
Stanford University http://www.stanford.edu
More information about the Gcc-bugs
mailing list