Commit b6263c5d by Nathan Sidwell Committed by Nathan Sidwell

Kill walk_namespaces.

	* cp-tree.h (walk_namespaces_fn, walk_namespaces): Delete.
	* decl.c (walk_namespaces_r, walk_namespaces): Delete.

From-SVN: r247638
parent c02d2d0a
2017-05-05 Nathan Sidwell <nathan@acm.org> 2017-05-05 Nathan Sidwell <nathan@acm.org>
Kill walk_namespaces.
* cp-tree.h (walk_namespaces_fn, walk_namespaces): Delete.
* decl.c (walk_namespaces_r, walk_namespaces): Delete.
Kill per-namespace static_decls. Kill per-namespace static_decls.
* cp-tree.h (static_decls): Declare. * cp-tree.h (static_decls): Declare.
(wrapup_globals_for_namespace, (wrapup_globals_for_namespace,
......
...@@ -5902,9 +5902,6 @@ extern void revert_static_member_fn (tree); ...@@ -5902,9 +5902,6 @@ extern void revert_static_member_fn (tree);
extern void fixup_anonymous_aggr (tree); extern void fixup_anonymous_aggr (tree);
extern tree compute_array_index_type (tree, tree, tsubst_flags_t); extern tree compute_array_index_type (tree, tree, tsubst_flags_t);
extern tree check_default_argument (tree, tree, tsubst_flags_t); extern tree check_default_argument (tree, tree, tsubst_flags_t);
typedef int (*walk_namespaces_fn) (tree, void *);
extern int walk_namespaces (walk_namespaces_fn,
void *);
extern int wrapup_namespace_globals (); extern int wrapup_namespace_globals ();
extern tree create_implicit_typedef (tree, tree); extern tree create_implicit_typedef (tree, tree);
extern int local_variable_p (const_tree); extern int local_variable_p (const_tree);
......
...@@ -78,7 +78,6 @@ static void check_for_uninitialized_const_var (tree); ...@@ -78,7 +78,6 @@ static void check_for_uninitialized_const_var (tree);
static tree local_variable_p_walkfn (tree *, int *, void *); static tree local_variable_p_walkfn (tree *, int *, void *);
static const char *tag_name (enum tag_types); static const char *tag_name (enum tag_types);
static tree lookup_and_check_tag (enum tag_types, tree, tag_scope, bool); static tree lookup_and_check_tag (enum tag_types, tree, tag_scope, bool);
static int walk_namespaces_r (tree, walk_namespaces_fn, void *);
static void maybe_deduce_size_from_array_init (tree, tree); static void maybe_deduce_size_from_array_init (tree, tree);
static void layout_var_decl (tree); static void layout_var_decl (tree);
static tree check_initializer (tree, tree, int, vec<tree, va_gc> **); static tree check_initializer (tree, tree, int, vec<tree, va_gc> **);
...@@ -879,32 +878,6 @@ poplevel (int keep, int reverse, int functionbody) ...@@ -879,32 +878,6 @@ poplevel (int keep, int reverse, int functionbody)
return block; return block;
} }
/* Walk all the namespaces contained NAMESPACE, including NAMESPACE
itself, calling F for each. The DATA is passed to F as well. */
static int
walk_namespaces_r (tree name_space, walk_namespaces_fn f, void* data)
{
int result = 0;
tree current = NAMESPACE_LEVEL (name_space)->namespaces;
result |= (*f) (name_space, data);
for (; current; current = DECL_CHAIN (current))
result |= walk_namespaces_r (current, f, data);
return result;
}
/* Walk all the namespaces, calling F for each. The DATA is passed to
F as well. */
int
walk_namespaces (walk_namespaces_fn f, void* data)
{
return walk_namespaces_r (global_namespace, f, data);
}
/* Call wrapup_globals_declarations for the globals in NAMESPACE. */ /* Call wrapup_globals_declarations for the globals in NAMESPACE. */
/* Diagnose odr-used extern inline variables without definitions /* Diagnose odr-used extern inline variables without definitions
in the current TU. */ in the current TU. */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment