From 5355cb603e009ae52d0d013a39e9718453541dcc Mon Sep 17 00:00:00 2001 From: mmitchel Date: Tue, 27 Jul 1999 18:15:21 +0000 Subject: * cp-tree.h (BINFO_VIRTUALS): Document new format. * class.c (modify_one_vtable): Change prototype accordingly. (modify_all_vtables): Likewise. (modify_all_direct_vtables): Likewise. (modify_all_indirect_vtables): Likewise. (build_vtable_entry_for_fn): New function. (set_rtti_entry): Simplify for new BINFO_VIRTUALS format. (modify_vtable_entry): Likewise. (add_virtual_function): Likewise. (build_vtbl_initializer): New function. (finish_vtbls): Simplify for new BINFO_VIRTUALS format. (fixup_vtable_deltas1): Likewise. (fixup_vtable_deltas): Likewise. (override_one_vtable): Likewise. (finish_struct_1): Likewise. * error.c (dump_expr): Likewise. * search.c (get_abstract_virtuals_1): Likewise. (get_abstract_virtuals): Likewise. (expand_upcast_fixups): Likewise. * tree.c (debug_binfo): Likewise. * decl2.c (mark_vtable_entries): Don't bash abstract virtuals to __pure_virtual here. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@28298 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/cp/search.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'gcc/cp/search.c') diff --git a/gcc/cp/search.c b/gcc/cp/search.c index b7f3e18453b..3af71f1cfc2 100644 --- a/gcc/cp/search.c +++ b/gcc/cp/search.c @@ -2032,10 +2032,10 @@ get_abstract_virtuals_1 (binfo, do_self, abstract_virtuals) while (virtuals) { - tree base_pfn = FNADDR_FROM_VTABLE_ENTRY (TREE_VALUE (virtuals)); - tree base_fndecl = TREE_OPERAND (base_pfn, 0); + tree base_fndecl = TREE_VALUE (virtuals); if (DECL_ABSTRACT_VIRTUAL_P (base_fndecl)) - abstract_virtuals = tree_cons (NULL_TREE, base_fndecl, abstract_virtuals); + abstract_virtuals = tree_cons (NULL_TREE, base_fndecl, + abstract_virtuals); virtuals = TREE_CHAIN (virtuals); } } @@ -2065,12 +2065,12 @@ get_abstract_virtuals (type) while (virtuals) { - tree base_pfn = FNADDR_FROM_VTABLE_ENTRY (TREE_VALUE (virtuals)); - tree base_fndecl = TREE_OPERAND (base_pfn, 0); + tree base_fndecl = TREE_VALUE (virtuals); if (DECL_NEEDS_FINAL_OVERRIDER_P (base_fndecl)) cp_error ("`%#D' needs a final overrider", base_fndecl); else if (DECL_ABSTRACT_VIRTUAL_P (base_fndecl)) - abstract_virtuals = tree_cons (NULL_TREE, base_fndecl, abstract_virtuals); + abstract_virtuals = tree_cons (NULL_TREE, base_fndecl, + abstract_virtuals); virtuals = TREE_CHAIN (virtuals); } } @@ -2541,8 +2541,7 @@ expand_upcast_fixups (binfo, addr, orig_addr, vbase, vbase_addr, t, while (virtuals) { tree current_fndecl = TREE_VALUE (virtuals); - current_fndecl = FNADDR_FROM_VTABLE_ENTRY (current_fndecl); - current_fndecl = TREE_OPERAND (current_fndecl, 0); + if (current_fndecl && current_fndecl != abort_fndecl && (vc=virtual_context (current_fndecl, t, vbase)) != vbase) -- cgit v1.2.1