https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109824
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Ever confirmed|0 |1 Status|UNCONFIRMED |NEW Last reconfirmed| |2023-05-12 --- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Here is a better testcase: ``` struct a { int aa; }; typedef struct a less_aligned_a __attribute__ ((aligned (1))); static_assert(alignof(less_aligned_a) == 1); struct a aa __attribute__((unused)); static_assert(alignof(less_aligned_a) == 1); ``` Which shows the issue. The first static_assert works but the second one does not.