PR c++/81917 - ICE with void_t and partial specialization.
[official-gcc.git] / gcc / testsuite / g++.dg / opt / vt3.C
blob0cef67206e012656a10f77ddc6d18e5be8f80a51
1 // PR c++/34949
2 // { dg-do compile }
3 // { dg-options "-O3" }
5 struct E {};
6 struct A
8   virtual void a (void *) = 0;
9 };
10 struct B
12   virtual ~B () {};
13   unsigned int b1;
14   E **b2;
15   A *b3;
17 struct C : public B
19   ~C ();
21 C::~C ()
23   for (unsigned int i = 0; i < b1; i++)
24     b3->a (b2);
26 struct D
28   ~D () {}
29   C d;
31 struct F { virtual ~F () {}; };
32 struct G { void g (); };
33 struct H : public F
35   virtual ~H ();
36   D *h1;
37   G *h2;
39 H::~H ()
41   h2->g ();
42   delete h1;