From 543a0daa84fd7dda27536a892dd88896ba25b1f3 Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Sun, 20 Jun 2004 03:10:02 -0700 Subject: c-common.h (add_decl_stmt): Move to cp-tree.h. * c-common.h (add_decl_stmt): Move to cp-tree.h. * c-decl.c (finish_decl): Don't use add_decl_stmt. * c-parse.in: Likewise. * c-gimplify.c (gimplify_expr_stmt): Don't build CLEANUP_POINT_EXPR. (gimplify_c_loop, gimplify_return_stmt, gimplify_decl_stmt): Likewise. * c-semantics.c (add_decl_stmt): Move to cp/semantics.c. cp/ * cp-tree.h (add_decl_stmt): Declare. * pt.c (tsubst_copy): Abort for CLEANUP_POINT_EXPR. * semantics.c (maybe_cleanup_point_expr): New. (add_decl_stmt, finish_expr_stmt, finish_return_stmt, finish_for_expr, finish_switch_cond): Use it. (finalize_nrv_r): Don't build an EXPR_STMT. Don't frob TREE_CHAIN. From-SVN: r83409 --- gcc/c-parse.in | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gcc/c-parse.in') diff --git a/gcc/c-parse.in b/gcc/c-parse.in index d3e39af..02625a5 100644 --- a/gcc/c-parse.in +++ b/gcc/c-parse.in @@ -1540,7 +1540,7 @@ nested_function: add_stmt ($6); finish_function (); pop_function_context (); - add_decl_stmt (decl); } + add_stmt (build_stmt (DECL_STMT, decl)); } ; notype_nested_function: @@ -1570,7 +1570,7 @@ notype_nested_function: add_stmt ($6); finish_function (); pop_function_context (); - add_decl_stmt (decl); } + add_stmt (build_stmt (DECL_STMT, decl)); } ; /* Any kind of declarator (thus, all declarators allowed @@ -2019,7 +2019,7 @@ label_decl: { tree label = declare_label (TREE_VALUE (link)); C_DECLARED_LABEL_FLAG (label) = 1; - add_decl_stmt (label); + add_stmt (build_stmt (DECL_STMT, label)); } } ; -- cgit v1.1