diff options
author | Mark Mitchell <mark@codesourcery.com> | 1999-09-08 20:53:47 +0000 |
---|---|---|
committer | Mark Mitchell <mmitchel@gcc.gnu.org> | 1999-09-08 20:53:47 +0000 |
commit | be91309cdabe6cd22d8656e8c0333e578918079f (patch) | |
tree | f5d0ca9f9a5255ae403e53148f91f3c103db5e85 | |
parent | 2e769ad05c7ddfd4791b18f1251113e7d0cf94a7 (diff) | |
download | gcc-be91309cdabe6cd22d8656e8c0333e578918079f.zip gcc-be91309cdabe6cd22d8656e8c0333e578918079f.tar.gz gcc-be91309cdabe6cd22d8656e8c0333e578918079f.tar.bz2 |
decl.c (start_function): Clear last_dtor_insn and last_parm_cleanup_insn.
* decl.c (start_function): Clear last_dtor_insn and
last_parm_cleanup_insn.
(push_cp_function_context): Just copy over a little of
the old context, not all of it.
From-SVN: r29213
-rw-r--r-- | gcc/cp/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/cp/decl.c | 8 |
2 files changed, 9 insertions, 4 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 4b689de..315e38d 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,10 @@ 1999-09-08 Mark Mitchell <mark@codesourcery.com> + * decl.c (start_function): Clear last_dtor_insn and + last_parm_cleanup_insn. + (push_cp_function_context): Just copy over a little of + the old context, not all of it. + * cp-tree.h (copy_to_permanent): Remove. (permanent_p): Likewise. * decl.c (building_typename_type): Don't use copy_to_permanent. diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index c66ba02..f3c67f9 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -12903,6 +12903,8 @@ start_function (declspecs, declarator, attrs, pre_parsed_p) current_function_assigns_this = 0; current_function_just_assigned_this = 0; current_function_parms_stored = 0; + last_dtor_insn = NULL_RTX; + last_parm_cleanup_insn = NULL_RTX; original_result_rtx = NULL_RTX; base_init_expr = NULL_TREE; current_base_init_list = NULL_TREE; @@ -14483,12 +14485,10 @@ push_cp_function_context (f) { struct language_function *p = ((struct language_function *) - xmalloc (sizeof (struct language_function))); + xcalloc (1, sizeof (struct language_function))); f->language = p; if (f->next) - *p = *f->next->language; - else - bzero (p, sizeof (struct language_function)); + p->binding_level = f->next->language->binding_level; /* For now, we always assume we're expanding all the way to RTL unless we're explicitly doing otherwise. */ |