Debian Codegraph @

gcc/testsuite/g++.dg/cpp0x/defaulted45.C

raw
1 // { dg-do run }
2 // { dg-require-effective-target c++11 }
3
4 struct A
5 {
6 int i;
7 A() = default;
8 A(int i): i{i} { }
9 ~A() {}
10 };
11
12 int main(int argc, char **argv)
13 {
14 { int i[4] = { 42, 42, 42, 42 }; }
15 {
16 A a[4] = { argc };
17 if (a[1].i != 0)
18 __builtin_abort ();
19 }
20 }