OSDN Git Service

* gcc.dg/20020201-1.c: Use cleanup-coverage_files.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.old-deja / g++.eh / vbase2.C
1 // { dg-do run  }
2 // Origin: Mark Mitchell <mark@codesourcery.com>
3
4 int i;
5
6 struct A
7 {
8   A () { i++; }
9   ~A () { i--; }
10 };
11
12 struct B : public virtual A
13 {
14   B () { throw 1; }
15 };
16
17 struct D: public B, virtual public A
18 {
19 };
20
21 void f()
22 {
23   D d;
24 }
25
26 int main ()
27 {
28   try {
29     f();
30   } catch (int) {
31   }
32
33   return i;
34 }
35