2018-11-07 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / g++.dg / cpp0x / initlist-throw2.C
blob2bb05834d9e0cdce75f15379896b74899d2ab8c7
1 // PR c++/85363
2 // { dg-do run { target c++11 } }
4 int
5 init (int f)
7   throw f;
10 struct X {
11   X () : n {init (42)} {}
12   int n;
15 struct P {
16   struct R {
17     struct Q {
18       X x = {};
19     } q;
20   } r;
23 int
24 main ()
26   try {
27     P p {};
28   }
29   catch (int n) {
30     return 0;
31   }
32   return 1;