https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104278
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|ICE constexpr class |ICE with class non-type |non-type template parameter |template parameter with a | |value depdenent constexpr | |call Ever confirmed|0 |1 Last reconfirmed| |2022-01-29 Keywords| |ice-on-valid-code Status|UNCONFIRMED |NEW --- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Confirmed reduced testcase: struct foo { int value; }; constexpr foo modify(foo) { return { 0 }; } template<foo f, bool Enable = f.value> struct bar { static void run() { } }; template<foo f> static void run() { bar<modify(f)>::run(); } void h() { run<foo{}>(); } bar::run still needs to be in a templated class.