------- Comment #2 from tor_rustad at hotmail dot com 2009-06-18 14:47 ------- (In reply to comment #1) > Works for me. > > gcc-4.2 --version > gcc-4.2 (GCC) 4.2.4 (Debian 4.2.4-6)
The seg fault happened with gcc version 4.2.4 (Ubuntu 4.2.4-1ubuntu3) unintentionally I left out two semicolons in the test case, the corrected test case is: $ cat test.c struct R { char c; }; struct R { struct R r; }; int main(void) { struct R r; return 0; } $ gcc test.c test.c:7: error: redefinition of struct R gcc: Internal error: Segmentation fault (program cc1) Please submit a full bug report. See <URL:http://gcc.gnu.org/bugs.html> for instructions. For Debian GNU/Linux specific bug reporting instructions, see <URL:file:///usr/share/doc/gcc-4.2/README.Bugs>. $ gcc -std=c89 test.c test.c:7: error: redefinition of struct R gcc: Internal error: Segmentation fault (program cc1) Please submit a full bug report. See <URL:http://gcc.gnu.org/bugs.html> for instructions. For Debian GNU/Linux specific bug reporting instructions, see <URL:file:///usr/share/doc/gcc-4.2/README.Bugs>. $ gcc -std=c99 test.c test.c:7: error: redefinition of struct R gcc: Internal error: Segmentation fault (program cc1) Please submit a full bug report. See <URL:http://gcc.gnu.org/bugs.html> for instructions. For Debian GNU/Linux specific bug reporting instructions, see <URL:file:///usr/share/doc/gcc-4.2/README.Bugs>. -- tor_rustad at hotmail dot com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tor_rustad at hotmail dot | |com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40476