https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84798
Bug ID: 84798 Summary: ICE (Segmentation fault) if `auto` appears in a template argument Product: gcc Version: 8.0.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: v.reshetnikov at gmail dot com Target Milestone: --- The following C++ code causes an ICE in GCC 8.0.1 20180308 (tested with https://godbolt.org/): /********************** SOURCE **********************/ template<typename T> struct S { static constexpr T value = 0; }; constexpr auto x = S<void(*)(auto)>::value; /******************** END SOURCE ********************/ /********************** OUTPUT **********************/ <source>:6:38: internal compiler error: Segmentation fault constexpr auto x = S<void(*)(auto)>::value; ^~~~~ mmap: Invalid argument Please submit a full bug report, with preprocessed source if appropriate. See <https://gcc.gnu.org/bugs/> for instructions. Compiler returned: 1 /******************** END OUTPUT ********************/ The same problem appears to exist in all versions since GCC 6.1.