http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55109
Bug #: 55109 Summary: internal compiler error: Segmentation fault while reporting error in template function instantiation Classification: Unclassified Product: gcc Version: 4.7.2 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: zetaetadan...@gmail.com The compiler command was: g++ -DHAVE_CONFIG_H -I. -O0 -g -std=c++11 -I src/ -Wall -Wextra -Werror -Wno-error=unused-variable -Wno-error=unused-parameter -Wno-error=unused-but-set-variable -MT mc___server-NetworkServer.o -MD -MP -MF .deps/mc___server-NetworkServer.Tpo -c -o mc___server-NetworkServer.o `test -f 'src/network/NetworkServer.cpp' || echo './'`src/network/NetworkServer.cpp The compiler output was (template stuff formatted for readability): In file included from src/network/NetworkServer.cpp:22:0: src/Scheduler.hpp: In instantiation of ‘typename std::enable_if< std::__and_< std::is_convertible< MemberFunc, std::function< decltype (MCServer::Scheduler::startThread::obj-> **MCServer::Scheduler::startThread::func( MCServer::Scheduler::startThread::args ... ) ) (Args ...) > >, std::is_member_function_pointer<MemberFunc> >::value, long unsigned int >::type MCServer::Scheduler::startImportantThread(MemberFunc&&, Class*, Args&& ...) [with MemberFunc = void (MCServer::Network::NetworkServer::*)(); Class = MCServer::Network::NetworkServer; Args = {}; typename std::enable_if< std::__and_< std::is_convertible< MemberFunc, std::function< decltype (MCServer::Scheduler::startThread::obj-> **MCServer::Scheduler::startThread::func( MCServer::Scheduler::startThread::args ... ) ) (Args ...) > >, std::is_member_function_pointer<MemberFunc> >::value, long unsigned int >::type = long unsigned int]’: src/network/NetworkServer.cpp:69:74: required from here src/Scheduler.hpp:187:156: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <https://bugs.archlinux.org/> for instructions. The backtrace of the segfault is: #0 0x00000000004e00e7 in ?? () #1 0x00000000004e0464 in tsubst_copy_and_build () #2 0x00000000004dbffa in ?? () #3 0x00000000004e7ddf in ?? () #4 0x00000000004e105b in tsubst_copy_and_build () #5 0x00000000004dbffa in ?? () #6 0x00000000004e28c0 in tsubst () #7 0x00000000004e881c in ?? () #8 0x00000000004e2ceb in tsubst () #9 0x00000000004e5b13 in ?? () #10 0x00000000004df422 in ?? () #11 0x00000000004e2ec9 in tsubst () #12 0x00000000004e0dac in tsubst_copy_and_build () #13 0x00000000004e0ffe in tsubst_copy_and_build () #14 0x00000000004dbffa in ?? () #15 0x00000000004dcd0f in ?? () #16 0x00000000004dcc4c in ?? () #17 0x00000000004dc118 in ?? () #18 0x00000000004f0da3 in instantiate_decl () #19 0x00000000004f37ac in instantiate_pending_templates () #20 0x000000000050979d in cp_write_global_declarations () #21 0x0000000000831a58 in toplev_main () #22 0x00007ffff5eca725 in __libc_start_main () from /usr/lib/libc.so.6 #23 0x00000000004abaf1 in _start () which is of course very incomplete, and I am currently compiling gcc with debug symbols to get a better backtrace, but it will take some time. The preprocessed source of the file being compiled is here: http://www.mediafire.com/?hdv6qddwnwclj82