Re: [PATCH] c++: constinit on pointer to function [PR104066]

2022-11-17 Thread Jason Merrill via Gcc-patches
On 11/17/22 13:38, Marek Polacek wrote: [dcl.constinit]: "The constinit specifier shall be applied only to a declaration of a variable with static or thread storage duration." Thus, this ought to be OK: constinit void (*p)() = nullptr; but the error message I introduced when implementing co

[PATCH] c++: constinit on pointer to function [PR104066]

2022-11-17 Thread Marek Polacek via Gcc-patches
[dcl.constinit]: "The constinit specifier shall be applied only to a declaration of a variable with static or thread storage duration." Thus, this ought to be OK: constinit void (*p)() = nullptr; but the error message I introduced when implementing constinit was not looking at funcdecl_p, so t