http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51660
Bug #: 51660 Summary: ICE on function missing argument list Classification: Unclassified Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: ca...@cs.stanford.edu g++ crashes on this (invalid) program: struct s { static int x {return 0;} }; Output: crashes/6.cpp:3:16: warning: extended initializer lists only available with -std=c++11 or -std=gnu++11 [enabled by default] crashes/6.cpp:3:19: error: expected primary-expression before ‘return’ crashes/6.cpp:3:19: error: expected ‘}’ before ‘return’ crashes/6.cpp:3:19: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions. How to run: g++ file.cpp Note that this program does not cause gcc to crash if compiled as C. Compiler version: Using built-in specs. COLLECT_GCC=/new-gcc/i-4.7/bin/g++ COLLECT_LTO_WRAPPER=/new-gcc/i-4.7/libexec/gcc/x86_64-unknown-linux-gnu/4.7.0/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ../s-4.7/configure --prefix=/new-gcc/i-4.7 Thread model: posix gcc version 4.7.0 20111223 (experimental) (GCC)