This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: c++/8149: internal error: Segmentation fault
- From: reichelt at igpm dot rwth-aachen dot de
- To: gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org, sneechy at hotmail dot com
- Date: 23 Oct 2002 20:36:47 -0000
- Subject: Re: c++/8149: internal error: Segmentation fault
- Reply-to: reichelt at igpm dot rwth-aachen dot de, gcc-bugs at gcc dot gnu dot org, gcc-prs at gcc dot gnu dot org, nobody at gcc dot gnu dot org, sneechy at hotmail dot com, gcc-gnats at gcc dot gnu dot org
Synopsis: internal error: Segmentation fault
State-Changed-From-To: open->analyzed
State-Changed-By: reichelt
State-Changed-When: Wed Oct 23 13:36:45 2002
State-Changed-Why:
Confirmed.
The example can be reduced a little bit further:
-------------------------snip here-------------------------
struct B { template <typename U> struct C; };
template <typename T> struct A { typedef typename T::C V; };
A<B>::V p;
-------------------------snip here-------------------------
Compiling this with "g++ -c" using the 3.2-branch or the main trunk
results in an ICE (checked on i686-pc-linux-gnu). With gcc 3.0.x or
2.95.x I get an error message:
PR8149.cc:3: aggregate `B::C<U> p' has incomplete type and cannot be
initialized
PR8149.cc:3: storage size of `p' isn't known
Changing "struct C;" to "struct C{};" in the first line to get rid of this
message (the rest of the code still remains illegal) causes gcc 3.0.x to
issue an ICE and 2.95.x to issue an assembler error.
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8149