diff options
author | Nathan Sidwell <nathan@codesourcery.com> | 2004-07-06 08:51:32 +0000 |
---|---|---|
committer | Nathan Sidwell <nathan@codesourcery.com> | 2004-07-06 08:51:32 +0000 |
commit | 8997ab08b7c6c30c92081cd64bacc1a1a99edf7a (patch) | |
tree | a990dca8afae963468b42e953ee838e411e88c45 /gcc/cp/init.c | |
parent | 96830866389012a09930f9841dae745bd44a14e4 (diff) |
* tree.h (TREE_VIA_VIRTUAL): Rename to ...
(BINFO_VIRTUAL_P): ... here. Require TREE_BINFO only.
(BINFO_MARKED, BINFO_FLAG_[16]): New binfo flags.
* dbxout.c (dbxout_type): Use BINFO_VIRTUAL_P.
* dwarf2out.c (add_data_member_location_attribute): Likewise.
(gen_inheritance_die): Likewise.
* tree-dump.c (deque_and_dump): Likewise.
* doc/c-tree.texi (Binfos): Add under reconstruction note.
* cp/cp-tree.h (BINFO_MARKED): Remove.
(BINFO_VTABLE_PATH_MARKED, BINFO_NEW_VTABLE_MARKED,
BINFO_DEPENDENT_BASE_P, BINFO_LOST_PRIMARY_P,
BINFO_INDIRECT_PRIMARY_P): Use appropriate BINFO_FLAG_n.
(SET_BINFO_NEW_VTABLE_MARKED): Use BINFO_VIRTUAL_P.
* cp/class.c (build_base_path): Use BINFO_VIRTUAL_P.
(mark_primary_bases, determine_primary_base, base_derived_from,
dfs_find_final_overrider, dfs_find_final_overrider_q,
dfs_find_inal_overrider_post, update_vtable_entry_for_fn,
dfs_modify_vtables, walk_subobject_offsets,
layout_nonempty_base_or_field, build_base_field,
build_base_fields, propagate_binfo_offsets, layout_virtual_bases,
end_of_class, get_vfield_name, dump_class_hierarchy, dump_vtable,
finish_vtbls, build_vtt_inits, dfs_build_secondary_vptr_vtt_inits,
build_ctor_vtbl_group, accumulate_vtble_inits,
dfs_accumulate_vtbls_inits, build_vbase_offset_vtbl_entries,
build_vcall_offset_vtbl_entries, add_vcall_offset_vtbl_entries_r,
add_vcall_offset_vtbl_entries_1): Likewise.
* cp/decl.c (xref_basetypes): Incomming virtual base indicated by
TREE_TYPE. Adjust.
* cp/dump.c (cp_dump_tree): Use BINFO_VIRTUAL_P.
* cp/init.c (finish_init_stmts, sort_mem_initializers,
emit_mem_initializers, build_vtble_address, expand_member_init,
push_base_cleanups): Likewise.
* cp/method.c (do_build_copy_constructor): Likewise.
* cp/pt.c (instantiate_class_template,
get_template_base_recursive): Likewise.
* cp/rtti.c (dfs_class_hint_mark, get_pseudo_ti_init,
get_pseudo_ti_desc): Likewise.
* cp/search.c (lookup_base_r, dynamic_cast_base_recurse,
binfo_from_vbase, binfo_via_virtual, copied_binfo,
original_binfo): Likewise.
* cp/semantics.c (finish_base_specifier): Virtualness is indicated
by TREE_TYPE.
* cp/tree.c (copy_base_binfos): Use BINFO_VIRTUAL_P.
* java/java-tree.h (CLASS_HAS_SUPER_FLAG): Use BINFO_FLAG_1.
* java/class.c (add_interface_do): Use BINFO_VIRTUAL_P.
git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@84148 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/init.c')
-rw-r--r-- | gcc/cp/init.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gcc/cp/init.c b/gcc/cp/init.c index 1be01180426..19e51cdaaa2 100644 --- a/gcc/cp/init.c +++ b/gcc/cp/init.c @@ -101,7 +101,7 @@ finish_init_stmts (bool is_global, tree stmt_expr, tree compound_stmt) static tree dfs_initialize_vtbl_ptrs (tree binfo, void *data) { - if ((!BINFO_PRIMARY_P (binfo) || TREE_VIA_VIRTUAL (binfo)) + if ((!BINFO_PRIMARY_P (binfo) || BINFO_VIRTUAL_P (binfo)) && CLASSTYPE_VFIELDS (BINFO_TYPE (binfo))) { tree base_ptr = TREE_VALUE ((tree) data); @@ -478,7 +478,7 @@ sort_mem_initializers (tree t, tree mem_inits) for (i = 0; i < CLASSTYPE_N_BASECLASSES (t); ++i) { base = BINFO_BASETYPE (TYPE_BINFO (t), i); - if (!TREE_VIA_VIRTUAL (base)) + if (!BINFO_VIRTUAL_P (base)) sorted_inits = tree_cons (base, NULL_TREE, sorted_inits); } /* Process the non-static data members. */ @@ -677,7 +677,7 @@ emit_mem_initializers (tree mem_inits) arguments = NULL_TREE; /* Initialize the base. */ - if (TREE_VIA_VIRTUAL (subobject)) + if (BINFO_VIRTUAL_P (subobject)) construct_virtual_base (subobject, arguments); else { @@ -717,7 +717,7 @@ build_vtbl_address (tree binfo) tree binfo_for = binfo; tree vtbl; - if (BINFO_VPTR_INDEX (binfo) && TREE_VIA_VIRTUAL (binfo) + if (BINFO_VPTR_INDEX (binfo) && BINFO_VIRTUAL_P (binfo) && BINFO_PRIMARY_P (binfo)) /* If this is a virtual primary base, then the vtable we want to store is that for the base this is being used as the primary base of. We @@ -990,7 +990,7 @@ expand_member_init (tree name) } /* Look for a virtual base -- unless the direct base is itself virtual. */ - if (!direct_binfo || !TREE_VIA_VIRTUAL (direct_binfo)) + if (!direct_binfo || !BINFO_VIRTUAL_P (direct_binfo)) virtual_binfo = binfo_for_vbase (basetype, current_class_type); /* [class.base.init] @@ -2918,7 +2918,7 @@ push_base_cleanups (void) { tree base_binfo = TREE_VEC_ELT (binfos, i); if (TYPE_HAS_TRIVIAL_DESTRUCTOR (BINFO_TYPE (base_binfo)) - || TREE_VIA_VIRTUAL (base_binfo)) + || BINFO_VIRTUAL_P (base_binfo)) continue; expr = build_special_member_call (current_class_ref, |