[Bug c++/118787] [15 Regression] ICE, Segmentation fault

2025-03-04 Thread cvs-commit at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118787

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

https://gcc.gnu.org/g:1853b02d8c127740055242123db2d32cf9476ea9

commit r15-7822-g1853b02d8c127740055242123db2d32cf9476ea9
Author: Jakub Jelinek 
Date:   Wed Mar 5 06:41:00 2025 +0100

c++: Apply/diagnose attributes when instatiating
ARRAY/POINTER/REFERENCE_TYPE [PR118787]

The following testcase IMO in violation of the P2552R3 paper doesn't
pedwarn on alignas applying to dependent types or alignas with dependent
argument.

tsubst was just ignoring TYPE_ATTRIBUTES.

The following patch fixes it for the POINTER/REFERENCE_TYPE and
ARRAY_TYPE cases, but perhaps we need to do the same also for other
types (INTEGER_TYPE/REAL_TYPE and the like).  I guess I'll need to
construct more testcases.

2025-03-05  Jakub Jelinek  

PR c++/118787
* pt.cc (tsubst) : Use return t; only if it
doesn't
have any TYPE_ATTRIBUTES.  Call apply_late_template_attributes.
: Likewise.  Formatting
fix.

* g++.dg/cpp0x/alignas22.C: New test.

[Bug c++/118787] [15 Regression] ICE, Segmentation fault

2025-02-07 Thread sjames at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118787

Sam James  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|UNCONFIRMED |RESOLVED

--- Comment #2 from Sam James  ---
r15-7435-g278bf5726c69db works.

[Bug c++/118787] [15 Regression] ICE, Segmentation fault

2025-02-07 Thread jakub at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118787

Jakub Jelinek  changed:

   What|Removed |Added

 CC||jakub at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek  ---
I think r15-7414-g801fb71f83624f0bf6d6bd27121d4a332103f7be should have fixed
this.

[Bug c++/118787] [15 Regression] ICE, Segmentation fault

2025-02-07 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118787

Andrew Pinski  changed:

   What|Removed |Added

 CC||pinskia at gcc dot gnu.org
   Target Milestone|--- |15.0