]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/testsuite/gcc.dg/c2x-complit-7.c
testsuite: Refer more consistently to C23 not C2X
[thirdparty/gcc.git] / gcc / testsuite / gcc.dg / c2x-complit-7.c
1 /* Test C23 storage class specifiers in compound literals diagnosed with
2 -Wc11-c23-compat, but not errors with -pedantic-errors. */
3 /* { dg-do compile } */
4 /* { dg-options "-std=c23 -Wc11-c23-compat -pedantic-errors" } */
5
6 int *ps = &(static int) { 1 }; /* { dg-warning "forbids storage class specifiers in compound literals" } */
7 int ss = sizeof (static int) { 1 }; /* { dg-warning "forbids storage class specifiers in compound literals" } */