https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104567
Jonathan Wakely <redi at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Known to fail| |12.0 --- Comment #4 from Jonathan Wakely <redi at gcc dot gnu.org> --- A testcase that shows the bug is a lot more useful than one that needs something uncommented to show the bug. template <typename _TAny, char const* value = _TAny::param> constexpr bool has_char_static_param(int) { return true; } template <typename _TAny> constexpr bool has_char_static_param(...) { return false; } struct works1 { constexpr static char param[] = "param"; }; struct works2 { constexpr static int param = 0; }; struct fails { char const* param; // not static }; static_assert(has_char_static_param<works1>(0), ""); static_assert(!has_char_static_param<works2>(0), ""); static_assert(!has_char_static_param<fails>(0), ""); // FAILS