summaryrefslogtreecommitdiff
path: root/gcc/c-common.c
diff options
context:
space:
mode:
authorManuel López-Ibáñez <manu@gcc.gnu.org>2009-07-07 02:10:19 +0000
committerManuel López-Ibáñez <manu@gcc.gnu.org>2009-07-07 02:10:19 +0000
commitfab922b1f55fe7766a375d0ee28a1c48f3185250 (patch)
tree75f96edfe80b6d74b595292cb3f885c6a8ade502 /gcc/c-common.c
parent56131eb5a0492df3fd6421db599ed6f3b42545c6 (diff)
downloadgcc-fab922b1f55fe7766a375d0ee28a1c48f3185250.tar.gz
c-lex.c: Replace %H by an explicit location.
2009-07-07 Manuel López-Ibáñez <manu@gcc.gnu.org> * c-lex.c: Replace %H by an explicit location. Update all calls. * c-common.c: Likewise. * c-decl.c: Likewise. * c-typeck.c: Likewise. * fold-const.c: Likewise. * gimplify.c: Likewise. * stmt.c: Likewise. * tree-cfg.c: Likewise. * tree-ssa-loop-niter.c: Likewise. * tree-vrp.c: Likewise. * value-prof.c: Likewise. java/ * jcf-parse.c: Replace %H by an explicit location. Update all calls. objc/ * objc-act.c: Replace %H by an explicit location. Update all calls. testsuite/ * gcc.dg/plugin/selfassign.c: Replace %H by an explicit location. Update all calls. * g++.dg/plugin/selfassign.c: Likewise. From-SVN: r149310
Diffstat (limited to 'gcc/c-common.c')
-rw-r--r--gcc/c-common.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/gcc/c-common.c b/gcc/c-common.c
index 1ff92920b65..772d9687bf8 100644
--- a/gcc/c-common.c
+++ b/gcc/c-common.c
@@ -5480,8 +5480,8 @@ c_do_switch_warnings (splay_tree cases, location_t switch_location,
default_node = splay_tree_lookup (cases, (splay_tree_key) NULL);
if (!default_node)
- warning (OPT_Wswitch_default, "%Hswitch missing default case",
- &switch_location);
+ warning_at (switch_location, OPT_Wswitch_default,
+ "switch missing default case");
/* From here on, we only care about about enumerated types. */
if (!type || TREE_CODE (type) != ENUMERAL_TYPE)
@@ -8258,13 +8258,12 @@ c_warn_unused_result (gimple_seq seq)
location_t loc = gimple_location (g);
if (fdecl)
- warning (0, "%Hignoring return value of %qD, "
- "declared with attribute warn_unused_result",
- &loc, fdecl);
+ warning_at (loc, 0, "ignoring return value of %qD, "
+ "declared with attribute warn_unused_result",
+ fdecl);
else
- warning (0, "%Hignoring return value of function "
- "declared with attribute warn_unused_result",
- &loc);
+ warning_at (loc, 0, "ignoring return value of function "
+ "declared with attribute warn_unused_result");
}
break;