* cp-tree.h (CP_DECL_CONTEXT): New macro.
authorjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 25 Jun 1998 03:28:35 +0000 (03:28 +0000)
committerjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 25 Jun 1998 03:28:35 +0000 (03:28 +0000)
commitd8396542151c98c3424ea7b9fc796e13645ee02a
tree9200dfe8e80bc424f27eb57bd93f73389e249e39
parent2cf1388ad7832ef619569c6ef65f8a927ffe5845
* cp-tree.h (CP_DECL_CONTEXT): New macro.
* decl2.c (is_namespace_ancestor, lookup_using_namespace): Use it.
* method.c (build_overload_nested_name): Likewise.
* sig.c (build_signature_pointer_or_reference_type): Don't set
DECL_CONTEXT.
Set DECL_CONTEXT for globals to NULL_TREE instead of global_namespace.
* cp-tree.h (FROB_CONTEXT): New macro.
(DECL_MAIN_P): ::main should have a DECL_CONTEXT of NULL_TREE.
* decl.c (namespace_binding): Replace NULL_TREE with
global_namespace.
(set_namespace_binding, pop_namespace, lookup_name_real): Likewise.
* decl2.c (is_namespace_ancestor, lookup_using_namespace):
Likewise.
* decl.c (pushtag): Use FROB_CONTEXT.
(pushdecl, make_typename_type, define_function, grokdeclarator):
Likewise.
* decl2.c (set_decl_namespace, do_namespace_alias): Likewise.
* pt.c (push_template_decl_real, lookup_template_class, tsubst):
Likewise.
* decl2.c (decl_namespace): Return global_namespace if no context.
* method.c (build_overload_nested_name): Expect null as context.
* pt.c (mangle_class_name_for_template): Do nothing for null
contexts.
(lookup_template_class): Allow for null id_context.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@20710 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/cp/ChangeLog
gcc/cp/Makefile.in
gcc/cp/cp-tree.h
gcc/cp/decl.c
gcc/cp/decl2.c
gcc/cp/method.c
gcc/cp/parse.c
gcc/cp/parse.y
gcc/cp/pt.c
gcc/cp/sig.c