Debian Codegraph @

gcc/testsuite/g++.dg/pr69697.C

raw
1 /* { dg-do compile { target c++11 } } */
2 /* { dg-additional-options "-Wno-pedantic" } */
3
4 int i;
5 struct A { int n, a[]; }
6 a = i ? A({ 1, { 2 } }) /* { dg-error "(non-static)|(initialization)" } */
7 : A({ 2, { 3, 4 } }); /* { dg-error "(non-static)|(initialization)" } */