diff options
author | Ollie Wild <aaw@google.com> | 2007-08-24 10:21:13 +0000 |
---|---|---|
committer | Ollie Wild <aaw@gcc.gnu.org> | 2007-08-24 10:21:13 +0000 |
commit | 89bd2c0308d7df6dc9ef000151844b41fac0e63b (patch) | |
tree | d62331aa9bc5247a8e890a9d8ae3131a26ffddd1 /gcc | |
parent | 972ce83e761fc86f8ff51e87b85807bfd654379c (diff) | |
download | gcc-89bd2c0308d7df6dc9ef000151844b41fac0e63b.zip gcc-89bd2c0308d7df6dc9ef000151844b41fac0e63b.tar.gz gcc-89bd2c0308d7df6dc9ef000151844b41fac0e63b.tar.bz2 |
name-lookup.c (add_decl_to_level): Remove addition to vtables chain.
gcc/cp/
* name-lookup.c (add_decl_to_level): Remove addition to vtables chain.
* name-lookup.h (cp_binding_level): Remove vtables member.
From-SVN: r127765
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/cp/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/cp/name-lookup.c | 9 | ||||
-rw-r--r-- | gcc/cp/name-lookup.h | 3 |
3 files changed, 9 insertions, 8 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 5bc2266..33a207e 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,8 @@ +2007-08-24 Ollie Wild <aaw@google.com> + + * name-lookup.c (add_decl_to_level): Remove addition to vtables chain. + * name-lookup.h (cp_binding_level): Remove vtables member. + 2007-08-24 Richard Guenther <rguenther@suse.de> * tree.c (cp_cannot_inline_tree_fn): Remove. diff --git a/gcc/cp/name-lookup.c b/gcc/cp/name-lookup.c index c6628aa..5b5e99d 100644 --- a/gcc/cp/name-lookup.c +++ b/gcc/cp/name-lookup.c @@ -536,17 +536,16 @@ supplement_binding (cxx_binding *binding, tree decl) static void add_decl_to_level (tree decl, cxx_scope *b) { + /* We used to record virtual tables as if they were ordinary + variables, but no longer do so. */ + gcc_assert (!(TREE_CODE (decl) == VAR_DECL && DECL_VIRTUAL_P (decl))); + if (TREE_CODE (decl) == NAMESPACE_DECL && !DECL_NAMESPACE_ALIAS (decl)) { TREE_CHAIN (decl) = b->namespaces; b->namespaces = decl; } - else if (TREE_CODE (decl) == VAR_DECL && DECL_VIRTUAL_P (decl)) - { - TREE_CHAIN (decl) = b->vtables; - b->vtables = decl; - } else { /* We build up the list in reverse order, and reverse it later if diff --git a/gcc/cp/name-lookup.h b/gcc/cp/name-lookup.h index d82445f..88551f2 100644 --- a/gcc/cp/name-lookup.h +++ b/gcc/cp/name-lookup.h @@ -190,9 +190,6 @@ struct cp_binding_level GTY(()) /* An array of static functions and variables (for namespaces only) */ VEC(tree,gc) *static_decls; - /* A chain of VTABLE_DECL nodes. */ - tree vtables; - /* A list of USING_DECL nodes. */ tree usings; |