13 static Check const data[] = {
14 { 0, 0, false }, // construct [0]
15 { 1, 0, true }, // [1] = [0]
16 { 0, 0, true }, // destruct [0]
17 { 2, 1, true }, // [2] = [1]
18 { 2, 2, true }, // destruct [2]
19 { 3, 1, true }, // [3] = [1]
20 { 3, 3, false }, // destruct [3]
21 { 1, 1, false }, // destruct [1]
22 { 9, 9, false } // end-of-data
27 static void test(int obj1, int obj2, bool state)
29 if (obj1 != data[pos].obj1) abort ();
30 if (obj2 != data[pos].obj2) abort ();
31 if (state != data[pos].state) abort ();
43 static int next_id = 0;
48 test (id, id, std::uncaught_exception ());
54 test (id, x.id, std::uncaught_exception ());
59 test (id, id, std::uncaught_exception ());
62 extern void foo (S *);
71 throw s0; // s1 is the exception object