aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorVolker Reichelt <reichelt@igpm.rwth-aachen.de>2006-01-25 08:45:44 +0000
committerVolker Reichelt <reichelt@igpm.rwth-aachen.de>2006-01-25 08:45:44 +0000
commitd6de2256b3b7b1d2f20a4ebb2bdc6b206cdca6e5 (patch)
tree96929012c1a30a58a388ef3d847a5366b4ce7912 /gcc
parent0e1cc58bc02f03431750d9ed6268d85922260b14 (diff)
* cp-tree.h (get_primary_binfo): Remove prototype.
(push_using_decl): Likewise. (current_template_args): Likewise. (more_specialized_class): Likewise. (mark_class_instantiated): Likewise. (default_conversion): Likewise. (pfn_from_ptrmemfunc): Likewise. * class.c (get_primary_binfo): Add prototype, make static, simplify. * name-lookup.c (push_using_decl): Make static. * pt.c (current_template_args): Likewise. (more_specialized_class): Likewise. (mark_class_instantiated): Likewise. * typeck.c (default_conversion): Make static. (pfn_from_ptrmemfunc): Add prototype, make static. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@110208 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cp/ChangeLog17
-rw-r--r--gcc/cp/class.c7
-rw-r--r--gcc/cp/cp-tree.h7
-rw-r--r--gcc/cp/name-lookup.c2
-rw-r--r--gcc/cp/pt.c6
-rw-r--r--gcc/cp/typeck.c5
6 files changed, 27 insertions, 17 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index d373078c997..a4f2fab7e0e 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,20 @@
+2006-01-25 Volker Reichelt <reichelt@igpm.rwth-aachen.de>
+
+ * cp-tree.h (get_primary_binfo): Remove prototype.
+ (push_using_decl): Likewise.
+ (current_template_args): Likewise.
+ (more_specialized_class): Likewise.
+ (mark_class_instantiated): Likewise.
+ (default_conversion): Likewise.
+ (pfn_from_ptrmemfunc): Likewise.
+ * class.c (get_primary_binfo): Add prototype, make static, simplify.
+ * name-lookup.c (push_using_decl): Make static.
+ * pt.c (current_template_args): Likewise.
+ (more_specialized_class): Likewise.
+ (mark_class_instantiated): Likewise.
+ * typeck.c (default_conversion): Make static.
+ (pfn_from_ptrmemfunc): Add prototype, make static.
+
2006-01-24 Dirk Mueller <dmueller@suse.de>
* typeck.c (build_binary_op): Use OPT_Wfloat_equal in warning().
diff --git a/gcc/cp/class.c b/gcc/cp/class.c
index ecad65054f9..bcbed7be4d2 100644
--- a/gcc/cp/class.c
+++ b/gcc/cp/class.c
@@ -167,6 +167,7 @@ static tree dfs_find_final_overrider_pre (tree, void *);
static tree dfs_find_final_overrider_post (tree, void *);
static tree find_final_overrider (tree, tree, tree);
static int make_new_vtable (tree, tree);
+static tree get_primary_binfo (tree);
static int maybe_indent_hierarchy (FILE *, int, int);
static tree dump_class_hierarchy_r (FILE *, int, tree, tree, int);
static void dump_class_hierarchy (tree);
@@ -6362,18 +6363,16 @@ get_vtbl_decl_for_binfo (tree binfo)
BINFO in the complete object. Check BINFO_PRIMARY_P or
BINFO_LOST_PRIMARY_P to be sure. */
-tree
+static tree
get_primary_binfo (tree binfo)
{
tree primary_base;
- tree result;
primary_base = CLASSTYPE_PRIMARY_BINFO (BINFO_TYPE (binfo));
if (!primary_base)
return NULL_TREE;
- result = copied_binfo (primary_base, binfo);
- return result;
+ return copied_binfo (primary_base, binfo);
}
/* If INDENTED_P is zero, indent to INDENT. Return nonzero. */
diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h
index 68c6ddb65e7..e7394075b24 100644
--- a/gcc/cp/cp-tree.h
+++ b/gcc/cp/cp-tree.h
@@ -3740,7 +3740,6 @@ extern void invalidate_class_lookup_cache (void);
extern void maybe_note_name_used_in_class (tree, tree);
extern void note_name_declared_in_class (tree, tree);
extern tree get_vtbl_decl_for_binfo (tree);
-extern tree get_primary_binfo (tree);
extern void debug_class (tree);
extern void debug_thunks (tree);
extern tree cp_fold_obj_type_ref (tree, tree);
@@ -3787,7 +3786,6 @@ extern tree duplicate_decls (tree, tree, bool);
extern tree pushdecl_top_level (tree);
extern tree pushdecl_top_level_maybe_friend (tree, bool);
extern tree pushdecl_top_level_and_finish (tree, tree);
-extern tree push_using_decl (tree, tree);
extern tree declare_local_label (tree);
extern tree define_label (location_t, tree);
extern void check_goto (tree);
@@ -4006,7 +4004,6 @@ extern tree check_explicit_specialization (tree, tree, int, int);
extern tree process_template_parm (tree, tree, bool);
extern tree end_template_parm_list (tree);
extern void end_template_decl (void);
-extern tree current_template_args (void);
extern tree push_template_decl (tree);
extern tree push_template_decl_real (tree, bool);
extern void redeclare_class_template (tree, tree);
@@ -4021,13 +4018,11 @@ extern int fn_type_unification (tree, tree, tree, tree,
tree, unification_kind_t, int);
extern void mark_decl_instantiated (tree, int);
extern int more_specialized_fn (tree, tree, int);
-extern void mark_class_instantiated (tree, int);
extern void do_decl_instantiation (tree, tree);
extern void do_type_instantiation (tree, tree, tsubst_flags_t);
extern tree instantiate_decl (tree, int, bool);
extern int push_tinst_level (tree);
extern void pop_tinst_level (void);
-extern int more_specialized_class (tree, tree, tree);
extern int comp_template_parms (tree, tree);
extern int template_class_depth (tree);
extern int is_specialization_of (tree, tree);
@@ -4309,7 +4304,6 @@ extern tree cxx_sizeof_or_alignof_type (tree, enum tree_code, bool);
#define cxx_sizeof_nowarn(T) cxx_sizeof_or_alignof_type (T, SIZEOF_EXPR, false)
extern tree inline_conversion (tree);
extern tree decay_conversion (tree);
-extern tree default_conversion (tree);
extern tree build_class_member_access_expr (tree, tree, tree, bool);
extern tree finish_class_member_access_expr (tree, tree, bool);
extern tree build_x_indirect_ref (tree, const char *);
@@ -4342,7 +4336,6 @@ extern bool at_least_as_qualified_p (tree, tree);
extern void cp_apply_type_quals_to_decl (int, tree);
extern tree build_ptrmemfunc1 (tree, tree, tree);
extern void expand_ptrmemfunc_cst (tree, tree *, tree *);
-extern tree pfn_from_ptrmemfunc (tree);
extern tree type_after_usual_arithmetic_conversions (tree, tree);
extern tree composite_pointer_type (tree, tree, tree, tree,
const char*);
diff --git a/gcc/cp/name-lookup.c b/gcc/cp/name-lookup.c
index 28b7c27a24f..e0ee7a2a4e1 100644
--- a/gcc/cp/name-lookup.c
+++ b/gcc/cp/name-lookup.c
@@ -1789,7 +1789,7 @@ binding_for_name (cxx_scope *scope, tree name)
return NULL_TREE if this not in namespace scope (in namespace
scope, a using decl might extend any previous bindings). */
-tree
+static tree
push_using_decl (tree scope, tree name)
{
tree decl;
diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c
index 40ebbe5cca7..d3d8961cfd0 100644
--- a/gcc/cp/pt.c
+++ b/gcc/cp/pt.c
@@ -2451,7 +2451,7 @@ end_template_decl (void)
/* Given a template argument vector containing the template PARMS.
The innermost PARMS are given first. */
-tree
+static tree
current_template_args (void)
{
tree header;
@@ -10710,7 +10710,7 @@ more_specialized_fn (tree pat1, tree pat2, int len)
FULL_ARGS is the full set of template arguments that triggers this
partial ordering. */
-int
+static int
more_specialized_class (tree pat1, tree pat2, tree full_args)
{
tree targs;
@@ -11138,7 +11138,7 @@ do_decl_instantiation (tree decl, tree storage)
/*expl_inst_class_mem_p=*/false);
}
-void
+static void
mark_class_instantiated (tree t, int extern_p)
{
SET_CLASSTYPE_EXPLICIT_INSTANTIATION (t);
diff --git a/gcc/cp/typeck.c b/gcc/cp/typeck.c
index e2853de98e9..792b919a9aa 100644
--- a/gcc/cp/typeck.c
+++ b/gcc/cp/typeck.c
@@ -43,6 +43,7 @@ Boston, MA 02110-1301, USA. */
#include "convert.h"
#include "c-common.h"
+static tree pfn_from_ptrmemfunc (tree);
static tree convert_for_assignment (tree, tree, const char *, tree, int);
static tree cp_pointer_int_sum (enum tree_code, tree, tree);
static tree rationalize_conditional_expr (enum tree_code, tree);
@@ -1422,7 +1423,7 @@ decay_conversion (tree exp)
return exp;
}
-tree
+static tree
default_conversion (tree exp)
{
exp = decay_conversion (exp);
@@ -5963,7 +5964,7 @@ expand_ptrmemfunc_cst (tree cst, tree *delta, tree *pfn)
/* Return an expression for PFN from the pointer-to-member function
given by T. */
-tree
+static tree
pfn_from_ptrmemfunc (tree t)
{
if (TREE_CODE (t) == PTRMEM_CST)