diff options
author | Mark Mitchell <mark@codesourcery.com> | 1999-09-07 16:07:42 +0000 |
---|---|---|
committer | Mark Mitchell <mmitchel@gcc.gnu.org> | 1999-09-07 16:07:42 +0000 |
commit | 87e3dbc92a1bb114bdde00fe8d541f7fc121e9d6 (patch) | |
tree | 5caea69b4472a05021147247c1b01dfdbe9059bd /gcc/cp/cp-tree.h | |
parent | bcc5cac9a73b8d8903cd5b7ac7e789dfb26e1a7c (diff) | |
download | gcc-87e3dbc92a1bb114bdde00fe8d541f7fc121e9d6.zip gcc-87e3dbc92a1bb114bdde00fe8d541f7fc121e9d6.tar.gz gcc-87e3dbc92a1bb114bdde00fe8d541f7fc121e9d6.tar.bz2 |
Makefile.in (tree.o): Depend on ggc.h.
* Makefile.in (tree.o): Depend on ggc.h.
* class.c (make_method_vec): Remove.
(free_method_vec): Likewise.
(free_method_vecs): Remove.
(add_method): Don't use them.
* cp-tree.def (PTRMEM_CST): Make it longer.
(TEMPLATE_PARM_INDEX): Make it shorter.
* cp-tree.h (BINDING_HAS_LEVEL_P): New macro.
(template_parm_index): Remove RTL field.
(ptrmem_cst): Add RTL field.
(finish_function): Removed parameter.
(process_next_inline): Change prototype.
(init_cplus_unsave): Rename to init_tree.
(binding_init): Remove.
* decl.c (free_binding_nodes): Remove.
(push_binding): Don't use them. Set BINDING_HAS_LEVEL_P.
(pop_binding): Don't use free_binding_nodes.
(free_binding_vecs): Remove.
(store_bindings): Don't use them.
(pop_from_top_level): Likewise.
(lookup_namespace_name): Simplify.
(build_typename_type): Don't use obstack_free.
(unqualified_namespace_lookup): Simplify.
(lookup_name_real): Simplify.
(start_function): Remove comment about leaks.
(finish_function): Removed nested parameter. Call
expand_end_bindings even when building_stmt_tree.
Call ggc_push_context and ggc_pop_context around
rest_of_compilation, if necessary.
(mark_cp_function_context): Handle a NULL language-context.
(lang_mark_false_label_stack): Fix typo.
(lang_mark_tree): Handle CPLUS_BINDING, OVERLOAD,
TEMPLATE_PARM_INDEX. Handle the funny TYPE_LANG_SPECIFIC on
pointer to method types.
(lang_cleanup_tree): Use free to free TYPE_LANG_SPECIFIC.
* decl2.c (finish_objects): Adjust call to finish_function.
(finish_static_store_duration_function): Likewise.
(do_nonmember_using_decl): Remove call to binding_init.
* except.c (end_anon_func): Adjust call to finish_function.
* lex.c (mark_impl_file_chain): New function.
(init_parse): Call init_tree, not init_cplus_unsave.
Add GC roots.
(cp_pramga_interface): Use xmalloc, not permalloc.
(cp_pragma_implementation): Likewise.
(begin_definition_of_inclass_inline): Simplify.
(process_next_inline): Adjust prototype.
(do_scoped_id): Don't call binding_init.
(make_lang_type): Allocate TYPE_LANG_SPECIFIC with xmalloc.
(emit_thunk): Adjust call to finish_function.
(synthesize_method): Likewise.
* parse.y (%union): Add a new `pi' variant.
(PRE_PARSED_FUNCTION_DECL): Use it.
(fn.defpen): Likewise.
(fndef): Adjust call to finish_function.
(instantiate_decl): Likewise.
(rtti.c): Likewise.
(semantics.c): Likewise.
* tree.c: Include ggc.h.
(mark_list_hash): New function.
(binding_init): Remove.
(init_cplus_unsave): Rename to ...
(init_tree): This. Add GC roots.
From-SVN: r29172
Diffstat (limited to 'gcc/cp/cp-tree.h')
-rw-r--r-- | gcc/cp/cp-tree.h | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h index 14231e8..d7ca7a7 100644 --- a/gcc/cp/cp-tree.h +++ b/gcc/cp/cp-tree.h @@ -54,6 +54,7 @@ Boston, MA 02111-1307, USA. */ BINFO_FIELDS_MARKED. TYPE_VIRTUAL_P. ICS_THIS_FLAG (in _CONV) + BINDING_HAS_LEVEL_P (In CPLUS_BINDING) 3: TYPE_USES_VIRTUAL_BASECLASSES (in a class TYPE). BINFO_VTABLE_PATH_MARKED. BINFO_PUSHDECLS_MARKED. @@ -139,8 +140,6 @@ typedef struct typedef struct { char common[sizeof (struct tree_common)]; - struct rtx_def *rtl; /* Unused, but required to match up with what - the middle-end expects. */ HOST_WIDE_INT index; HOST_WIDE_INT level; HOST_WIDE_INT orig_level; @@ -150,6 +149,9 @@ typedef struct typedef struct ptrmem_cst { char common[sizeof (struct tree_common)]; + /* This isn't used, but the middle-end expects all constants to have + this field. */ + struct rtx_def *rtl; tree member; }* ptrmem_cst_t; @@ -168,6 +170,9 @@ typedef struct ptrmem_cst BINDING_LEVEL is used instead. */ #define BINDING_SCOPE(NODE) (((struct tree_binding*)NODE)->scope.scope) +/* Nonzero if NODE has BINDING_LEVEL, rather than BINDING_SCOPE. */ +#define BINDING_HAS_LEVEL_P(NODE) TREE_LANG_FLAG_2 ((NODE)) + /* This is the declaration bound to the name. Possible values: variable, overloaded function, namespace, template, enumerator. */ #define BINDING_VALUE(NODE) (((struct tree_binding*)NODE)->value) @@ -3174,7 +3179,7 @@ extern int start_function PROTO((tree, tree, tree, int)); extern void expand_start_early_try_stmts PROTO((void)); extern void store_parm_decls PROTO((void)); extern void store_return_init PROTO((tree)); -extern void finish_function PROTO((int, int, int)); +extern void finish_function PROTO((int, int)); extern tree start_method PROTO((tree, tree, tree)); extern tree finish_method PROTO((tree)); extern void hack_incomplete_structures PROTO((tree)); @@ -3376,7 +3381,7 @@ extern void reinit_parse_for_function PROTO((void)); extern void print_parse_statistics PROTO((void)); extern void extract_interface_info PROTO((void)); extern void do_pending_inlines PROTO((void)); -extern void process_next_inline PROTO((tree)); +extern void process_next_inline PROTO((struct pending_inline *)); extern struct pending_input *save_pending_input PROTO((void)); extern void restore_pending_input PROTO((struct pending_input *)); extern void yyungetc PROTO((int, int)); @@ -3640,7 +3645,7 @@ extern int yylex PROTO((void)); extern tree arbitrate_lookup PROTO((tree, tree, tree)); /* in tree.c */ -extern void init_cplus_unsave PROTO((void)); +extern void init_tree PROTO((void)); extern void cplus_unsave_expr_now PROTO((tree)); extern int pod_type_p PROTO((tree)); extern void unshare_base_binfos PROTO((tree)); @@ -3670,7 +3675,6 @@ extern tree reverse_path PROTO((tree)); extern int count_functions PROTO((tree)); extern int is_overloaded_fn PROTO((tree)); extern tree get_first_fn PROTO((tree)); -extern tree binding_init PROTO((struct tree_binding*)); extern int bound_pmf_p PROTO((tree)); extern tree ovl_cons PROTO((tree, tree)); extern tree scratch_ovl_cons PROTO((tree, tree)); |