Bug 55583

Summary: g++3 segfault on example
Product: [Retired] Red Hat Linux Reporter: Neal D. Becker <nbecker>
Component: gcc3Assignee: Jakub Jelinek <jakub>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 8.0   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-10-02 00:47:37 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
TestRtoC.ii.bz2 none

Description Neal D. Becker 2001-11-02 14:53:47 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.2.1) Gecko/20010901

Description of problem:
g++3 -v -c -save-temps TestRtoC.cc -I/usr/local/src/boost
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/3.0.2/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--disable-checking --host=i386-redhat-linux
Thread model: posix
gcc version 3.0.2 20010905 (Red Hat Linux 7.1 3.0.1-3)
 /usr/lib/gcc-lib/i386-redhat-linux/3.0.2/cpp0 -lang-c++ -D__GNUG__=3
-D__GXX_DEPRECATED -D__EXCEPTIONS -D__GXX_ABI_VERSION=100 -v
-I/usr/local/src/boost -D__GNUC__=3 -D__GNUC_MINOR__=0
-D__GNUC_PATCHLEVEL__=2 -D__ELF__ -Dunix -Dlinux -D__ELF__ -D__unix__
-D__linux__ -D__unix -D__linux -Asystem=posix -D__NO_INLINE__
-D__STDC_HOSTED__=1 -D_GNU_SOURCE -Acpu=i386 -Amachine=i386 -Di386 -D__i386
-D__i386__ -D__tune_i386__ TestRtoC.cc TestRtoC.ii
GNU CPP version 3.0.2 20010905 (Red Hat Linux 7.1 3.0.1-3) (cpplib) (i386
Linux/ELF)
ignoring nonexistent directory "/usr/i386-redhat-linux/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/src/boost
 /usr/include/g++-v3
 /usr/include/g++-v3/i386-redhat-linux
 /usr/include/g++-v3/backward
 /usr/local/include
 /usr/lib/gcc-lib/i386-redhat-linux/3.0.2/include
 /usr/include
End of search list.
 /usr/lib/gcc-lib/i386-redhat-linux/3.0.2/cc1plus -fpreprocessed
TestRtoC.ii -quiet -dumpbase TestRtoC.cc -version -o TestRtoC.s
GNU CPP version 3.0.2 20010905 (Red Hat Linux 7.1 3.0.1-3) (cpplib) (i386
Linux/ELF)
GNU C++ version 3.0.2 20010905 (Red Hat Linux 7.1 3.0.1-3) (i386-redhat-linux)
	compiled by GNU C version 3.0.2 20010905 (Red Hat Linux 7.1 3.0.1-3).
In file included from TestRtoC.cc:1:
RtoC.H:111: Internal error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla/> for instructions.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.see above
2.
3.
	

Additional info:

Comment 1 Neal D. Becker 2001-11-02 14:59:54 UTC
Created attachment 36201 [details]
TestRtoC.ii.bz2

Comment 2 Jakub Jelinek 2001-11-07 18:05:03 UTC
It is ICE on wrong code, you're missing a typename there.
Anyway, the compiler shouldn't segfault, but give an error, so I'll try to debug
this.
Simplified testcase is:
template <class T> struct S {
  typedef typename T::t t;
};
template <class T> struct A
{
  typedef S<T>::t u;
  typedef u::t v;
};

Comment 3 Alan Cox 2002-12-15 18:07:00 UTC
Still present in g++ 3.2


Comment 4 Richard Henderson 2004-10-02 00:47:37 UTC
ICE fixed for gcc 3.4.