summaryrefslogtreecommitdiff
path: root/gcc/cp/name-lookup.c
diff options
context:
space:
mode:
authordj <dj@138bc75d-0d04-0410-961f-82ee72b054a4>2005-04-23 21:29:07 +0000
committerdj <dj@138bc75d-0d04-0410-961f-82ee72b054a4>2005-04-23 21:29:07 +0000
commitc3ceba8e8139354ec6e7fb9510bb3541d5baac23 (patch)
tree754eeef62542ff45392c946c655cc40c38bd1bed /gcc/cp/name-lookup.c
parentd9253f48c6643c6b0a45f9c41cd7166986e45752 (diff)
downloadgcc-c3ceba8e8139354ec6e7fb9510bb3541d5baac23.tar.gz
* diagnostic.c (warning): Accept parameter to classify warning option.
(warning0): New, for when a pointer to an error() like function is needed. * errors.c (warning): Likewise. * errors.h (warning, warning0): Adjust prototypes. * toplev.h (warning, warning0): Likewise. * attribs.c, builtins.c, c-common.c, c-decl.c, c-format.c, c-gimplify.c, c-lex.c, c-objc-common.c, c-opts.c, c-parser.c, c-pragma.c, c-typeck.c, calls.c, cgraph.c, coverage.c, emit-rtl.c, fold-const.c, fortran/trans-decl.c, function.c, gcse.c, genautomata.c, haifa-sched.c, opts.c, passes.c, regclass.c, reload1.c, stmt.c, stor-layout.c, toplev.c, tree-cfg.c, tree-dump.c, tree-inline.c, tree-mudflap.c, tree-optimize.c, tree-ssa.c, tree.c, varasm.c: Adjust warning() callers. * config/alpha/alpha.c, config/arc/arc.c, config/arm/arm.c, config/avr/avr.c, config/bfin/bfin.c, config/c4x/c4x-c.c, config/c4x/c4x.c, config/cris/cris.c, config/darwin-c.c, config/darwin.c, config/darwin.h, config/h8300/h8300.c, config/i386/cygming.h, config/i386/djgpp.h, config/i386/i386.c, config/i386/winnt.c, config/ia64/ia64-c.c, config/ia64/ia64.c, config/ip2k/ip2k.c, config/m32r/m32r.c, config/m68hc11/m68hc11.c, config/m68k/m68k.c, config/mcore/mcore.c, config/mips/mips.c, config/mmix/mmix.c, config/ns32k/ns32k.c, config/pa/pa-hpux11.h, config/pa/pa.c, config/rs6000/aix43.h, config/rs6000/aix51.h, config/rs6000/aix52.h, config/rs6000/darwin.h, config/rs6000/rs6000-c.c, config/rs6000/rs6000.c, config/s390/s390.c, config/sh/sh.c, config/sh/sh.h, config/sh/symbian.c, config/sol2-c.c, config/sol2.c, config/stormy16/stormy16.c, config/v850/v850-c.c, config/v850/v850.c, config/xtensa/xtensa.c: Adjust warning() callers. * ada/misc.c: Adjust warning() callers. * cp/call.c, cp/class.c, cp/cvt.c, cp/decl.c, cp/decl2.c, cp/except.c, cp/friend.c, cp/init.c, cp/lex.c, cp/mangle.c, cp/method.c, cp/name-lookup.c, cp/parser.c, cp/repo.c, cp/rtti.c, cp/tree.c, cp/typeck.c, cp/typeck2.c: Adjust warning() callers. * fortran/trans-decl.c: Adjust warning() callers. * java/class.c, java/decl.c, java/expr.c, java/jcf-io.c, java/jcf-parse.c, java/jv-scan.c, java/parse.y: Adjust warning() callers. * objc/objc-act.c: Adjust warning() callers. * treelang/parse.y: Adjust warning() callers. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@98633 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/name-lookup.c')
-rw-r--r--gcc/cp/name-lookup.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/gcc/cp/name-lookup.c b/gcc/cp/name-lookup.c
index ce1d5b3b119..634645d7fa4 100644
--- a/gcc/cp/name-lookup.c
+++ b/gcc/cp/name-lookup.c
@@ -894,7 +894,7 @@ pushdecl (tree x)
/* OK */;
else
{
- warning ("extern declaration of %q#D doesn't match", x);
+ warning (0, "extern declaration of %q#D doesn't match", x);
cp_warning_at ("global declaration %q#D", oldglobal);
}
}
@@ -938,8 +938,8 @@ pushdecl (tree x)
if (warn_shadow && !err)
{
- warning ("declaration of %q#D shadows a parameter", x);
- warning ("%Jshadowed declaration is here", oldlocal);
+ warning (0, "declaration of %q#D shadows a parameter", x);
+ warning (0, "%Jshadowed declaration is here", oldlocal);
}
}
@@ -963,22 +963,22 @@ pushdecl (tree x)
if (member && !TREE_STATIC (member))
{
/* Location of previous decl is not useful in this case. */
- warning ("declaration of %qD shadows a member of 'this'",
+ warning (0, "declaration of %qD shadows a member of 'this'",
x);
}
else if (oldlocal != NULL_TREE
&& TREE_CODE (oldlocal) == VAR_DECL)
{
- warning ("declaration of %qD shadows a previous local", x);
- warning ("%Jshadowed declaration is here", oldlocal);
+ warning (0, "declaration of %qD shadows a previous local", x);
+ warning (0, "%Jshadowed declaration is here", oldlocal);
}
else if (oldglobal != NULL_TREE
&& TREE_CODE (oldglobal) == VAR_DECL)
/* XXX shadow warnings in outer-more namespaces */
{
- warning ("declaration of %qD shadows a global declaration",
+ warning (0, "declaration of %qD shadows a global declaration",
x);
- warning ("%Jshadowed declaration is here", oldglobal);
+ warning (0, "%Jshadowed declaration is here", oldglobal);
}
}
}
@@ -1092,7 +1092,7 @@ check_for_out_of_scope_variable (tree decl)
{
if (!DECL_ERROR_REPORTED (decl))
{
- warning ("name lookup of %qD changed", DECL_NAME (decl));
+ warning (0, "name lookup of %qD changed", DECL_NAME (decl));
cp_warning_at (" matches this %qD under ISO standard rules",
shadowed);
cp_warning_at (" matches this %qD under old rules", decl);
@@ -1861,7 +1861,7 @@ push_overloaded_decl (tree decl, int flags)
if (IS_AGGR_TYPE (t) && warn_shadow
&& (! DECL_IN_SYSTEM_HEADER (decl)
|| ! DECL_IN_SYSTEM_HEADER (old)))
- warning ("%q#D hides constructor for %q#T", decl, t);
+ warning (0, "%q#D hides constructor for %q#T", decl, t);
old = NULL_TREE;
}
else if (is_overloaded_fn (old))
@@ -3207,7 +3207,7 @@ parse_using_directive (tree namespace, tree attribs)
DECL_NAMESPACE_ASSOCIATIONS (namespace));
}
else
- warning ("%qD attribute directive ignored", name);
+ warning (0, "%qD attribute directive ignored", name);
}
}