1 // Make sure that we force an LSDA for a throw() spec with -fnothrow-opt so
2 // that the personality routine will call terminate.  Also check that we
3 // optimize away the EH cleanup for var because the personality routine
4 // will call terminate before unwinding: there should not be an EH region
5 // (i.e. LEHB/LEHE labels) around the call to g().
6 
7 // { dg-final { scan-assembler-not "_ZSt9terminatev" } }
8 // { dg-final { scan-assembler-not "EHB" } }
9 // { dg-final { scan-assembler "LSDA" } }
10 
11 // { dg-options "-fnothrow-opt" }
12 
13 struct A { ~A(); };
14 void g();
f()15 void f() throw()
16 {
17   A var;
18   g();
19 }
20