Debian Codegraph @

gcc/testsuite/g++.dg/cpp1z/decomp45.C

raw
1 // PR c++/85227
2 // { dg-do compile { target c++11 } }
3 // { dg-options "" }
4
5 extern struct A a;
6
7 template<int>
8 void f()
9 {
10 auto [x] = a; // { dg-warning "incomplete" }
11 } // { dg-warning "structured bindings only available with '-std=c..17' or '-std=gnu..17'" "" { target c++14_down } .-1 }
12
13 struct A { int i; };
14
15 int main()
16 {
17 f<0>();
18 }