[Bug c++/124414] [reflection] Invalid constexpr variable accepted with void pointer to consteval-only type
jakub at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Apr 22 21:59:29 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=124414
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Isn't https://eel.is/c++draft/expr.const#imm-2.3 what makes
constexpr auto a = ^^int;
const void *b = &a;
invalid? &a has consteval-only type, so it is immediately-escalating
expression.
More information about the Gcc-bugs
mailing list