https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69718
Bug ID: 69718 Summary: [concepts] cc1plus segfault on invalid Product: gcc Version: 6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: lucdanton at free dot fr Target Milestone: --- The testcase was mechanically reduced. $ g++-trunk --version g++-trunk (GCC) 6.0.0 20160208 (experimental) Copyright (C) 2016 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. $ cat main.cpp template<typename Type> concept bool Concept = requires { Type { 0 }; }; struct foo { typename foo(Init) requires Concept<foo> { foo { $ g++-trunk -std=c++1z main.cpp main.cpp:3:14: error: expected nested-name-specifier before 'foo' typename foo(Init) requires Concept<foo> { ^~~ main.cpp:3:18: error: 'Init' has not been declared typename foo(Init) requires Concept<foo> { ^~~~ main.cpp:4:13: error: expected '}' at end of input foo { ^ g++-trunk: internal compiler error: Segmentation fault (program cc1plus) Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions.