cp-tree.h (context_as_string): Remove extern.

* cp-tree.h (context_as_string): Remove extern.
	* error.c (context_as_string): Remove.

	* cp-tree.h (cp_type_qual_from_rid): Remove extern.
	* lex.c (cp_type_qual_from_rid): Remove.

	* cp-tree.h (do_poplevel): Remove extern.
	(check_multiple_declarators): Likewise.
	* semantics.c (do_poplevel): Make static.
	(check_multiple_declarators): Remove.

	* cp-tree.h (check_final_overrider): Remove extern.
	* search.c (check_final_overrider): Make static.

	* cp-tree.h (build_artificial_parm): Remove extern.
	* decl2.c (build_artificial_parm): Make static.

From-SVN: r91134
This commit is contained in:
Ben Elliston 2004-11-24 04:09:27 +00:00 committed by Ben Elliston
parent 0b167d51ed
commit af74669714
7 changed files with 22 additions and 59 deletions

View File

@ -1,3 +1,22 @@
2004-11-23 Ben Elliston <bje@au.ibm.com>
* cp-tree.h (context_as_string): Remove extern.
* error.c (context_as_string): Remove.
* cp-tree.h (cp_type_qual_from_rid): Remove extern.
* lex.c (cp_type_qual_from_rid): Remove.
* cp-tree.h (do_poplevel): Remove extern.
(check_multiple_declarators): Likewise.
* semantics.c (do_poplevel): Make static.
(check_multiple_declarators): Remove.
* cp-tree.h (check_final_overrider): Remove extern.
* search.c (check_final_overrider): Make static.
* cp-tree.h (build_artificial_parm): Remove extern.
* decl2.c (build_artificial_parm): Make static.
2004-11-22 Giovanni Bajo <giovannibajo@gcc.gnu.org>
PR c++/18354

View File

@ -3831,7 +3831,6 @@ extern void check_default_args (tree);
extern void mark_used (tree);
extern void finish_static_data_member_decl (tree, tree, tree, int);
extern tree cp_build_parm_decl (tree, tree);
extern tree build_artificial_parm (tree, tree);
extern tree get_guard (tree);
extern tree get_guard_cond (tree);
extern tree set_guard (tree);
@ -3853,7 +3852,6 @@ extern void init_error (void);
extern const char *type_as_string (tree, int);
extern const char *decl_as_string (tree, int);
extern const char *expr_as_string (tree, int);
extern const char *context_as_string (tree, int);
extern const char *lang_decl_name (tree, int);
extern const char *language_to_string (enum languages);
extern const char *class_key_or_enum_as_string (tree);
@ -3923,7 +3921,6 @@ extern tree cxx_make_type (enum tree_code);
extern tree make_aggr_type (enum tree_code);
extern void yyerror (const char *);
extern void yyhook (int);
extern int cp_type_qual_from_rid (tree);
extern bool cxx_init (void);
extern void cxx_finish (void);
@ -4056,7 +4053,6 @@ extern tree binfo_for_vtable (tree);
extern tree binfo_from_vbase (tree);
extern tree binfo_for_vbase (tree, tree);
extern tree look_for_overrides_here (tree, tree);
extern int check_final_overrider (tree, tree);
#define dfs_skip_bases ((tree)1)
extern tree dfs_walk_all (tree, tree (*) (tree, void *),
tree (*) (tree, void *), void *);
@ -4080,7 +4076,6 @@ extern void pop_to_parent_deferring_access_checks (void);
extern void perform_deferred_access_checks (void);
extern void perform_or_defer_access_check (tree, tree);
extern void init_cp_semantics (void);
extern tree do_poplevel (tree);
extern void add_decl_expr (tree);
extern tree finish_expr_stmt (tree);
extern tree begin_if_stmt (void);
@ -4157,7 +4152,6 @@ extern void finish_template_decl (tree);
extern tree finish_template_type (tree, tree, int);
extern tree finish_base_specifier (tree, tree, bool);
extern void finish_member_declaration (tree);
extern void check_multiple_declarators (void);
extern void qualified_name_lookup_error (tree, tree, tree);
extern tree finish_id_expression (tree, tree, tree,
cp_id_kind *, tree *,

View File

@ -157,7 +157,7 @@ cp_build_parm_decl (tree name, tree type)
/* Returns a PARM_DECL for a parameter of the indicated TYPE, with the
indicated NAME. */
tree
static tree
build_artificial_parm (tree name, tree type)
{
tree parm = cp_build_parm_decl (name, type);

View File

@ -1919,14 +1919,6 @@ decl_as_string (tree decl, int flags)
return pp_formatted_text (cxx_pp);
}
const char *
context_as_string (tree context, int flags)
{
reinit_cxx_pp ();
dump_scope (context, flags);
return pp_formatted_text (cxx_pp);
}
/* Generate the three forms of printable names for cxx_printable_name. */
const char *

View File

@ -796,20 +796,3 @@ make_aggr_type (enum tree_code code)
return t;
}
/* Return the type-qualifier corresponding to the identifier given by
RID. */
int
cp_type_qual_from_rid (tree rid)
{
if (rid == ridpointers[(int) RID_CONST])
return TYPE_QUAL_CONST;
else if (rid == ridpointers[(int) RID_VOLATILE])
return TYPE_QUAL_VOLATILE;
else if (rid == ridpointers[(int) RID_RESTRICT])
return TYPE_QUAL_RESTRICT;
gcc_unreachable ();
return TYPE_UNQUALIFIED;
}

View File

@ -1774,7 +1774,7 @@ dfs_walk_once_accessible (tree binfo, bool friends_p,
/* Check that virtual overrider OVERRIDER is acceptable for base function
BASEFN. Issue diagnostic, and return zero, if unacceptable. */
int
static int
check_final_overrider (tree overrider, tree basefn)
{
tree over_type = TREE_TYPE (overrider);

View File

@ -401,7 +401,7 @@ anon_aggr_type_p (tree node)
/* Finish a scope. */
tree
static tree
do_poplevel (tree stmt_list)
{
tree block = NULL;
@ -2294,31 +2294,6 @@ finish_base_specifier (tree base, tree access, bool virtual_p)
return result;
}
/* Called when multiple declarators are processed. If that is not
permitted in this context, an error is issued. */
void
check_multiple_declarators (void)
{
/* [temp]
In a template-declaration, explicit specialization, or explicit
instantiation the init-declarator-list in the declaration shall
contain at most one declarator.
We don't just use PROCESSING_TEMPLATE_DECL for the first
condition since that would disallow the perfectly valid code,
like `template <class T> struct S { int i, j; };'. */
if (at_function_scope_p ())
/* It's OK to write `template <class T> void f() { int i, j;}'. */
return;
if (PROCESSING_REAL_TEMPLATE_DECL_P ()
|| processing_explicit_instantiation
|| processing_specialization)
error ("multiple declarators in template declaration");
}
/* Issue a diagnostic that NAME cannot be found in SCOPE. DECL is
what we found when we tried to do the lookup. */