[Bug c++/20463] New: [4.0/4.1 regression] ICE on using undefined type
belyshev at depni dot sinp dot msu dot ru
gcc-bugzilla@gcc.gnu.org
Sun Mar 13 22:12:00 GMT 2005
This invalid code snippet produces ICE on mainline and 4.0 branch:
-------------------------------------------------------------------------------
template < typename T > struct C;
template < typename T > void C < T > :: f ()
{
const foo bar;
}
-------------------------------------------------------------------------------
foo.cc:3: error: invalid use of undefined type Âstruct C<T>Â
foo.cc:1: error: declaration of Âstruct C<T>Â
foo.cc:3: error: template definition of non-template Âvoid C<T>::f()Â
foo.cc: In member function Âvoid C<T>::f()Â:
foo.cc:5: error: Âfoo does not name a type
foo.cc:5: internal compiler error: Segmentation fault
--
Summary: [4.0/4.1 regression] ICE on using undefined type
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Keywords: ice-on-invalid-code, error-recovery
Severity: minor
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: belyshev at depni dot sinp dot msu dot ru
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20463
More information about the Gcc-bugs
mailing list