http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48211
Summary: [C++0x] Segment Fault When Compiling Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: critical Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: neur...@bitfoc.us Created attachment 23729 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=23729 source file and temp file. Source file that leads to crash is in attachment, named as function.cpp, along with temp files function. ii and function.s The following is what I did to compile the source and the output by the compiler. $ gcc -std=c++0x function.cpp In file included from /usr/local/lib/gcc/i686-pc-cygwin/4.7.0/../../../../include/c++/4.7.0/memory:85:0, from function.cpp:2: /usr/local/lib/gcc/i686-pc-cygwin/4.7.0/../../../../include/c++/4.7.0/bits/unique_ptr.h: In instantiation of ‘constexpr std::unique_ptr<_Tp, _Dp>::unique_ptr() [with _Tp = const stmt_base, _Dp = std::default_delete<const stmt_base>]’: function.cpp:8:8: instantiated from ‘sptr<const stmt_base>’ function.cpp:28:33: instantiated from here /usr/local/lib/gcc/i686-pc-cygwin/4.7.0/../../../../include/c++/4.7.0/bits/unique_ptr.h:115:59: 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. The following is compiler and system info. $ gcc -v Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/i686-pc-cygwin/4.7.0/lto-wrapper.exe Target: i686-pc-cygwin Configured with: ./configure --enable-languages=c,c++,fortran,lto,objc Thread model: single gcc version 4.7.0 20110320 (experimental) (GCC)