]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/testsuite/gcc.dg/Wunused-var-6.c
Update copyright years.
[thirdparty/gcc.git] / gcc / testsuite / gcc.dg / Wunused-var-6.c
1 /* PR c/99588 */
2 /* { dg-do compile } */
3 /* { dg-options "-std=c11 -Wunused-but-set-variable" } */
4
5 void bar (int, ...);
6 struct S { int a, b, c; };
7 typedef _Atomic struct S T;
8
9 void
10 foo (void)
11 {
12 static T x = (struct S) { 0, 0, 0 }; /* { dg-bogus "set but not used" } */
13 bar (0, x = (struct S) { 1, 1, 1 });
14 }