[Bug c++/93228] [[deprecated("message")]] on template struct/class drops message

2020-02-14 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93228

Jakub Jelinek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED
   Target Milestone|--- |8.4

--- Comment #7 from Jakub Jelinek  ---
Fixed on the trunk and all release branches.

[Bug c++/93228] [[deprecated("message")]] on template struct/class drops message

2020-02-14 Thread cvs-commit at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93228

--- Comment #6 from CVS Commits  ---
The releases/gcc-8 branch has been updated by Jakub Jelinek
:

https://gcc.gnu.org/g:ef2e6135591f2a197d4fb8a7dbb8425a9d2df85e

commit r8-10005-gef2e6135591f2a197d4fb8a7dbb8425a9d2df85e
Author: Jakub Jelinek 
Date:   Fri Feb 14 15:39:57 2020 +0100

c++: Fix deprecated attribute handling on templates (PR c++/93228)

As the following testcase shows, when deprecated attribute is on a
template,
we'd never print the message if any, because the attribute is not
present on the TEMPLATE_DECL with which warn_deprecated_use is called,
but on its DECL_TEMPLATE_RESULT or its type.

2020-01-17  Jakub Jelinek  

PR c++/93228
* parser.c (cp_parser_template_name): Look up deprecated attribute
in DECL_TEMPLATE_RESULT or its type's attributes.

* g++.dg/cpp1y/attr-deprecated-3.C: New test.

[Bug c++/93228] [[deprecated("message")]] on template struct/class drops message

2020-02-13 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93228

Jonathan Wakely  changed:

   What|Removed |Added

   See Also||https://gcc.gnu.org/bugzill
   ||a/show_bug.cgi?id=90515

--- Comment #5 from Jonathan Wakely  ---
PR 90515 has similar cases that still fail.

[Bug c++/93228] [[deprecated("message")]] on template struct/class drops message

2020-01-22 Thread cvs-commit at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93228

--- Comment #4 from CVS Commits  ---
The releases/gcc-9 branch has been updated by Jakub Jelinek
:

https://gcc.gnu.org/g:514314b73109b3672ecb3c3c04f614bb7c7fef57

commit r9-8163-g514314b73109b3672ecb3c3c04f614bb7c7fef57
Author: Jakub Jelinek 
Date:   Wed Jan 22 17:52:11 2020 +0100

c++: Fix deprecated attribute handling on templates (PR c++/93228)

As the following testcase shows, when deprecated attribute is on a
template,
we'd never print the message if any, because the attribute is not
present on the TEMPLATE_DECL with which warn_deprecated_use is called,
but on its DECL_TEMPLATE_RESULT or its type.

2020-01-17  Jakub Jelinek  

PR c++/93228
* parser.c (cp_parser_template_name): Look up deprecated attribute
in DECL_TEMPLATE_RESULT or its type's attributes.

* g++.dg/cpp1y/attr-deprecated-3.C: New test.

[Bug c++/93228] [[deprecated("message")]] on template struct/class drops message

2020-01-17 Thread cvs-commit at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93228

--- Comment #3 from CVS Commits  ---
The master branch has been updated by Jakub Jelinek :

https://gcc.gnu.org/g:c60a18f8056facdcf370ce0e5f51550c9df5b539

commit r10-6041-gc60a18f8056facdcf370ce0e5f51550c9df5b539
Author: Jakub Jelinek 
Date:   Fri Jan 17 15:22:22 2020 +0100

c++: Fix deprecated attribute handling on templates (PR c++/93228)

As the following testcase shows, when deprecated attribute is on a
template,
we'd never print the message if any, because the attribute is not
present on the TEMPLATE_DECL with which warn_deprecated_use is called,
but on its DECL_TEMPLATE_RESULT or its type.

2020-01-17  Jakub Jelinek  

PR c++/93228
* parser.c (cp_parser_template_name): Look up deprecated attribute
in DECL_TEMPLATE_RESULT or its type's attributes.

* g++.dg/cpp1y/attr-deprecated-3.C: New test.

[Bug c++/93228] [[deprecated("message")]] on template struct/class drops message

2020-01-10 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93228

Jakub Jelinek  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
   Assignee|unassigned at gcc dot gnu.org  |jakub at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek  ---
Created attachment 47633
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=47633=edit
gcc10-pr93228.patch

Untested fix.

[Bug c++/93228] [[deprecated("message")]] on template struct/class drops message

2020-01-10 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93228

Marek Polacek  changed:

   What|Removed |Added

   Keywords||diagnostic
 Status|UNCONFIRMED |NEW
   Last reconfirmed||2020-01-10
 CC||mpolacek at gcc dot gnu.org
 Ever confirmed|0   |1

--- Comment #1 from Marek Polacek  ---
Confirmed.