2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.mike / p6058.C
blob3146e542a22eb6ebefe7da14deb077a35a9f0cfd
1 // { dg-do assemble  }
2 // { dg-options "-fexceptions -pedantic-errors" }
3 // prms-id: 6058
5 void bar(struct s1 { } a) { (void)a; }                  // { dg-error "" } 
7 struct s2*fooey()
9   try {
10     static_cast<struct s3 { } *>(0);                    // { dg-error "" } 
11     const_cast<struct s4 { } *>((s4*)0);                // { dg-error "" } 
12     reinterpret_cast<struct s5 { } *>((s3*)0);          // { dg-error "" } 
13     dynamic_cast<struct s6 { } *>((s6*)0);              // { dg-error "" } 
14     (struct s7 { } *)(int*)0xffedec;                    // { dg-error "" } 
15   } catch (struct s8 { } s) {                           // { dg-error "" } 
16   }
17   return 0;