https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89480
Bug ID: 89480 Summary: internal compiler error: in unify, at cp/pt.c:22160 with the template argument force conversion. Product: gcc Version: 8.3.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: kutdanila at yandex dot ru Target Milestone: --- Created attachment 45807 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=45807&action=edit Source file Command line `g++ test.cpp -o test` Source file is attached The code itself: template <typename Foo, Foo Part> struct TSelect {}; enum What { The }; template <typename Foo> struct AnotherOneSelector { static constexpr Foo Id = Foo::The; }; template <typename Foo, typename SelectPartType> struct THelper; template <typename Foo> struct THelper<Foo, TSelect<Foo, Foo{AnotherOneSelector<Foo>::Id}>> {}; int main() { THelper<What, TSelect<What, What::The>> t; }