#define BROKEN 1 int main( int argc, char *argv[] ) { int ints[] = { #if BROKEN [-1] = 5, #endif [0] = 6 }; return ints[0]; } The above was saved in a file called /tmp/foo.c [thayne@torch ecc_new]$ gcc -v -save-temps /tmp/foo.c -o /tmp/foo Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/3.3/specs Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --host=i386-redhat-linux Thread model: posix gcc version 3.3 20030615 (Red Hat Linux 3.3-7) /usr/lib/gcc-lib/i386-redhat-linux/3.3/cc1 -E -quiet -v -D__GNUC__=3 -D__GNUC_MINOR__=3 -D__GNUC_PATCHLEVEL__=0 /tmp/foo.c foo.i ignoring nonexistent directory "/usr/i386-redhat-linux/include" #include "..." search starts here: #include <...> search starts here: /usr/local/include /usr/lib/gcc-lib/i386-redhat-linux/3.3/include /usr/include End of search list. /usr/lib/gcc-lib/i386-redhat-linux/3.3/cc1 -fpreprocessed foo.i -quiet -dumpbase foo.c -auxbase foo -version -o foo.s GNU C version 3.3 20030615 (Red Hat Linux 3.3-7) (i386-redhat-linux) compiled by GNU C version 3.3 20030615 (Red Hat Linux 3.3-7). GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 /tmp/foo.c: In function `main': /tmp/foo.c:7: internal compiler error: in tree_low_cst, at tree.c:3228 Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://bugzilla.redhat.com/bugzilla> for instructions. The bug is not reproduceable, so it is likely a hardware or OS problem Strangely, the bug is very reproduceable - contrary to the line above. A negative index for an array static initializer should produce an error message describing the problem - not an internal compiler error.
This is a dup of bug 11207 which is not fixed yet. *** This bug has been marked as a duplicate of 11207 ***