Debian Codegraph @

gcc/testsuite/g++.dg/eh/synth2.C

raw
1 // PR c++/24580
2 // { dg-do run }
3
4 struct vbase {};
5
6 struct foo : virtual vbase
7 {
8 foo()
9 {
10 throw "exception in foo ctor";
11 }
12 };
13
14 struct bar : public foo {};
15
16 int main()
17 {
18 try
19 {
20 bar a;
21 }
22 catch ( ... ) { }
23 return 0;
24 }