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

--- Comment #2 from terryinzaghi <terryinzaghi at 163 dot com> ---
(In reply to Jakub Jelinek from comment #1)
> Why do you think this is a bug?
> https://eel.is/c++draft/dcl.decl#dcl.fct-1.sentence-5
> says that the attribute-specifier-seq in your old{4,5,6,7} declarations
> appertains to the function type.
> And https://eel.is/c++draft/dcl.attr.deprecated#2 lists to what entities it
> may be applied, and function type is not one of those.
> GCC 15 will error on those 4 lines with -pedantic-errors, I think clang++
> rejects it by default.

thanks for the hint.

I will try GCC 15 with -pedantic-errors.

Reply via email to