diff options
author | lerdsuwa <lerdsuwa@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-03-14 14:33:54 +0000 |
---|---|---|
committer | lerdsuwa <lerdsuwa@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-03-14 14:33:54 +0000 |
commit | 3f3fa5564280a316734286ccac29e446d28b9d9a (patch) | |
tree | 3d599413959c98f204efab81966efde722599232 /gcc/cp/name-lookup.h | |
parent | 944f00e4cb072dc6e19537bcdea49ffcdbf46c4a (diff) | |
download | gcc-3f3fa5564280a316734286ccac29e446d28b9d9a.tar.gz |
Friend class name lookup 5/n
PR c++/1016
* cp-tree.h (pushtag): Adjust declaration.
* decl.c (lookup_and_check_tag): Call lookup_type_scope if
lookup_name fails.
(xref_tag): Adjust call to pushtag. Make hidden class visible.
(start_enum): Adjust call to pushtag.
* name-lookup.c (ambiguous_decl): Ignore hidden names.
(qualify_lookup): Change return type to bool.
(hidden_name_p): New function.
(lookup_namespace_name, unqualified_namespace_lookup,
lookup_name_real): Use it.
(lookup_type_scope): Update comments.
(maybe_process_template_type_declaration): Change parameter name
from globalize to is_friend.
(pushtag): Change globalize parameter of type int to tag_scope.
Hide name if introduced by friend declaration.
* name-lookup.h (hidden_name_p): Add declaration.
* parser.c (cp_parser_lookup_name): Don't deal with hidden name
here.
* pt.c (push_template_decl_real): Make hidden class template
visible.
(lookup_template_class, instantiate_class_template): Adjust call
to pushtag.
* semantics.c (begin_class_definition): Likewise.
* rtti.c (init_rtti_processing, build_dynamic_cast_1,
tinfo_base_init, emit_support_tinfos): Use ts_current instead of
ts_global.
* g++.dg/lookup/hidden-class1.C: New test.
* g++.dg/lookup/hidden-class2.C: Likewise.
* g++.dg/lookup/hidden-class3.C: Likewise.
* g++.dg/lookup/hidden-class4.C: Likewise.
* g++.dg/lookup/hidden-class5.C: Likewise.
* g++.dg/lookup/hidden-class6.C: Likewise.
* g++.dg/lookup/hidden-class7.C: Likewise.
* g++.dg/lookup/hidden-class8.C: Likewise.
* g++.dg/lookup/hidden-class9.C: Likewise.
* g++.dg/lookup/hidden-temp-class1.C: Likewise.
* g++.dg/lookup/hidden-temp-class2.C: Likewise.
* g++.dg/lookup/hidden-temp-class3.C: Likewise.
* g++.dg/lookup/hidden-temp-class4.C: Likewise.
* g++.dg/lookup/hidden-temp-class5.C: Likewise.
* g++.dg/lookup/hidden-temp-class6.C: Likewise.
* g++.dg/lookup/hidden-temp-class7.C: Likewise.
* g++.dg/lookup/hidden-temp-class8.C: Likewise.
* g++.dg/lookup/hidden-temp-class9.C: Likewise.
* g++.dg/lookup/hidden-temp-class10.C: Likewise.
* g++.dg/lookup/hidden-temp-class11.C: Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@96430 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/name-lookup.h')
-rw-r--r-- | gcc/cp/name-lookup.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/cp/name-lookup.h b/gcc/cp/name-lookup.h index e4433191771..451e6ecffa3 100644 --- a/gcc/cp/name-lookup.h +++ b/gcc/cp/name-lookup.h @@ -315,6 +315,7 @@ extern tree lookup_name_real (tree, int, int, bool, int, int); extern tree lookup_type_scope (tree, tag_scope); extern tree namespace_binding (tree, tree); extern void set_namespace_binding (tree, tree, tree); +extern bool hidden_name_p (tree); extern tree lookup_namespace_name (tree, tree); extern tree lookup_qualified_name (tree, tree, bool, bool); extern tree lookup_name_nonclass (tree); |