g++.dg/tree-ssa/ehcleanup-1.C: New testcase.
From-SVN: r146603
This commit is contained in:
parent
4c7c486a4e
commit
0500a9f180
@ -1,3 +1,7 @@
|
||||
2009-04-22 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
* g++.dg/tree-ssa/ehcleanup-1.C: New testcase.
|
||||
|
||||
2009-04-22 Steve Ellcey <sje@cup.hp.com>
|
||||
|
||||
PR testsuite/39623
|
||||
|
24
gcc/testsuite/g++.dg/tree-ssa/ehcleanup-1.C
Normal file
24
gcc/testsuite/g++.dg/tree-ssa/ehcleanup-1.C
Normal file
@ -0,0 +1,24 @@
|
||||
// { dg-options "-O2 -fdump-tree-ehcleanup1" }
|
||||
extern void can_throw ();
|
||||
class a
|
||||
{
|
||||
public:
|
||||
~a ()
|
||||
{
|
||||
if (0)
|
||||
can_throw ();
|
||||
}
|
||||
};
|
||||
void
|
||||
t (void)
|
||||
{
|
||||
class a a;
|
||||
can_throw ();
|
||||
}
|
||||
// We ought to remove implicit cleanup, since destructor is empty.
|
||||
// { dg-final { scan-tree-dump-times "Empty EH handler" 1 "ehcleanup1" } }
|
||||
//
|
||||
// And as a result also contained control flow.
|
||||
// { dg-final { scan-tree-dump-times "Removing unreachable" 1 "ehcleanup1" } }
|
||||
//
|
||||
// { dg-final { cleanup-tree-dump "ehcleanup1" } }
|
Loading…
Reference in New Issue
Block a user