This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Internal compiler error
- To: gcc-bugs at gcc dot gnu dot org
- Subject: Internal compiler error
- From: Erkki Seppala <flux at inside dot org>
- Date: Sun, 2 Jul 2000 18:10:15 +0300
Code: (*.cc-file)
template <class T> struct Bar { };
template <class T> struct Foo {
struct Baz;
};
template <class T>
struct Foo<T>::Baz :
public Bar<T> {
};
Produced *.ii-file is essentially the same.
Problem:
Command
gcc -v --save-temps gccbug.cc
produces
Reading specs from /usr/lib/gcc-lib/i386-linux/2.95.2/specs
gcc version 2.95.2 20000220 (Debian GNU/Linux)
/usr/lib/gcc-lib/i386-linux/2.95.2/cpp -lang-c++ -v -D__GNUC__=2 -D__GNUG__=2 -D__GNUC_MINOR__=95 -D__cplusplus -D__ELF__ -Dunix -D__i386__ -Dlinux -D__ELF__ -D__unix__ -D__i386__ -D__linux__ -D__unix -D__linux -Asystem(posix) -D__EXCEPTIONS -Acpu(i386) -Amachine(i386) -Di386 -D__i386 -D__i386__ gccbug.cc gccbug.ii
GNU CPP version 2.95.2 20000220 (Debian GNU/Linux) (i386 Linux/ELF)
#include "..." search starts here:
#include <...> search starts here:
/lhome/flux/include
/usr/lib/gcc-lib/i386-linux/2.95.2/../../../../include/g++-3
/usr/local/include
/usr/lib/gcc-lib/i386-linux/2.95.2/include
/usr/include
End of search list.
The following default directories have been omitted from the search path:
/usr/lib/gcc-lib/i386-linux/2.95.2/../../../../i386-linux/include
End of omitted list.
/usr/lib/gcc-lib/i386-linux/2.95.2/cc1plus gccbug.ii -quiet -dumpbase gccbug.cc -version -o gccbug.s
GNU C++ version 2.95.2 20000220 (Debian GNU/Linux) (i386-linux) compiled by GNU C version 2.95.2 20000220 (Debian GNU/Linux).
gccbug.cc:8: Internal compiler error.
gccbug.cc:8: Please submit a full bug report.
gccbug.cc:8: See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.
The obvious workaround is to move the definition to the actual
header file, but this creates a dependency.
--
_____________________________________________________________________
/ __// /__ ____ __ Erkki Seppälä\ \
/ /_ / // // /\ \/ //ircnet Inside Informatics ry\ /
/_/ /_/ \___/ /_/\_\@inside.org http://www.inside.org/~flux/