diff options
author | jason <jason@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-10-15 05:21:37 +0000 |
---|---|---|
committer | jason <jason@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-10-15 05:21:37 +0000 |
commit | e2d9473df995c429354a369fa5071f5e041d1d89 (patch) | |
tree | 1790aa29b83df4a200b6f43e36baf83dc6d873d5 /gcc/tree-eh.c | |
parent | 0620694017a1deac0f345790b5f9cdc721540d48 (diff) | |
download | gcc-e2d9473df995c429354a369fa5071f5e041d1d89.tar.gz |
* tree-eh.c (optimize_double_finally): Don't assume that the
cleanup we're duplicating is only one statement.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@129311 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-eh.c')
-rw-r--r-- | gcc/tree-eh.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/gcc/tree-eh.c b/gcc/tree-eh.c index 1924353f7b1..71d3d941b79 100644 --- a/gcc/tree-eh.c +++ b/gcc/tree-eh.c @@ -2157,18 +2157,12 @@ optimize_double_finally (tree one, tree two) if (same_handler_p (TREE_OPERAND (oneh, 1), TREE_OPERAND (two, 1))) { - tree twoh; - tree b = TREE_OPERAND (oneh, 0); TREE_OPERAND (one, 1) = b; TREE_SET_CODE (one, TRY_CATCH_EXPR); - b = tsi_stmt (tsi_start (b)); - twoh = TREE_OPERAND (two, 0); - /* same_handler_p only handles single-statement handlers, - so there must only be one statement. */ - i = tsi_start (twoh); - tsi_link_before (&i, unshare_expr (b), TSI_SAME_STMT); + i = tsi_start (TREE_OPERAND (two, 0)); + tsi_link_before (&i, unsave_expr_now (b), TSI_SAME_STMT); } } |