From 87e3d7cfb5c5c9cf265e5ee803cce904f2a5a123 Mon Sep 17 00:00:00 2001 From: Nathan Sidwell Date: Thu, 5 Oct 2017 12:10:55 +0000 Subject: [C++ PATCH] Kill IDENTIFIER_GLOBAL_VALUE https://gcc.gnu.org/ml/gcc-patches/2017-10/msg00239.html Kill IDENTIFIER_GLOBAL_VALUE, SET_IDENTIFIER_GLOBAL_VALUE * cp-tree.h (IDENTIFIER_GLOBAL_VALUE, SET_IDENTIFIER_GLOBAL_VALUE): Delete. * name-lookup.h (set_global_binding): Remove NAME parm. (get_global_binding): New inline fn. * name-lookup.c (set_global_binding): Remove NAME parm. Adjust. (identifier_global_value): Move to ... * cp-objcp-common.c (identifier_global_value): ... here. * class.c (build_ctor_vtbl_group, build_vtbl_initializer): Adjust. * decl.c (record_builtin_type, expand_static_init, grokdeclarator): Adjust. * decl2.c (get_guard, get_local_tls_init_fn, get_tls_init_fn, get_tls_wrapper_fn, maybe_warn_sized_delete): Adjust. * except.c (declare_library_fn, build_throw): Adjust. * init.c (throw_bad_array_length): Adjust. * rtti.c (throw_bad_cast, throw_bad_typeid, get_tinfo_decl): Adjust. From-SVN: r253444 --- gcc/cp/cp-objcp-common.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'gcc/cp/cp-objcp-common.c') diff --git a/gcc/cp/cp-objcp-common.c b/gcc/cp/cp-objcp-common.c index 267fcca..f251b05 100644 --- a/gcc/cp/cp-objcp-common.c +++ b/gcc/cp/cp-objcp-common.c @@ -400,6 +400,15 @@ cp_pushdecl (tree decl) return pushdecl (decl); } +/* Get the global value binding of NAME. Called directly from + c-common.c, not via a hook. */ + +tree +identifier_global_value (tree name) +{ + return get_global_binding (name); +} + /* Register c++-specific dumps. */ void -- cgit v1.1