aboutsummaryrefslogtreecommitdiff
path: root/gcc/function.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2003-09-20 22:07:20 -0700
committerRichard Henderson <rth@gcc.gnu.org>2003-09-20 22:07:20 -0700
commitddd2d57e722237230da8eea70a2fcecb11bd0f81 (patch)
tree28f355780724c452ad42bb81a3672b2e8010c989 /gcc/function.c
parentccea753c0563b847b42d9ca5fc1b8afaee49f343 (diff)
downloadgcc-ddd2d57e722237230da8eea70a2fcecb11bd0f81.zip
gcc-ddd2d57e722237230da8eea70a2fcecb11bd0f81.tar.gz
gcc-ddd2d57e722237230da8eea70a2fcecb11bd0f81.tar.bz2
c-format.c (gcc_diag_char_table): Add %J.
* c-format.c (gcc_diag_char_table): Add %J. (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Likewise. (check_format_types): Fix wanted_type name lookup. (init_dynamic_diag_info): Setup %J. * diagnostic.c (text_specifies_location): Implement %J. * c-common.c, c-decl.c, c-objc-common.c, c-pragma.c, calls.c, dwarfout.c, expr.c, function.c, stmt.c, stor-layout.c, toplev.c, tree-inline.c, tree-optimize.c, varasm.c, config/arm/pe.c, config/i386/winnt.c, config/ia64/ia64.c, config/mcore/mcore.c, config/v850/v850.c, objc/objc-act.c: Use %J in diagnostics. * tree-inline.c: Include intl.h (inline_forbidden_p_1): Fix i18n of inline_forbidden_reason. * Makefile.in (tree-inline.o): Update. cp/ * decl.c, decl2.c, pt.c: Use %J in diagnostics. java/ * check-init.c, class.c, decl.c, expr.c: Use %J in diagnostics. testsuite/ * gcc.dg/format/gcc_diag-1.c: Add tests for %J. From-SVN: r71619
Diffstat (limited to 'gcc/function.c')
-rw-r--r--gcc/function.c18
1 files changed, 8 insertions, 10 deletions
diff --git a/gcc/function.c b/gcc/function.c
index 344e31b..baec4ab 100644
--- a/gcc/function.c
+++ b/gcc/function.c
@@ -880,8 +880,7 @@ assign_temp (tree type_or_decl, int keep, int memory_required,
if (decl && size == -1
&& TREE_CODE (TYPE_SIZE_UNIT (type)) == INTEGER_CST)
{
- error ("%Hsize of variable '%D' is too large",
- &DECL_SOURCE_LOCATION (decl), decl);
+ error ("%Jsize of variable '%D' is too large", decl, decl);
size = 1;
}
@@ -5610,15 +5609,15 @@ uninitialized_vars_warning (tree block)
if we want to warn. */
&& (DECL_INITIAL (decl) == NULL_TREE || lang_hooks.decl_uninit (decl))
&& regno_uninitialized (REGNO (DECL_RTL (decl))))
- warning ("%H'%D' might be used uninitialized in this function",
- &DECL_SOURCE_LOCATION (decl), decl);
+ warning ("%J'%D' might be used uninitialized in this function",
+ decl, decl);
if (extra_warnings
&& TREE_CODE (decl) == VAR_DECL
&& DECL_RTL (decl) != 0
&& GET_CODE (DECL_RTL (decl)) == REG
&& regno_clobbered_at_setjmp (REGNO (DECL_RTL (decl))))
- warning ("%Hvariable '%D' might be clobbered by `longjmp' or `vfork'",
- &DECL_SOURCE_LOCATION (decl), decl);
+ warning ("%Jvariable '%D' might be clobbered by `longjmp' or `vfork'",
+ decl, decl);
}
for (sub = BLOCK_SUBBLOCKS (block); sub; sub = TREE_CHAIN (sub))
uninitialized_vars_warning (sub);
@@ -5636,8 +5635,8 @@ setjmp_args_warning (void)
if (DECL_RTL (decl) != 0
&& GET_CODE (DECL_RTL (decl)) == REG
&& regno_clobbered_at_setjmp (REGNO (DECL_RTL (decl))))
- warning ("%Hargument '%D' might be clobbered by `longjmp' or `vfork'",
- &DECL_SOURCE_LOCATION (decl), decl);
+ warning ("%Jargument '%D' might be clobbered by `longjmp' or `vfork'",
+ decl, decl);
}
/* If this function call setjmp, put all vars into the stack
@@ -6895,8 +6894,7 @@ expand_function_end (void)
decl; decl = TREE_CHAIN (decl))
if (! TREE_USED (decl) && TREE_CODE (decl) == PARM_DECL
&& DECL_NAME (decl) && ! DECL_ARTIFICIAL (decl))
- warning ("%Hunused parameter '%D'",
- &DECL_SOURCE_LOCATION (decl), decl);
+ warning ("%Junused parameter '%D'", decl, decl);
}
/* Delete handlers for nonlocal gotos if nothing uses them. */