https://gcc.gnu.org/bugzilla/show_bug.cgi?id=48665

--- Comment #16 from Jonathan Wakely <redi at gcc dot gnu.org> ---
It's not valid.

[expr.typeid] p5 says typeid(cv T) is the same as typeid(T) but that isn't
relevant here. 'void () const' is not the cv-qualified version of 'void ()',
because there are no cv-qualified function types. See [dcl.fct] p7.

'void () const' is a function type with a cv-qualifier-seq and can only appear
in a few specific places, which does not include a typeid expression. See
[dcl.fct] p6.

Reply via email to