[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2019-05-22 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

Jonathan Wakely  changed:

   What|Removed |Added

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

--- Comment #8 from Jonathan Wakely  ---
Fixed for 8.3 and 9.1

[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2018-11-05 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

--- Comment #7 from Jakub Jelinek  ---
Author: jakub
Date: Mon Nov  5 14:09:10 2018
New Revision: 265803

URL: https://gcc.gnu.org/viewcvs?rev=265803=gcc=rev
Log:
Backported from mainline
2018-10-24  Jakub Jelinek  

PR c++/86288
* parser.c (cp_parser_std_attribute): Canonicalize attr_ns, and when
:: is not present and attr_ns non-NULL, canonicalize also attr_id.
(cp_parser_attribute_spec): Fix comment typo.

* g++.dg/cpp0x/gen-attrs-66.C: New test.

Added:
branches/gcc-8-branch/gcc/testsuite/g++.dg/cpp0x/gen-attrs-66.C
Modified:
branches/gcc-8-branch/gcc/cp/ChangeLog
branches/gcc-8-branch/gcc/cp/parser.c
branches/gcc-8-branch/gcc/testsuite/ChangeLog

[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2018-10-24 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

--- Comment #6 from Jakub Jelinek  ---
Author: jakub
Date: Wed Oct 24 19:39:23 2018
New Revision: 265470

URL: https://gcc.gnu.org/viewcvs?rev=265470=gcc=rev
Log:
PR c++/86288
* parser.c (cp_parser_std_attribute): Canonicalize attr_ns, and when
:: is not present and attr_ns non-NULL, canonicalize also attr_id.
(cp_parser_attribute_spec): Fix comment typo.

* g++.dg/cpp0x/gen-attrs-66.C: New test.

Added:
trunk/gcc/testsuite/g++.dg/cpp0x/gen-attrs-66.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/parser.c
trunk/gcc/testsuite/ChangeLog

[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2018-10-24 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

--- Comment #5 from Jonathan Wakely  ---
Clang has now implemented this as a special case, only recognizing "__gnu__" as
a synonym for the "gnu" attribute-namespace. That's fine for libstdc++'s
purposes, as I don't expect we'll start using any other vendor attributes.

EDG have also been told about this, so compilers based on their front end
should also be able to recognize [[__gnu__::__blah__]] at some point.

[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2018-10-17 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

--- Comment #4 from Jonathan Wakely  ---
I think Jakub's patch does only allow __gnu__, using the same canonicalization
for attribute-namespaces as for attributes.

[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2018-10-17 Thread msebor at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

Martin Sebor  changed:

   What|Removed |Added

 CC||msebor at gcc dot gnu.org

--- Comment #3 from Martin Sebor  ---
If both __gnu__ and __gnu are accepted, should both __aligned__ and __aligned
also be?  If not, then should only __gnu__ be accepted?

[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2018-10-17 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

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 44846
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=44846=edit
gcc9-pr86288.patch

Untested patch with implementation for this enhancement request as well as fix
for the above mentioned ICE (the latter should be backported I guess).

[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2018-10-17 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

Jakub Jelinek  changed:

   What|Removed |Added

 CC||jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek  ---
Unrelated note, we even ICE on
int f [[using gnu : __aligned__(alignof(int))]];

[Bug c++/86288] Recognize __gnu and/or __gnu__ as attribute-namespace

2018-10-17 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86288

Jonathan Wakely  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2018-10-17
 Ever confirmed|0   |1