diff options
author | Dirk Mueller <dmueller@suse.com> | 2006-01-04 15:26:15 +0000 |
---|---|---|
committer | Richard Biener <rguenth@gcc.gnu.org> | 2006-01-04 15:26:15 +0000 |
commit | ebfd9521b5926ac5a1d80b4a2f017e4bb57545de (patch) | |
tree | 68b979aad07636e1ccefd80d4cad57a4adad2687 /gcc | |
parent | d8701f023e1eddc20439eb2dc1b887b2225acb77 (diff) | |
download | gcc-ebfd9521b5926ac5a1d80b4a2f017e4bb57545de.zip gcc-ebfd9521b5926ac5a1d80b4a2f017e4bb57545de.tar.gz gcc-ebfd9521b5926ac5a1d80b4a2f017e4bb57545de.tar.bz2 |
decl.c (finish_constructor_body): create simple compound stmt instead of a if(1) { } construct.
2002-01-04 Dirk Mueller <dmueller@suse.com>
* decl.c (finish_constructor_body): create simple
compound stmt instead of a if(1) { } construct.
From-SVN: r109331
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/cp/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/cp/decl.c | 25 |
2 files changed, 5 insertions, 25 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 9102cbc..29389f4 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,8 @@ +2002-01-04 Dirk Mueller <dmueller@suse.com> + + * decl.c (finish_constructor_body): create simple + compound stmt instead of a if(1) { } construct. + 2006-01-03 Mark Mitchell <mark@codesourcery.com> PR c++/25492 diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index 020d96f..2f85334 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -10625,31 +10625,8 @@ finish_constructor_body (void) static void begin_destructor_body (void) { - tree if_stmt; tree compound_stmt; - /* If the dtor is empty, and we know there is not any possible - way we could use any vtable entries, before they are possibly - set by a base class dtor, we don't have to setup the vtables, - as we know that any base class dtor will set up any vtables - it needs. We avoid MI, because one base class dtor can do a - virtual dispatch to an overridden function that would need to - have a non-related vtable set up, we cannot avoid setting up - vtables in that case. We could change this to see if there - is just one vtable. - - ??? In the destructor for a class, the vtables are set - appropriately for that class. There will be no non-related - vtables. jason 2001-12-11. */ - if_stmt = begin_if_stmt (); - - /* If it is not safe to avoid setting up the vtables, then - someone will change the condition to be boolean_true_node. - (Actually, for now, we do not have code to set the condition - appropriately, so we just assume that we always need to - initialize the vtables.) */ - finish_if_stmt_cond (boolean_true_node, if_stmt); - compound_stmt = begin_compound_stmt (0); /* Make all virtual function table pointers in non-virtual base @@ -10658,8 +10635,6 @@ begin_destructor_body (void) initialize_vtbl_ptrs (current_class_ptr); finish_compound_stmt (compound_stmt); - finish_then_clause (if_stmt); - finish_if_stmt (if_stmt); /* And insert cleanups for our bases and members so that they will be properly destroyed if we throw. */ |