diff options
author | Jason Merrill <jason@redhat.com> | 2005-11-11 12:14:49 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2005-11-11 12:14:49 -0500 |
commit | df77f454639a450946ea2b7d96dff216b0199c68 (patch) | |
tree | 31f98d4599a66a5410481c3cad61fa9efd5df0e1 /gcc/gimplify.c | |
parent | 301a8f9577f730dcb680760b84e258e62cafd01f (diff) | |
download | gcc-df77f454639a450946ea2b7d96dff216b0199c68.zip gcc-df77f454639a450946ea2b7d96dff216b0199c68.tar.gz gcc-df77f454639a450946ea2b7d96dff216b0199c68.tar.bz2 |
re PR c++/24686 (ICE when building a variation of NMSTL)
PR c++/24686
* gimplify.c (gimplify_cleanup_point_expr): Also save and restore
the cleanup list.
From-SVN: r106786
Diffstat (limited to 'gcc/gimplify.c')
-rw-r--r-- | gcc/gimplify.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/gimplify.c b/gcc/gimplify.c index 9e25aef..b232112 100644 --- a/gcc/gimplify.c +++ b/gcc/gimplify.c @@ -3810,14 +3810,18 @@ gimplify_cleanup_point_expr (tree *expr_p, tree *pre_p) tree temp = voidify_wrapper_expr (*expr_p, NULL); /* We only care about the number of conditions between the innermost - CLEANUP_POINT_EXPR and the cleanup. So save and reset the count. */ + CLEANUP_POINT_EXPR and the cleanup. So save and reset the count and + any cleanups collected outside the CLEANUP_POINT_EXPR. */ int old_conds = gimplify_ctxp->conditions; + tree old_cleanups = gimplify_ctxp->conditional_cleanups; gimplify_ctxp->conditions = 0; + gimplify_ctxp->conditional_cleanups = NULL_TREE; body = TREE_OPERAND (*expr_p, 0); gimplify_to_stmt_list (&body); gimplify_ctxp->conditions = old_conds; + gimplify_ctxp->conditional_cleanups = old_cleanups; for (iter = tsi_start (body); !tsi_end_p (iter); ) { |