From 2e3757e78af922758a8ec45c4af78159384a6091 Mon Sep 17 00:00:00 2001 From: Nathan Sidwell Date: Thu, 11 May 2017 15:46:48 +0000 Subject: [PATCH] Revert pushdecl_top_level_and_finish name change. * name-lookup.h (pushdecl_top_level_and_finish): Resurrect old name. * name-lookup.c (pushdecl_top_level_and_finish): Likewise. * decl.c (cp_make_fname_decl): Adjust. * decl2.c (get_guard, handle_tls_init): Adjust. * rtti.c (get_tinfo_decl, tinfo_base_init): Adjust. From-SVN: r247915 --- gcc/cp/ChangeLog | 7 +++++++ gcc/cp/decl.c | 2 +- gcc/cp/decl2.c | 4 ++-- gcc/cp/name-lookup.c | 2 +- gcc/cp/name-lookup.h | 2 +- gcc/cp/rtti.c | 4 ++-- 6 files changed, 14 insertions(+), 7 deletions(-) diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 78269de..63fac4d 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,12 @@ 2017-05-11 Nathan Sidwell + Revert pushdecl_top_level_and_finish name change. + * name-lookup.h (pushdecl_top_level_and_finish): Resurrect old name. + * name-lookup.c (pushdecl_top_level_and_finish): Likewise. + * decl.c (cp_make_fname_decl): Adjust. + * decl2.c (get_guard, handle_tls_init): Adjust. + * rtti.c (get_tinfo_decl, tinfo_base_init): Adjust. + * name-lookup.c (pushdecl_outermost_localscope): Always conditionally stop timer. diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index 44276cc..476fd8d 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -4342,7 +4342,7 @@ cp_make_fname_decl (location_t loc, tree id, int type_dep) else { DECL_THIS_STATIC (decl) = true; - pushdecl_top_level_with_init (decl, init); + pushdecl_top_level_and_finish (decl, init); } return decl; diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c index 758c698..46959ec 100644 --- a/gcc/cp/decl2.c +++ b/gcc/cp/decl2.c @@ -3021,7 +3021,7 @@ get_guard (tree decl) DECL_ARTIFICIAL (guard) = 1; DECL_IGNORED_P (guard) = 1; TREE_USED (guard) = 1; - pushdecl_top_level_with_init (guard, NULL_TREE); + pushdecl_top_level_and_finish (guard, NULL_TREE); } return guard; } @@ -4261,7 +4261,7 @@ handle_tls_init (void) TREE_USED (guard) = true; CP_DECL_THREAD_LOCAL_P (guard) = true; set_decl_tls_model (guard, decl_default_tls_model (guard)); - pushdecl_top_level_with_init (guard, NULL_TREE); + pushdecl_top_level_and_finish (guard, NULL_TREE); tree fn = get_local_tls_init_fn (); start_preparsed_function (fn, NULL_TREE, SF_PRE_PARSED); diff --git a/gcc/cp/name-lookup.c b/gcc/cp/name-lookup.c index b5a60e3..183133b 100644 --- a/gcc/cp/name-lookup.c +++ b/gcc/cp/name-lookup.c @@ -4586,7 +4586,7 @@ pushdecl_top_level_maybe_friend (tree x, bool is_friend) initializing it with INIT. */ tree -pushdecl_top_level_with_init (tree x, tree init) +pushdecl_top_level_and_finish (tree x, tree init) { return pushdecl_top_level_1 (x, &init, false); } diff --git a/gcc/cp/name-lookup.h b/gcc/cp/name-lookup.h index f24461c..4b46f3e 100644 --- a/gcc/cp/name-lookup.h +++ b/gcc/cp/name-lookup.h @@ -340,7 +340,7 @@ extern tree pushdecl (tree); extern tree pushdecl_outermost_localscope (tree); extern tree pushdecl_top_level_maybe_friend (tree, bool is_friend); extern tree pushdecl_top_level (tree); -extern tree pushdecl_top_level_with_init (tree, tree); +extern tree pushdecl_top_level_and_finish (tree, tree); extern tree pushtag (tree, tree, tag_scope); extern bool push_namespace (tree); extern void pop_namespace (void); diff --git a/gcc/cp/rtti.c b/gcc/cp/rtti.c index c5a110c..89d1891 100644 --- a/gcc/cp/rtti.c +++ b/gcc/cp/rtti.c @@ -445,7 +445,7 @@ get_tinfo_decl (tree type) DECL_NOT_REALLY_EXTERN (d) = 1; set_linkage_according_to_type (type, d); - d = pushdecl_top_level_with_init (d, NULL_TREE); + d = pushdecl_top_level_and_finish (d, NULL_TREE); if (CLASS_TYPE_P (type)) CLASSTYPE_TYPEINFO_VAR (TYPE_MAIN_VARIANT (type)) = d; @@ -911,7 +911,7 @@ tinfo_base_init (tinfo_s *ti, tree target) name_string = tinfo_name (target, !TREE_PUBLIC (name_decl)); DECL_INITIAL (name_decl) = name_string; mark_used (name_decl); - pushdecl_top_level_with_init (name_decl, name_string); + pushdecl_top_level_and_finish (name_decl, name_string); } vtable_ptr = ti->vtable; -- 2.7.4