diff options
author | Martin v. Löwis <loewis@informatik.hu-berlin.de> | 1998-10-22 14:48:22 +0000 |
---|---|---|
committer | Martin v. Löwis <loewis@gcc.gnu.org> | 1998-10-22 14:48:22 +0000 |
commit | e0afe616d4883f8dcfdafda44373d3f8190b9e20 (patch) | |
tree | 398582feb23b0a4ebae05a74cb692d990e07bc76 | |
parent | 298978c9331b7601a24eeb5d46a56ee88740c9c2 (diff) | |
download | gcc-e0afe616d4883f8dcfdafda44373d3f8190b9e20.zip gcc-e0afe616d4883f8dcfdafda44373d3f8190b9e20.tar.gz gcc-e0afe616d4883f8dcfdafda44373d3f8190b9e20.tar.bz2 |
* init.c (build_new_1): Delay cleanup until end of full expression.
From-SVN: r23223
-rw-r--r-- | gcc/cp/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/cp/init.c | 11 |
2 files changed, 4 insertions, 11 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 8bdc162..f2be60c 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +1998-10-22 Martin v. Löwis <loewis@informatik.hu-berlin.de> + + * init.c (build_new_1): Delay cleanup until end of full expression. + 1998-10-21 Jason Merrill <jason@yorick.cygnus.com> * typeck.c (build_component_ref): Use of a type here is an error. diff --git a/gcc/cp/init.c b/gcc/cp/init.c index 47c8355..87c4a59 100644 --- a/gcc/cp/init.c +++ b/gcc/cp/init.c @@ -2444,9 +2444,6 @@ build_new_1 (exp) if (cleanup) { -#if 0 - /* Disable this until flow is fixed so that it doesn't - think the initialization of sentry is a dead write. */ tree end, sentry, begin, buf, t = TREE_TYPE (rval); begin = get_target_expr (boolean_true_node); @@ -2469,14 +2466,6 @@ build_new_1 (exp) rval = build (COMPOUND_EXPR, t, begin, build (COMPOUND_EXPR, t, rval, build (COMPOUND_EXPR, t, end, buf))); -#else - /* FIXME: this is a workaround for a crash due to overlapping - exception regions. Cleanups shouldn't really happen here. */ - rval = build1 (CLEANUP_POINT_EXPR, TREE_TYPE (rval), rval); - - rval = build (TRY_CATCH_EXPR, TREE_TYPE (rval), rval, cleanup); - rval = build (COMPOUND_EXPR, TREE_TYPE (rval), alloc_expr, rval); -#endif } } } |