cp-tree.def (CLEANUP_STMT): New node.
authorMark Mitchell <mark@codesourcery.com>
Sun, 12 Sep 1999 01:12:59 +0000 (01:12 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Sun, 12 Sep 1999 01:12:59 +0000 (01:12 +0000)
commit24bef15854919b1b36f74ea8208c71b146975a0b
tree21262e14b6ea734d629371b88b3f1eeb361b27dc
parentfcf6eeb628b0df816f962c5185641325de7d5f6e
cp-tree.def (CLEANUP_STMT): New node.

* cp-tree.def (CLEANUP_STMT): New node.
* cp-tree.h (language_function): Add name_declared.
(current_function_name_declared): New macro.
(CLEANUP_DECL): New macro.
(CLEANUP_EXPR): Likewise.
(emit_local_var): Likewise.
(finish_decl_cleanup): New function.
* cvt.c (build_up_reference): Simplify.
(ocp_convert): Remove dead code.
* decl.c (start_decl): Remove call to add_decl_stmt.
(grok_reference_init): Adjust, to handle bindings temporaries to
references.  Remove dead code.
(initialize_local_var): Don't generate RTL for
declarations here, or build cleanups here.  Don't fuss with
obstacks.  Replace expand_start_target_temps calls with explicit
setting of stms_are_full_exprs_p.
(destroy_local_var): New function.
(emit_local_var): Likewise.
(cp_finish_decl): Use them, as appropriate.
(start_function): Announce template functions.
(store_parm_decls): Don't call declare_function_name here.
(finish_stmt): Don't start emit base-initialization code when just
building the statement-tree.
* init.c (create_temporary_var): Move add_decl_stmt call ...
(get_temp_regvar): Here.
* pt.c (tsubst_expr): Make DECL_INITIAL look like what
cp_finish_decl would expect.  Don't call add_decl_stmt.
* semantics.c (begin_compound_stmt): Call declare_function_name,
if appropriate.
(finish_decl_cleanup): New function.
(expand_stmt): Use emit_local_var to output variables.
(expand_body): Set current_funtion_name_declared.

From-SVN: r29348
gcc/cp/ChangeLog
gcc/cp/cp-tree.def
gcc/cp/cp-tree.h
gcc/cp/cvt.c
gcc/cp/decl.c
gcc/cp/init.c
gcc/cp/pt.c
gcc/cp/semantics.c