arocc icon indicating copy to clipboard operation
arocc copied to clipboard

`_Alignas` not allowed on declarations with `register` storage class

Open Vexu opened this issue 1 year ago • 0 comments

void foo(void) {
    register _Alignas(8) int a;
}
$ arocc a.c -fsyntax-only
$ clang a.c -fsyntax-only
a.c:20:14: error: '_Alignas' attribute cannot be applied to a variable with 'register' storage class
   20 |     register _Alignas(8) int a;
      |              ^
1 error generated.

Vexu avatar Dec 31 '24 13:12 Vexu