aboutsummaryrefslogtreecommitdiff
path: root/gcc/stmt.c
diff options
context:
space:
mode:
authorNeil Booth <neil@daikokuya.demon.co.uk>2002-03-21 18:39:29 +0000
committerNeil Booth <neil@gcc.gnu.org>2002-03-21 18:39:29 +0000
commit43577e6bd7bb992e87d22b6ac5e13787f8a96af3 (patch)
treeb565716472649ba4ff8e84298f2475f0afd90105 /gcc/stmt.c
parent5b19b10c6b457c9d02812a2a68a73fa5d39086db (diff)
downloadgcc-43577e6bd7bb992e87d22b6ac5e13787f8a96af3.zip
gcc-43577e6bd7bb992e87d22b6ac5e13787f8a96af3.tar.gz
gcc-43577e6bd7bb992e87d22b6ac5e13787f8a96af3.tar.bz2
Makefile.in (fold-const.o, [...]): Update.
* Makefile.in (fold-const.o, stor-layout.o, stmt.o, sdbout.o, profile.o): Update. * c-common.c (c_common_nodes_and_builtins): Use pushdecl langhook. * c-common.h (gettags): Move here from tree.h. * c-tree.h (pushdecl, pushlevel, poplevel, set_block, insert_block, getdecls, kept_level_p, global_bindings_p): New. * dbxout.c (dbxout_init): Use getdecls langhook. * expr.c (expand_expr): Use insert_block langhook. * fold-const.c: Include langhooks.h. (fold_range_test, fold_binary_op_with_conditional_arg, fold): Use global_bindings_p langhook. * integrate.c (expand_inline_function): Use insert_block langhook. * langhooks-def.h (LANG_HOOKS_DECLS, LANG_HOOKS_PUSHLEVEL, LANG_HOOKS_POPLEVEL, LANG_HOOKS_GLOBAL_BINDINGS_P, LANG_HOOKS_INSERT_BLOCK, LANG_HOOKS_SET_BLOCK, LANG_HOOKS_PUSHDECL, LANG_HOOKS_GETDECLS): New. (LANG_HOOKS_INITIALIZER): Update. * langhooks.c (lhd_clear_binding_stack): Use global_bindings_p langhook. * langhooks.h (struct lang_hooks_for_decls): New. (struct lang_hooks): Update. * profile.c: Include langhooks.h. (output_func_start_profiler): Use new langhooks. * sdbout.c: Include langhooks.h. (sdbout_init, sdbout_finish): Use getdecls langhook. * stmt.c: Include langhooks.h. (expand_fixup, fixup_gotos): Use new langhooks. * stor-layout.c: Include langhooks.h. (variable_size): Use global_bindings_p langhook. * toplev.c (compile_file): Use getdecls langhook. * tree-inline.c (remap_block): Use insert_block langhook. * tree.h (pushdecl, pushlevel, poplevel, set_block, gettags, insert_block, getdecls, kept_level_p, global_bindings_p): Remove. cp: * cp-tree.h (pushdecl, pushlevel, poplevel, set_block, insert_block, getdecls, global_bindings_p): New. java: * cp-tree.h (pushdecl, pushlevel, poplevel, set_block, insert_block, getdecls, kept_level_p, global_bindings_p): New. f: * cp-tree.h (pushdecl, pushlevel, poplevel, set_block, insert_block, getdecls, global_bindings_p): New. From-SVN: r51136
Diffstat (limited to 'gcc/stmt.c')
-rw-r--r--gcc/stmt.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/gcc/stmt.c b/gcc/stmt.c
index b41b62b..559795d 100644
--- a/gcc/stmt.c
+++ b/gcc/stmt.c
@@ -53,6 +53,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "toplev.h"
#include "output.h"
#include "ggc.h"
+#include "langhooks.h"
#define obstack_chunk_alloc xmalloc
#define obstack_chunk_free free
@@ -1054,7 +1055,7 @@ expand_fixup (tree_label, rtl_label, last_insn)
TREE_USED (block) = 1;
if (!cfun->x_whole_function_mode_p)
- insert_block (block);
+ (*lang_hooks.decls.insert_block) (block);
else
{
BLOCK_CHAIN (block)
@@ -1175,8 +1176,8 @@ fixup_gotos (thisblock, stack_level, cleanup_list, first_insn, dont_jump_in)
logically be inserting the fixup code. We do this for the
sake of getting the debugging information right. */
- pushlevel (0);
- set_block (f->context);
+ (*lang_hooks.decls.pushlevel) (0);
+ (*lang_hooks.decls.set_block) (f->context);
/* Expand the cleanups for blocks this jump exits. */
if (f->cleanup_list_list)
@@ -1215,7 +1216,7 @@ fixup_gotos (thisblock, stack_level, cleanup_list, first_insn, dont_jump_in)
destructed are still "in scope". */
cleanup_insns = get_insns ();
- poplevel (1, 0, 0);
+ (*lang_hooks.decls.poplevel) (1, 0, 0);
end_sequence ();
emit_insns_after (cleanup_insns, f->before_jump);
@@ -1249,12 +1250,12 @@ fixup_gotos (thisblock, stack_level, cleanup_list, first_insn, dont_jump_in)
if (TREE_CHAIN (lists) == thisblock->data.block.outer_cleanups)
{
start_sequence ();
- pushlevel (0);
- set_block (f->context);
+ (*lang_hooks.decls.pushlevel) (0);
+ (*lang_hooks.decls.set_block) (f->context);
expand_cleanups (TREE_VALUE (lists), NULL_TREE, 1, 1);
do_pending_stack_adjust ();
cleanup_insns = get_insns ();
- poplevel (1, 0, 0);
+ (*lang_hooks.decls.poplevel) (1, 0, 0);
end_sequence ();
if (cleanup_insns != 0)
f->before_jump