builtins.c, [...]: Avoid "`" as left quote, using "'" or %q, %< and %> as appropriate.

* builtins.c, c-common.c, c-decl.c, c-format.c, c-format.h,
	c-parse.in, c-pch.c, c-pragma.c, collect2.c, final.c, gcc.c,
	gcov.c, opts.c, pretty-print.h, protoize.c, reg-stack.c, rtl.c,
	tlink.c, config/alpha/alpha.c, config/arc/arc.c, config/arm/arm.c,
	config/avr/avr.c, config/c4x/c4x.c, config/darwin.c,
	config/frv/frv.c, config/h8300/h8300.c, config/i386/i386.c,
	config/i386/winnt.c, config/ia64/ia64.c, config/ip2k/ip2k.c,
	config/iq2000/iq2000.c, config/m32r/m32r.c,
	config/m68hc11/m68hc11.c, config/m68k/m68k.c, config/m68k/m68k.h,
	config/mcore/mcore.c, config/mips/mips.c, config/mmix/mmix.c,
	config/ns32k/ns32k.c, config/rs6000/host-darwin.c,
	config/rs6000/rs6000.c, config/s390/s390.c, config/sh/sh.c,
	config/sh/symbian.c, config/stormy16/stormy16.c,
	config/v850/v850.c: Avoid "`" as left quote, using "'" or %q, %<
	and %> as appropriate.  Use %' as apostrophe in diagnostics where
	applicable.  Use %< and %> in place of '' quotes where applicable.
	Use %qs in place of %<%s%>.  Consistently quote __builtin function
	names.

ada:
	* misc.c (gnat_handle_option): Use %< and %> for quoting in
	warning message.

cp:
	* call.c, class.c, decl.c, decl2.c, error.c, mangle.c, parser.c,
	pt.c, search.c, semantics.c, typeck.c: Use %q, %< and %> for
	quoting in diagnostics.
	* parser.c (cp_parser_sizeof_operand): Use '' instead of `' for
	quoting in printf format.
	* decl.c (duplicate_decls, start_decl): Use %qD instead of
	unquoted %D.

objc:
	* objc-act.c: Use %q, %< and %> for quoting in diagnostics.

testsuite:
	* gcc.dg/builtin-prefetch-1.c: Adjust expected messages.

From-SVN: r90337
This commit is contained in:
Joseph Myers 2004-11-09 10:13:30 +00:00 committed by Joseph Myers
parent 55a9c4b2fc
commit 9e637a2679
65 changed files with 360 additions and 316 deletions

View File

@ -1,3 +1,24 @@
2004-11-09 Joseph S. Myers <joseph@codesourcery.com>
* builtins.c, c-common.c, c-decl.c, c-format.c, c-format.h,
c-parse.in, c-pch.c, c-pragma.c, collect2.c, final.c, gcc.c,
gcov.c, opts.c, pretty-print.h, protoize.c, reg-stack.c, rtl.c,
tlink.c, config/alpha/alpha.c, config/arc/arc.c, config/arm/arm.c,
config/avr/avr.c, config/c4x/c4x.c, config/darwin.c,
config/frv/frv.c, config/h8300/h8300.c, config/i386/i386.c,
config/i386/winnt.c, config/ia64/ia64.c, config/ip2k/ip2k.c,
config/iq2000/iq2000.c, config/m32r/m32r.c,
config/m68hc11/m68hc11.c, config/m68k/m68k.c, config/m68k/m68k.h,
config/mcore/mcore.c, config/mips/mips.c, config/mmix/mmix.c,
config/ns32k/ns32k.c, config/rs6000/host-darwin.c,
config/rs6000/rs6000.c, config/s390/s390.c, config/sh/sh.c,
config/sh/symbian.c, config/stormy16/stormy16.c,
config/v850/v850.c: Avoid "`" as left quote, using "'" or %q, %<
and %> as appropriate. Use %' as apostrophe in diagnostics where
applicable. Use %< and %> in place of '' quotes where applicable.
Use %qs in place of %<%s%>. Consistently quote __builtin function
names.
2004-11-09 Hans-Peter Nilsson <hp@bitrange.com>
* gdbinit.in (pbb, pbm): New macros.

View File

@ -1,3 +1,8 @@
2004-11-09 Joseph S. Myers <joseph@codesourcery.com>
* misc.c (gnat_handle_option): Use %< and %> for quoting in
warning message.
2004-11-08 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
* a-numaux-x86.adb (Tan): Fix fdivp syntax.

View File

@ -296,7 +296,7 @@ gnat_handle_option (size_t scode, const char *arg, int value ATTRIBUTE_UNUSED)
break;
case OPT_gant:
warning ("`-gnat' misspelled as `-gant'");
warning ("%<-gnat%> misspelled as %<-gant%>");
/* ... fall through ... */

View File

@ -929,7 +929,7 @@ expand_builtin_prefetch (tree arglist)
/* Argument 1 must be either zero or one. */
if (INTVAL (op1) != 0 && INTVAL (op1) != 1)
{
warning ("invalid second arg to __builtin_prefetch; using zero");
warning ("invalid second arg to %<__builtin_prefetch%>; using zero");
op1 = const0_rtx;
}
@ -943,7 +943,7 @@ expand_builtin_prefetch (tree arglist)
/* Argument 2 must be 0, 1, 2, or 3. */
if (INTVAL (op2) < 0 || INTVAL (op2) > 3)
{
warning ("invalid third arg to __builtin_prefetch; using zero");
warning ("invalid third arg to %<__builtin_prefetch%>; using zero");
op2 = const0_rtx;
}
@ -5486,7 +5486,7 @@ expand_builtin (tree exp, rtx target, rtx subtarget, enum machine_mode mode,
if (value != const1_rtx)
{
error ("__builtin_longjmp second argument must be 1");
error ("%<__builtin_longjmp%> second argument must be 1");
return const0_rtx;
}

View File

@ -4311,7 +4311,7 @@ handle_mode_attribute (tree *node, tree name, tree args,
if (mode == VOIDmode)
{
error ("unknown machine mode %<%s%>", p);
error ("unknown machine mode %qs", p);
return NULL_TREE;
}
@ -4342,7 +4342,7 @@ handle_mode_attribute (tree *node, tree name, tree args,
}
if (!valid_mode)
{
error ("unable to emulate %<%s%>", p);
error ("unable to emulate %qs", p);
return NULL_TREE;
}
@ -4352,7 +4352,7 @@ handle_mode_attribute (tree *node, tree name, tree args,
if (!targetm.valid_pointer_mode (mode))
{
error ("invalid pointer mode %<%s%>", p);
error ("invalid pointer mode %qs", p);
return NULL_TREE;
}

View File

@ -1005,14 +1005,14 @@ diagnose_arglist_conflict (tree newdecl, tree olddecl,
if (TREE_CHAIN (t) == 0
&& TYPE_MAIN_VARIANT (type) != void_type_node)
{
inform ("a parameter list with an ellipsis can't match "
inform ("a parameter list with an ellipsis can%'t match "
"an empty parameter name list declaration");
break;
}
if (c_type_promotes_to (type) != type)
{
inform ("an argument type that has a default promotion can't match "
inform ("an argument type that has a default promotion can%'t match "
"an empty parameter name list declaration");
break;
}
@ -5063,7 +5063,7 @@ grokfield (struct c_declarator *declarator, struct c_declspecs *declspecs,
return NULL_TREE;
}
if (pedantic)
pedwarn ("ISO C doesn't support unnamed structs/unions");
pedwarn ("ISO C doesn%'t support unnamed structs/unions");
}
value = grokdeclarator (declarator, declspecs, FIELD, false,

View File

@ -212,7 +212,7 @@ decode_format_attr (tree args, function_format_info *info, int validated_p)
if (!get_constant (first_arg_num_expr, &info->first_arg_num, validated_p))
{
error ("'...' has invalid operand number");
error ("%<...%> has invalid operand number");
return false;
}
@ -2496,7 +2496,7 @@ handle_format_attribute (tree *node, tree ARG_UNUSED (name), tree args,
if (arg_num != info.first_arg_num)
{
if (!(flags & (int) ATTR_FLAG_BUILT_IN))
error ("args to be formatted is not '...'");
error ("args to be formatted is not %<...%>");
*no_add_attrs = true;
return NULL_TREE;
}

View File

@ -161,7 +161,7 @@ typedef struct
nonzero character that may be found in flags2 if it describes the
flag when used with certain formats only. If the latter, only
the first such entry found that applies to the current conversion
specifier is used; the values of `name' and `long_name' it supplies
specifier is used; the values of 'name' and 'long_name' it supplies
will be used, if non-NULL and the standard version is higher than
the unpredicated one, for any pedantic warning. For example, 'o'
for strftime formats (meaning 'O' is an extension over C99). */
@ -170,10 +170,10 @@ typedef struct
be skipped ('=' in strfmon), zero otherwise. */
int skip_next_char;
/* The name to use for this flag in diagnostic messages. For example,
N_("`0' flag"), N_("field width"). */
N_("'0' flag"), N_("field width"). */
const char *name;
/* Long name for this flag in diagnostic messages; currently only used for
"ISO C does not support ...". For example, N_("the `I' printf flag"). */
"ISO C does not support ...". For example, N_("the 'I' printf flag"). */
const char *long_name;
/* The standard version in which it appeared. */
enum format_std_version std;

View File

@ -733,7 +733,7 @@ primary:
c = fold ($3.value);
STRIP_NOPS (c);
if (TREE_CODE (c) != INTEGER_CST)
error ("first argument to __builtin_choose_expr not"
error ("first argument to %<__builtin_choose_expr%> not"
" a constant");
$$ = integer_zerop (c) ? $7 : $5;
}

View File

@ -127,7 +127,7 @@ pch_init (void)
f = fopen (pch_file, "w+b");
if (f == NULL)
fatal_error ("can't create precompiled header %s: %m", pch_file);
fatal_error ("can%'t create precompiled header %s: %m", pch_file);
pch_outfile = f;
gcc_assert (strlen (host_machine) < 256
@ -155,7 +155,7 @@ pch_init (void)
|| fwrite (target_machine, v.target_machine_length, 1, f) != 1
|| fwrite (version_string, v.version_length, 1, f) != 1
|| fwrite (target_validity, v.target_data_length, 1, f) != 1)
fatal_error ("can't write to %s: %m", pch_file);
fatal_error ("can%'t write to %s: %m", pch_file);
/* We need to be able to re-read the output. */
/* The driver always provides a valid -o option. */
@ -190,12 +190,12 @@ c_common_write_pch (void)
h.asm_size = asm_file_end - asm_file_startpos;
if (fwrite (&h, sizeof (h), 1, pch_outfile) != 1)
fatal_error ("can't write %s: %m", pch_file);
fatal_error ("can%'t write %s: %m", pch_file);
buf = xmalloc (16384);
if (fseek (asm_out_file, asm_file_startpos, SEEK_SET) != 0)
fatal_error ("can't seek in %s: %m", asm_file_name);
fatal_error ("can%'t seek in %s: %m", asm_file_name);
for (written = asm_file_startpos; written < asm_file_end; )
{
@ -203,23 +203,23 @@ c_common_write_pch (void)
if (size > 16384)
size = 16384;
if (fread (buf, size, 1, asm_out_file) != 1)
fatal_error ("can't read %s: %m", asm_file_name);
fatal_error ("can%'t read %s: %m", asm_file_name);
if (fwrite (buf, size, 1, pch_outfile) != 1)
fatal_error ("can't write %s: %m", pch_file);
fatal_error ("can%'t write %s: %m", pch_file);
written += size;
}
free (buf);
/* asm_out_file can be written afterwards, so fseek to clear
_IOREAD flag. */
if (fseek (asm_out_file, 0, SEEK_END) != 0)
fatal_error ("can't seek in %s: %m", asm_file_name);
fatal_error ("can%'t seek in %s: %m", asm_file_name);
gt_pch_save (pch_outfile);
cpp_write_pch_state (parse_in, pch_outfile);
if (fseek (pch_outfile, 0, SEEK_SET) != 0
|| fwrite (get_ident (), IDENT_LENGTH, 1, pch_outfile) != 1)
fatal_error ("can't write %s: %m", pch_file);
fatal_error ("can%'t write %s: %m", pch_file);
fclose (pch_outfile);
}
@ -245,7 +245,7 @@ c_common_valid_pch (cpp_reader *pfile, const char *name, int fd)
sizeread = read (fd, ident, IDENT_LENGTH);
if (sizeread == -1)
fatal_error ("can't read %s: %m", name);
fatal_error ("can%'t read %s: %m", name);
else if (sizeread != IDENT_LENGTH)
return 2;
@ -273,12 +273,12 @@ c_common_valid_pch (cpp_reader *pfile, const char *name, int fd)
/* At this point, we know it's a PCH file, so it ought to be long enough
that we can read a c_pch_validity structure. */
if (read (fd, &v, sizeof (v)) != sizeof (v))
fatal_error ("can't read %s: %m", name);
fatal_error ("can%'t read %s: %m", name);
strings_length = (v.host_machine_length + v.target_machine_length
+ v.version_length);
if (read (fd, short_strings, strings_length) != strings_length)
fatal_error ("can't read %s: %m", name);
fatal_error ("can%'t read %s: %m", name);
if (v.host_machine_length != strlen (host_machine)
|| memcmp (host_machine, short_strings, strlen (host_machine)) != 0)
{
@ -362,7 +362,7 @@ c_common_valid_pch (cpp_reader *pfile, const char *name, int fd)
if ((size_t) read (fd, this_file_data, v.target_data_length)
!= v.target_data_length)
fatal_error ("can't read %s: %m", name);
fatal_error ("can%'t read %s: %m", name);
msg = targetm.pch_valid_p (this_file_data, v.target_data_length);
free (this_file_data);
if (msg != NULL)
@ -495,7 +495,7 @@ c_common_pch_pragma (cpp_reader *pfile)
fd = open (name, O_RDONLY | O_BINARY, 0666);
if (fd == -1)
fatal_error ("%s: couldn't open PCH file: %m\n", name);
fatal_error ("%s: couldn%'t open PCH file: %m\n", name);
if (c_common_valid_pch (pfile, name, fd) != 1)
{

View File

@ -618,7 +618,7 @@ handle_pragma_visibility (cpp_reader *dummy ATTRIBUTE_UNUSED)
visibility_options.inpragma = 1;
}
if (c_lex (&x) != CPP_CLOSE_PAREN)
GCC_BAD ("missing '(' after %<#pragma GCC visibility push%> - ignored");
GCC_BAD ("missing %<(%> after %<#pragma GCC visibility push%> - ignored");
}
}
if (c_lex (&x) != CPP_EOF)

View File

@ -1562,7 +1562,7 @@ collect_execute (const char *prog, char **argv, const char *redir)
since we might not end up needing something that we could not find. */
if (argv[0] == 0)
fatal ("cannot find `%s'", prog);
fatal ("cannot find '%s'", prog);
if (redir)
{
@ -2039,7 +2039,7 @@ scan_prog_file (const char *prog_name, enum pass which_pass)
/* If we do not have an `nm', complain. */
if (nm_file_name == 0)
fatal ("cannot find `nm'");
fatal ("cannot find 'nm'");
nm_argv[argc++] = nm_file_name;
if (NM_FLAGS[0] != '\0')
@ -2206,7 +2206,7 @@ scan_libraries (const char *prog_name)
/* If we do not have an `ldd', complain. */
if (ldd_file_name == 0)
{
error ("cannot find `ldd'");
error ("cannot find 'ldd'");
return;
}

View File

@ -303,7 +303,7 @@ override_options (void)
else if (! strcmp (alpha_tp_string, "i"))
alpha_tp = ALPHA_TP_INSN;
else
error ("bad value `%s' for -mtrap-precision switch", alpha_tp_string);
error ("bad value %qs for -mtrap-precision switch", alpha_tp_string);
}
if (alpha_fprm_string)
@ -317,7 +317,7 @@ override_options (void)
else if (! strcmp (alpha_fprm_string,"d"))
alpha_fprm = ALPHA_FPRM_DYN;
else
error ("bad value `%s' for -mfp-rounding-mode switch",
error ("bad value %qs for -mfp-rounding-mode switch",
alpha_fprm_string);
}
@ -332,7 +332,7 @@ override_options (void)
else if (strcmp (alpha_fptm_string, "sui") == 0)
alpha_fptm = ALPHA_FPTM_SUI;
else
error ("bad value `%s' for -mfp-trap-mode switch", alpha_fptm_string);
error ("bad value %qs for -mfp-trap-mode switch", alpha_fptm_string);
}
if (alpha_tls_size_string)
@ -344,7 +344,7 @@ override_options (void)
else if (strcmp (alpha_tls_size_string, "64") == 0)
alpha_tls_size = 64;
else
error ("bad value `%s' for -mtls-size switch", alpha_tls_size_string);
error ("bad value %qs for -mtls-size switch", alpha_tls_size_string);
}
alpha_cpu
@ -363,7 +363,7 @@ override_options (void)
break;
}
if (! cpu_table [i].name)
error ("bad value `%s' for -mcpu switch", alpha_cpu_string);
error ("bad value %qs for -mcpu switch", alpha_cpu_string);
}
if (alpha_tune_string)
@ -375,7 +375,7 @@ override_options (void)
break;
}
if (! cpu_table [i].name)
error ("bad value `%s' for -mcpu switch", alpha_tune_string);
error ("bad value %qs for -mcpu switch", alpha_tune_string);
}
/* Do some sanity checks on the above options. */
@ -457,7 +457,7 @@ override_options (void)
}
else
{
warning ("bad value `%s' for -mmemory-latency", alpha_mlat_string);
warning ("bad value %qs for -mmemory-latency", alpha_mlat_string);
lat = 3;
}

View File

@ -391,14 +391,14 @@ arc_handle_interrupt_attribute (tree *node ATTRIBUTE_UNUSED,
if (TREE_CODE (value) != STRING_CST)
{
warning ("argument of `%s' attribute is not a string constant",
warning ("argument of %qs attribute is not a string constant",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
else if (strcmp (TREE_STRING_POINTER (value), "ilink1")
&& strcmp (TREE_STRING_POINTER (value), "ilink2"))
{
warning ("argument of `%s' attribute is not \"ilink1\" or \"ilink2\"",
warning ("argument of %qs attribute is not \"ilink1\" or \"ilink2\"",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -2605,7 +2605,7 @@ arm_handle_fndecl_attribute (tree *node, tree name, tree args ATTRIBUTE_UNUSED,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -2623,7 +2623,7 @@ arm_handle_isr_attribute (tree *node, tree name, tree args, int flags,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -2637,7 +2637,7 @@ arm_handle_isr_attribute (tree *node, tree name, tree args, int flags,
{
if (arm_isr_value (args) == ARM_FT_UNKNOWN)
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
}
@ -2664,7 +2664,7 @@ arm_handle_isr_attribute (tree *node, tree name, tree args, int flags,
}
else
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
}
}
}

View File

@ -4511,7 +4511,7 @@ avr_handle_progmem_attribute (tree *node, tree name,
}
else
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
}
@ -4530,7 +4530,7 @@ avr_handle_fndecl_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -4612,7 +4612,7 @@ static void
avr_file_start (void)
{
if (avr_asm_only_p)
error ("MCU `%s' supported for assembler only", avr_mcu_name);
error ("MCU %qs supported for assembler only", avr_mcu_name);
default_file_start ();

View File

@ -4496,7 +4496,7 @@ c4x_handle_fntype_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != FUNCTION_TYPE)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -1214,7 +1214,7 @@ darwin_handle_weak_import_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
else

View File

@ -9613,7 +9613,7 @@ frv_int_to_acc (enum insn_code icode, int opnum, rtx opval)
if (! (*insn_data[icode].operand[opnum].predicate) (reg, VOIDmode))
{
error ("inappropriate accumulator for `%s'", insn_data[icode].name);
error ("inappropriate accumulator for %qs", insn_data[icode].name);
return NULL_RTX;
}
return reg;
@ -9702,12 +9702,12 @@ frv_check_constant_argument (enum insn_code icode, int opnum, rtx opval)
{
if (GET_CODE (opval) != CONST_INT)
{
error ("`%s' expects a constant argument", insn_data[icode].name);
error ("%qs expects a constant argument", insn_data[icode].name);
return FALSE;
}
if (! (*insn_data[icode].operand[opnum].predicate) (opval, VOIDmode))
{
error ("constant argument out of range for `%s'", insn_data[icode].name);
error ("constant argument out of range for %qs", insn_data[icode].name);
return FALSE;
}
return TRUE;

View File

@ -5752,7 +5752,7 @@ h8300_handle_fndecl_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -5776,7 +5776,7 @@ h8300_handle_eightbit_data_attribute (tree *node, tree name,
}
else
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -5799,7 +5799,7 @@ h8300_handle_tiny_data_attribute (tree *node, tree name,
}
else
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -1271,10 +1271,10 @@ override_options (void)
error ("bad value (%s) for -masm= switch", ix86_asm_string);
}
if ((TARGET_64BIT == 0) != (ix86_cmodel == CM_32))
error ("code model `%s' not supported in the %s bit mode",
error ("code model %qs not supported in the %s bit mode",
ix86_cmodel_string, TARGET_64BIT ? "64" : "32");
if (ix86_cmodel == CM_LARGE)
sorry ("code model `large' not supported yet");
sorry ("code model %<large%> not supported yet");
if ((TARGET_64BIT != 0) != ((target_flags & MASK_64BIT) != 0))
sorry ("%i-bit mode not compiled in",
(target_flags & MASK_64BIT) ? 64 : 32);
@ -1682,7 +1682,7 @@ ix86_handle_cdecl_attribute (tree *node, tree name,
&& TREE_CODE (*node) != FIELD_DECL
&& TREE_CODE (*node) != TYPE_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -1710,7 +1710,7 @@ ix86_handle_cdecl_attribute (tree *node, tree name,
if (TARGET_64BIT)
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -1728,7 +1728,7 @@ ix86_handle_regparm_attribute (tree *node, tree name, tree args,
&& TREE_CODE (*node) != FIELD_DECL
&& TREE_CODE (*node) != TYPE_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -1739,13 +1739,13 @@ ix86_handle_regparm_attribute (tree *node, tree name, tree args,
cst = TREE_VALUE (args);
if (TREE_CODE (cst) != INTEGER_CST)
{
warning ("`%s' attribute requires an integer constant argument",
warning ("%qs attribute requires an integer constant argument",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
else if (compare_tree_int (cst, REGPARM_MAX) > 0)
{
warning ("argument to `%s' attribute larger than %d",
warning ("argument to %qs attribute larger than %d",
IDENTIFIER_POINTER (name), REGPARM_MAX);
*no_add_attrs = true;
}
@ -6538,7 +6538,7 @@ print_operand (FILE *file, rtx x, int code)
return;
}
default:
output_operand_lossage ("invalid operand code `%c'", code);
output_operand_lossage ("invalid operand code '%c'", code);
}
}
@ -14507,7 +14507,7 @@ ix86_handle_struct_attribute (tree *node, tree name,
if (!(type && (TREE_CODE (*type) == RECORD_TYPE
|| TREE_CODE (*type) == UNION_TYPE)))
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -14516,7 +14516,7 @@ ix86_handle_struct_attribute (tree *node, tree name,
|| ((is_attribute_p ("gcc_struct", name)
&& lookup_attribute ("ms_struct", TYPE_ATTRIBUTES (*type)))))
{
warning ("`%s' incompatible attribute ignored",
warning ("%qs incompatible attribute ignored",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -71,7 +71,7 @@ ix86_handle_shared_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != VAR_DECL)
{
warning ("`%s' attribute only applies to variables",
warning ("%qs attribute only applies to variables",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -296,7 +296,7 @@ i386_pe_mark_dllimport (tree decl)
abort ();
if (i386_pe_dllexport_name_p (oldname))
{
error ("`%s' declared as both exported to and imported from a DLL",
error ("%qs declared as both exported to and imported from a DLL",
IDENTIFIER_POINTER (DECL_NAME (decl)));
return;
}

View File

@ -477,7 +477,7 @@ ia64_handle_model_attribute (tree *node, tree name, tree args, int flags ATTRIBU
}
else
{
warning ("invalid argument of `%s' attribute",
warning ("invalid argument of %qs attribute",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -509,7 +509,7 @@ ia64_handle_model_attribute (tree *node, tree name, tree args, int flags ATTRIBU
break;
default:
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
break;
}

View File

@ -3160,7 +3160,7 @@ ip2k_handle_progmem_attribute (tree *node, tree name,
}
else
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
}
@ -3178,7 +3178,7 @@ ip2k_handle_fndecl_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -2842,7 +2842,7 @@ expand_one_builtin (enum insn_code icode, rtx target, tree arglist,
op[i] = expand_expr (arg[i], NULL_RTX, VOIDmode, 0);
mode[i] = insn_data[icode].operand[i].mode;
if (code[i] == CONST_INT && GET_CODE (op[i]) != CONST_INT)
error ("argument `%d' is not a constant", i + 1);
error ("argument %qd is not a constant", i + 1);
if (code[i] == REG
&& ! (*insn_data[icode].operand[i].predicate) (op[i], mode[i]))
op[i] = copy_to_mode_reg (mode[i], op[i]);

View File

@ -353,7 +353,7 @@ m32r_handle_model_attribute (tree *node ATTRIBUTE_UNUSED, tree name,
&& arg != large_ident1
&& arg != large_ident2)
{
warning ("invalid argument of `%s' attribute",
warning ("invalid argument of %qs attribute",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -1311,7 +1311,7 @@ m68hc11_handle_page0_attribute (tree *node, tree name,
}
else
{
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -1347,7 +1347,7 @@ m68hc11_handle_fntype_attribute (tree *node, tree name,
&& TREE_CODE (*node) != FIELD_DECL
&& TREE_CODE (*node) != TYPE_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -1432,13 +1432,13 @@ m68hc11_encode_section_info (tree decl, rtx rtl, int first ATTRIBUTE_UNUSED)
trap_handler = lookup_attribute ("trap", func_attr) != NULL_TREE;
if (trap_handler && is_far)
{
warning ("`trap' and `far' attributes are not compatible, ignoring `far'");
warning ("%<trap%> and %<far%> attributes are not compatible, ignoring %<far%>");
trap_handler = 0;
}
if (trap_handler)
{
if (trap_handler_symbol != 0)
warning ("`trap' attribute is already used");
warning ("%<trap%> attribute is already used");
else
trap_handler_symbol = XEXP (rtl, 0);
}

View File

@ -285,7 +285,7 @@ m68k_handle_fndecl_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -253,9 +253,9 @@ extern int target_flags;
{ "nobitfield", - MASK_BITFIELD, \
N_("Do not use the bit-field instructions") }, \
{ "short", MASK_SHORT, \
N_("Consider type `int' to be 16 bits wide") }, \
N_("Consider type 'int' to be 16 bits wide") }, \
{ "noshort", - MASK_SHORT, \
N_("Consider type `int' to be 32 bits wide") }, \
N_("Consider type 'int' to be 32 bits wide") }, \
{ "68881", MASK_68881, "" }, \
{ "soft-float", - MASK_68881, \
N_("Generate code with library calls for floating point") }, \

View File

@ -2984,7 +2984,7 @@ mcore_override_options (void)
|| (mcore_stack_increment == 0
&& (mcore_stack_increment_string[0] != '0'
|| mcore_stack_increment_string[1] != 0)))
error ("invalid option `-mstack-increment=%s'",
error ("invalid option %<-mstack-increment=%s%>",
mcore_stack_increment_string);
}
@ -3372,7 +3372,7 @@ mcore_handle_naked_attribute (tree * node, tree name, tree args ATTRIBUTE_UNUSED
}
else
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -7541,7 +7541,7 @@ build_mips16_call_stub (rtx retval, rtx fn, rtx arg_size, int fp_code)
Fortunately, this case is illegal, since it means that a function
was declared in two different ways in a single compilation. */
if (fpret && ! l->fpret)
error ("cannot handle inconsistent calls to `%s'", fnname);
error ("cannot handle inconsistent calls to %qs", fnname);
/* If we are calling a stub which handles a floating point return
value, we need to arrange to save $18 in the prologue. We do

View File

@ -1585,7 +1585,7 @@ mmix_print_operand (FILE *stream, rtx x, int code)
default:
/* Presumably there's a missing case above if we get here. */
internal_error ("MMIX Internal: Missing `%c' case in mmix_print_operand", code);
internal_error ("MMIX Internal: Missing %qc case in mmix_print_operand", code);
}
switch (GET_CODE (modified_x))

View File

@ -1065,7 +1065,7 @@ ns32k_handle_fntype_attribute (tree *node, tree name,
&& TREE_CODE (*node) != FIELD_DECL
&& TREE_CODE (*node) != TYPE_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -101,7 +101,7 @@ segv_handler (int sig ATTRIBUTE_UNUSED,
if (strcmp (shell_commands[i][0], shell_name + 1) == 0)
{
fnotice (stderr,
"Try running `%s' in the shell to raise its limit.\n",
"Try running '%s' in the shell to raise its limit.\n",
shell_commands[i][1]);
}
}

View File

@ -1268,7 +1268,7 @@ rs6000_override_options (const char *default_cpu)
else if (! strncmp (rs6000_traceback_name, "no", 2))
rs6000_traceback = traceback_none;
else
error ("unknown -mtraceback arg `%s'; expecting `full', `partial' or `none'",
error ("unknown -mtraceback arg %qs; expecting %<full%>, %<partial%> or %<none%>",
rs6000_traceback_name);
}
@ -1369,7 +1369,7 @@ rs6000_override_options (const char *default_cpu)
while (base[-1] != 'm') base--;
if (*rs6000_longcall_switch != '\0')
error ("invalid option `%s'", base);
error ("invalid option %qs", base);
rs6000_default_long_calls = (base[0] != 'n');
}
@ -1380,7 +1380,7 @@ rs6000_override_options (const char *default_cpu)
while (base[-1] != 'm') base--;
if (*rs6000_warn_altivec_long_switch != '\0')
error ("invalid option `%s'", base);
error ("invalid option %qs", base);
rs6000_warn_altivec_long = (base[0] != 'n');
}
@ -1677,7 +1677,7 @@ rs6000_parse_tls_size_option (void)
else if (strcmp (rs6000_tls_size_string, "64") == 0)
rs6000_tls_size = 64;
else
error ("bad value `%s' for -mtls-size switch", rs6000_tls_size_string);
error ("bad value %qs for -mtls-size switch", rs6000_tls_size_string);
}
void
@ -6798,7 +6798,7 @@ altivec_expand_dst_builtin (tree exp, rtx target ATTRIBUTE_UNUSED,
if (TREE_CODE (arg2) != INTEGER_CST
|| TREE_INT_CST_LOW (arg2) & ~0x3)
{
error ("argument to `%s' must be a 2-bit unsigned literal", d->name);
error ("argument to %qs must be a 2-bit unsigned literal", d->name);
return const0_rtx;
}
@ -6926,7 +6926,7 @@ altivec_expand_builtin (tree exp, rtx target, bool *expandedp)
while (TREE_CODE (arg0) == NOP_EXPR || TREE_CODE (arg0) == ADDR_EXPR
|| TREE_CODE (arg0) == ARRAY_REF)
arg0 = TREE_OPERAND (arg0, 0);
error ("invalid parameter combination for `%s' AltiVec intrinsic",
error ("invalid parameter combination for %qs AltiVec intrinsic",
TREE_STRING_POINTER (arg0));
return const0_rtx;
@ -16746,7 +16746,7 @@ rs6000_handle_altivec_attribute (tree *node, tree name, tree args,
*no_add_attrs = true; /* No need to hang on to the attribute. */
if (!result)
warning ("`%s' attribute ignored", IDENTIFIER_POINTER (name));
warning ("%qs attribute ignored", IDENTIFIER_POINTER (name));
else
*node = reconstruct_complex_type (*node, result);
@ -16781,7 +16781,7 @@ rs6000_handle_longcall_attribute (tree *node, tree name,
&& TREE_CODE (*node) != FIELD_DECL
&& TREE_CODE (*node) != TYPE_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -6827,11 +6827,11 @@ s390_emit_prologue (void)
if (s390_warn_framesize > 0
&& cfun_frame_layout.frame_size >= s390_warn_framesize)
warning ("frame size of `%s' is " HOST_WIDE_INT_PRINT_DEC " bytes",
warning ("frame size of %qs is " HOST_WIDE_INT_PRINT_DEC " bytes",
current_function_name (), cfun_frame_layout.frame_size);
if (s390_warn_dynamicstack_p && cfun->calls_alloca)
warning ("`%s' uses dynamic stack allocation", current_function_name ());
warning ("%qs uses dynamic stack allocation", current_function_name ());
/* Save incoming stack pointer into temp reg. */
if (cfun_frame_layout.save_backchain_p || next_fpr)

View File

@ -7150,7 +7150,7 @@ sh_handle_interrupt_handler_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -7171,21 +7171,21 @@ sh_handle_sp_switch_attribute (tree *node, tree name, tree args,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
else if (!pragma_interrupt)
{
/* The sp_switch attribute only has meaning for interrupt functions. */
warning ("`%s' attribute only applies to interrupt functions",
warning ("%qs attribute only applies to interrupt functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
else if (TREE_CODE (TREE_VALUE (args)) != STRING_CST)
{
/* The argument must be a constant string. */
warning ("`%s' attribute argument not a string constant",
warning ("%qs attribute argument not a string constant",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -7206,21 +7206,21 @@ sh_handle_trap_exit_attribute (tree *node, tree name, tree args,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
else if (!pragma_interrupt)
{
/* The trap_exit attribute only has meaning for interrupt functions. */
warning ("`%s' attribute only applies to interrupt functions",
warning ("%qs attribute only applies to interrupt functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
else if (TREE_CODE (TREE_VALUE (args)) != INTEGER_CST)
{
/* The argument must be a constant integer. */
warning ("`%s' attribute argument not an integer constant",
warning ("%qs attribute argument not an integer constant",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -7348,7 +7348,7 @@ sh_pch_valid_p (const void *data_p, size_t len)
make_message:
{
char *r;
asprintf (&r, _("created and used with differing settings of `-m%s'"),
asprintf (&r, _("created and used with differing settings of '-m%s'"),
flag_that_differs);
if (r == NULL)
return _("out of memory");

View File

@ -276,7 +276,7 @@ sh_symbian_mark_dllimport (tree decl)
if (sh_symbian_dllexport_name_p (oldname))
{
error ("`%s' declared as both exported to and imported from a DLL",
error ("%qs declared as both exported to and imported from a DLL",
IDENTIFIER_POINTER (DECL_NAME (decl)));
}
else if (sh_symbian_dllimport_name_p (oldname))
@ -411,14 +411,14 @@ sh_symbian_handle_dll_attribute (tree *pnode, tree name, tree args,
| (int) ATTR_FLAG_FUNCTION_NEXT
| (int) ATTR_FLAG_ARRAY_NEXT))
{
warning ("`%s' attribute ignored", attr);
warning ("%qs attribute ignored", attr);
*no_add_attrs = true;
return tree_cons (name, args, NULL_TREE);
}
if (TREE_CODE (node) != RECORD_TYPE && TREE_CODE (node) != UNION_TYPE)
{
warning ("`%s' attribute ignored", attr);
warning ("%qs attribute ignored", attr);
*no_add_attrs = true;
}
@ -433,7 +433,7 @@ sh_symbian_handle_dll_attribute (tree *pnode, tree name, tree args,
{
if (DECL_INITIAL (node))
{
error ("%Hvariable `%D' definition is marked dllimport.",
error ("%Hvariable %qD definition is marked dllimport.",
& DECL_SOURCE_LOCATION (node), node);
*no_add_attrs = true;
}

View File

@ -1918,7 +1918,7 @@ xstormy16_print_operand (FILE *file, rtx x, int code)
if (GET_CODE (x) == CONST_INT)
xx = INTVAL (x);
else
output_operand_lossage ("`B' operand is not constant");
output_operand_lossage ("'B' operand is not constant");
/* GCC sign-extends masks with the MSB set, so we have to
detect all the cases that differ only in sign extension
@ -1945,7 +1945,7 @@ xstormy16_print_operand (FILE *file, rtx x, int code)
}
if (l == -1)
output_operand_lossage ("`B' operand has multiple bits set");
output_operand_lossage ("'B' operand has multiple bits set");
fprintf (file, IMMEDIATE_PREFIX HOST_WIDE_INT_PRINT_DEC, l);
return;
@ -1971,7 +1971,7 @@ xstormy16_print_operand (FILE *file, rtx x, int code)
if (GET_CODE (x) == CONST_INT)
xx = INTVAL (x);
else
output_operand_lossage ("`o' operand is not constant");
output_operand_lossage ("'o' operand is not constant");
if (code == 'O')
xx = -xx;
@ -1989,7 +1989,7 @@ xstormy16_print_operand (FILE *file, rtx x, int code)
if (GET_CODE (x) == CONST_INT)
xx = INTVAL (x);
else
output_operand_lossage ("`B' operand is not constant");
output_operand_lossage ("'B' operand is not constant");
l = 7 - xx;
@ -2410,7 +2410,7 @@ xstormy16_handle_interrupt_attribute (tree *node, tree name,
{
if (TREE_CODE (*node) != FUNCTION_TYPE)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}
@ -2431,7 +2431,7 @@ xstormy16_handle_below100_attribute (tree *node,
&& TREE_CODE (*node) != POINTER_TYPE
&& TREE_CODE (*node) != TYPE_DECL)
{
warning ("`__BELOW100__' attribute only applies to variables");
warning ("%<__BELOW100__%> attribute only applies to variables");
*no_add_attrs = true;
}
else if (args == NULL_TREE && TREE_CODE (*node) == VAR_DECL)

View File

@ -2204,7 +2204,7 @@ v850_handle_interrupt_attribute (tree * node,
{
if (TREE_CODE (*node) != FUNCTION_DECL)
{
warning ("`%s' attribute only applies to functions",
warning ("%qs attribute only applies to functions",
IDENTIFIER_POINTER (name));
*no_add_attrs = true;
}

View File

@ -1,3 +1,13 @@
2004-11-09 Joseph S. Myers <joseph@codesourcery.com>
* call.c, class.c, decl.c, decl2.c, error.c, mangle.c, parser.c,
pt.c, search.c, semantics.c, typeck.c: Use %q, %< and %> for
quoting in diagnostics.
* parser.c (cp_parser_sizeof_operand): Use '' instead of `' for
quoting in printf format.
* decl.c (duplicate_decls, start_decl): Use %qD instead of
unquoted %D.
2004-11-08 Kazu Hirata <kazu@cs.umass.edu>
* class.c, decl.c, lex.c, name-lookup.c, parser.c, pt.c,

View File

@ -3400,7 +3400,7 @@ build_conditional_expr (tree arg1, tree arg2, tree arg3)
if (TREE_CODE (arg2_type) == ENUMERAL_TYPE
&& TREE_CODE (arg3_type) == ENUMERAL_TYPE)
warning ("enumeral mismatch in conditional expression: `%T' vs `%T'",
warning ("enumeral mismatch in conditional expression: %qT vs %qT",
arg2_type, arg3_type);
else if (extra_warnings
&& ((TREE_CODE (arg2_type) == ENUMERAL_TYPE

View File

@ -5529,7 +5529,7 @@ push_lang_context (tree name)
current_lang_name = name;
}
else
error ("language string `\"%E\"' not recognized", name);
error ("language string %<\"%E\"%> not recognized", name);
}
/* Get out of the current language scope. */

View File

@ -1848,7 +1848,7 @@ duplicate_decls (tree newdecl, tree olddecl)
that specialization that would cause an implicit
instantiation to take place, in every translation unit in
which such a use occurs. */
error ("explicit specialization of %D after first use",
error ("explicit specialization of %qD after first use",
olddecl);
SET_DECL_TEMPLATE_SPECIALIZATION (olddecl);
@ -3781,7 +3781,7 @@ start_decl (const cp_declarator *declarator,
initialization. Thus, duplicate_decls won't warn
about this situation, and so we check here. */
if (DECL_INITIAL (decl) && DECL_INITIAL (field))
error ("duplicate initialization of %D", decl);
error ("duplicate initialization of %qD", decl);
if (duplicate_decls (decl, field))
decl = field;
}
@ -7052,7 +7052,7 @@ grokdeclarator (const cp_declarator *declarator,
/* Warn about storage classes that are invalid for certain
kinds of declarations (parameters, typenames, etc.). */
if (declspecs->multiple_storage_classes_p)
error ("multiple storage classes in declaration of `%s'", name);
error ("multiple storage classes in declaration of %qs", name);
else if (thread_p
&& ((storage_class
&& storage_class != sc_extern

View File

@ -961,7 +961,7 @@ grokfield (const cp_declarator *declarator,
case FIELD_DECL:
if (asmspec)
error ("`asm' specifiers are not permitted on non-static data members");
error ("%<asm%> specifiers are not permitted on non-static data members");
if (DECL_INITIAL (value) == error_mark_node)
init = error_mark_node;
cp_finish_decl (value, init, NULL_TREE, flags);
@ -3030,7 +3030,7 @@ cp_finish_file (void)
already verified there was a definition. */
&& !DECL_EXPLICIT_INSTANTIATION (decl))
{
cp_warning_at ("inline function `%D' used but never defined", decl);
cp_warning_at ("inline function %qD used but never defined", decl);
/* This symbol is effectively an "extern" declaration now.
This is not strictly necessary, but removes a duplicate
warning. */

View File

@ -2230,7 +2230,7 @@ print_instantiation_partial_context (diagnostic_context *context,
xloc = expand_location (loc);
if (t == NULL_TREE)
break;
pp_verbatim (context->printer, "%s:%d: instantiated from `%s'\n",
pp_verbatim (context->printer, "%s:%d: instantiated from %qs\n",
xloc.file, xloc.line,
decl_as_string (TINST_DECL (t),
TFF_DECL_SPECIFIERS | TFF_RETURN_TYPE));
@ -2370,7 +2370,7 @@ locate_error (const char *msgid, va_list ap)
default:
errorcount = 0; /* damn ICE suppression */
internal_error ("unexpected letter `%c' in locate_error\n", *f);
internal_error ("unexpected letter %qc in locate_error\n", *f);
}
}
}

View File

@ -2169,7 +2169,7 @@ write_expression (tree expr)
expression without extending the C++ ABI. */
if (code == COND_EXPR && i == 1 && !operand)
{
error ("omitted middle operand to `?:' operand "
error ("omitted middle operand to %<?:%> operand "
"cannot be mangled");
continue;
}
@ -2479,7 +2479,7 @@ static inline const char *
finish_mangling (const bool warn)
{
if (warn_abi && warn && G.need_abi_warning)
warning ("the mangled name of `%D' will change in a future "
warning ("the mangled name of %qD will change in a future "
"version of GCC",
G.entity);

View File

@ -1821,7 +1821,7 @@ cp_parser_name_lookup_error (cp_parser* parser,
error ("%<%T::%D%> has not been declared",
parser->object_scope, name);
else
error ("`%D' has not been declared", name);
error ("%qD has not been declared", name);
}
else if (parser->scope && parser->scope != global_namespace)
error ("%<%D::%D%> %s", parser->scope, name, desired);
@ -15228,7 +15228,7 @@ cp_parser_sizeof_operand (cp_parser* parser, enum rid keyword)
/* Initialize FORMAT the first time we get here. */
if (!format)
format = "types may not be defined in `%s' expressions";
format = "types may not be defined in '%s' expressions";
/* Types cannot be defined in a `sizeof' expression. Save away the
old message. */
@ -15266,7 +15266,7 @@ cp_parser_sizeof_operand (cp_parser* parser, enum rid keyword)
type = cp_parser_type_id (parser);
parser->in_type_id_in_expr_p = saved_in_type_id_in_expr_p;
/* Now, look for the trailing `)'. */
cp_parser_require (parser, CPP_CLOSE_PAREN, "`)'");
cp_parser_require (parser, CPP_CLOSE_PAREN, "%<)%>");
/* If all went well, then we're done. */
if (cp_parser_parse_definitely (parser))
{

View File

@ -1795,7 +1795,7 @@ check_explicit_specialization (tree declarator,
error("too few template parameter lists in declaration of %qD", decl);
else
error("explicit specialization of %qD must be introduced by "
"`template <>'", decl);
"%<template <>%>", decl);
/* Fall through. */
case tsk_expl_spec:
@ -7407,7 +7407,7 @@ tsubst (tree t, tree args, tsubst_flags_t complain, tree in_decl)
}
default:
sorry ("use of `%s' in template",
sorry ("use of %qs in template",
tree_code_name [(int) TREE_CODE (t)]);
return error_mark_node;
}

View File

@ -1131,7 +1131,7 @@ lookup_field_r (tree binfo, void *data)
/* Add the new value. */
lfi->ambiguous = tree_cons (NULL_TREE, nval, lfi->ambiguous);
TREE_TYPE (lfi->ambiguous) = error_mark_node;
lfi->errstr = "request for member `%D' is ambiguous";
lfi->errstr = "request for member %qD is ambiguous";
}
}
else

View File

@ -1858,15 +1858,15 @@ finish_this_expr (void)
else if (current_function_decl
&& DECL_STATIC_FUNCTION_P (current_function_decl))
{
error ("`this' is unavailable for static member functions");
error ("%<this%> is unavailable for static member functions");
result = error_mark_node;
}
else
{
if (current_function_decl)
error ("invalid use of `this' in non-member function");
error ("invalid use of %<this%> in non-member function");
else
error ("invalid use of `this' at top level");
error ("invalid use of %<this%> at top level");
result = error_mark_node;
}
@ -2004,7 +2004,7 @@ finish_template_type_parm (tree aggr, tree identifier)
{
if (aggr != class_type_node)
{
pedwarn ("template type parameters must use the keyword `class' or `typename'");
pedwarn ("template type parameters must use the keyword %<class%> or %<typename%>");
aggr = class_type_node;
}

View File

@ -4325,7 +4325,7 @@ cxx_mark_addressable (tree exp)
case PARM_DECL:
if (x == current_class_ptr)
{
error ("cannot take the address of `this', which is an rvalue expression");
error ("cannot take the address of %<this%>, which is an rvalue expression");
TREE_ADDRESSABLE (x) = 1; /* so compiler doesn't die later. */
return true;
}
@ -4344,7 +4344,7 @@ cxx_mark_addressable (tree exp)
case RESULT_DECL:
if (DECL_REGISTER (x) && !TREE_ADDRESSABLE (x)
&& !DECL_ARTIFICIAL (x) && extra_warnings)
warning ("address requested for %qD, which is declared `register'",
warning ("address requested for %qD, which is declared %<register%>",
x);
TREE_ADDRESSABLE (x) = 1;
return true;
@ -4863,7 +4863,7 @@ build_reinterpret_cast_1 (tree type, tree expr, bool c_cast_p,
if (TYPE_PTR_P (intype)
&& (comptypes (TREE_TYPE (intype), TREE_TYPE (type),
COMPARE_BASE | COMPARE_DERIVED)))
warning ("casting `%T' to `%T' does not dereference pointer",
warning ("casting %qT to %qT does not dereference pointer",
intype, type);
expr = build_unary_op (ADDR_EXPR, expr, 0);
@ -6144,7 +6144,7 @@ check_return_expr (tree retval)
(This is a G++ extension, used to get better code for functions
that call the `volatile' function.) */
if (TREE_THIS_VOLATILE (current_function_decl))
warning ("function declared `noreturn' has a `return' statement");
warning ("function declared %<noreturn%> has a %<return%> statement");
/* Check for various simple errors. */
if (DECL_DESTRUCTOR_P (current_function_decl))
@ -6184,7 +6184,7 @@ check_return_expr (tree retval)
that's supposed to return a value. */
if (!retval && fn_returns_value_p)
{
pedwarn ("return-statement with no value, in function returning '%T'",
pedwarn ("return-statement with no value, in function returning %qT",
valtype);
/* Clear this, so finish_function won't say that we reach the
end of a non-void function (which we don't, we gave a

View File

@ -2850,7 +2850,7 @@ output_operand_lossage (const char *msgid, ...)
va_start (ap, msgid);
pfx_str = this_is_asm_operands ? _("invalid `asm': ") : "output_operand: ";
pfx_str = this_is_asm_operands ? _("invalid 'asm': ") : "output_operand: ";
asprintf (&fmt_string, "%s%s", pfx_str, _(msgid));
vasprintf (&new_message, fmt_string, ap);
@ -3202,7 +3202,7 @@ output_asm_label (rtx x)
&& NOTE_LINE_NUMBER (x) == NOTE_INSN_DELETED_LABEL))
ASM_GENERATE_INTERNAL_LABEL (buf, "L", CODE_LABEL_NUMBER (x));
else
output_operand_lossage ("`%%l' operand isn't a label");
output_operand_lossage ("'%%l' operand isn't a label");
assemble_name (asm_out_file, buf);
}

View File

@ -1266,7 +1266,7 @@ translate_options (int *argcp, const char *const **argvp)
else if (strchr (arginfo, '*') != 0)
{
error ("incomplete `%s' option", option_map[j].name);
error ("incomplete '%s' option", option_map[j].name);
break;
}
@ -1277,7 +1277,7 @@ translate_options (int *argcp, const char *const **argvp)
{
if (i + 1 == argc)
{
error ("missing argument to `%s' option",
error ("missing argument to '%s' option",
option_map[j].name);
break;
}
@ -1290,7 +1290,7 @@ translate_options (int *argcp, const char *const **argvp)
else if (strchr (arginfo, 'o') == 0)
{
if (arg != 0)
error ("extraneous argument to `%s' option",
error ("extraneous argument to '%s' option",
option_map[j].name);
arg = 0;
}
@ -2632,7 +2632,7 @@ add_sysrooted_prefix (struct path_prefix *pprefix, const char *prefix,
int require_machine_suffix, int os_multilib)
{
if (!IS_ABSOLUTE_PATH (prefix))
fatal ("system path `%s' is not absolute", prefix);
fatal ("system path '%s' is not absolute", prefix);
if (target_system_root)
{
@ -3198,7 +3198,7 @@ process_command (int argc, const char **argv)
argv += 2;
}
else
fatal ("`-%c' option must have argument", opt);
fatal ("'-%c' option must have argument", opt);
if (opt == 'V')
new_version = arg;
else
@ -3220,7 +3220,7 @@ process_command (int argc, const char **argv)
new_argv[0] = new_argv0;
execvp (new_argv0, new_argv);
fatal ("couldn't run `%s': %s", new_argv0, xstrerror (errno));
fatal ("couldn't run '%s': %s", new_argv0, xstrerror (errno));
}
/* Set up the default search paths. If there is no GCC_EXEC_PREFIX,
@ -3509,7 +3509,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
else if (strcmp (argv[i], "-Xlinker") == 0)
{
if (i + 1 == argc)
fatal ("argument to `-Xlinker' is missing");
fatal ("argument to '-Xlinker' is missing");
n_infiles++;
i++;
@ -3517,21 +3517,21 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
else if (strcmp (argv[i], "-Xpreprocessor") == 0)
{
if (i + 1 == argc)
fatal ("argument to `-Xpreprocessor' is missing");
fatal ("argument to '-Xpreprocessor' is missing");
add_preprocessor_option (argv[i+1], strlen (argv[i+1]));
}
else if (strcmp (argv[i], "-Xassembler") == 0)
{
if (i + 1 == argc)
fatal ("argument to `-Xassembler' is missing");
fatal ("argument to '-Xassembler' is missing");
add_assembler_option (argv[i+1], strlen (argv[i+1]));
}
else if (strcmp (argv[i], "-l") == 0)
{
if (i + 1 == argc)
fatal ("argument to `-l' is missing");
fatal ("argument to '-l' is missing");
n_infiles++;
i++;
@ -3552,7 +3552,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
{
struct user_specs *user = xmalloc (sizeof (struct user_specs));
if (++i >= argc)
fatal ("argument to `-specs' is missing");
fatal ("argument to '-specs' is missing");
user->next = (struct user_specs *) 0;
user->filename = argv[i];
@ -3566,7 +3566,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
{
struct user_specs *user = xmalloc (sizeof (struct user_specs));
if (strlen (argv[i]) == 7)
fatal ("argument to `-specs=' is missing");
fatal ("argument to '-specs=' is missing");
user->next = (struct user_specs *) 0;
user->filename = argv[i] + 7;
@ -3603,7 +3603,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
{
case 'b':
case 'V':
fatal ("`-%c' must come at the start of the command line", c);
fatal ("'-%c' must come at the start of the command line", c);
break;
case 'B':
@ -3612,7 +3612,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
int len;
if (p[1] == 0 && i + 1 == argc)
fatal ("argument to `-B' is missing");
fatal ("argument to '-B' is missing");
if (p[1] == 0)
value = argv[++i];
else
@ -4001,7 +4001,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
if (c == 'x')
{
if (p[1] == 0 && i + 1 == argc)
fatal ("argument to `-x' is missing");
fatal ("argument to '-x' is missing");
if (p[1] == 0)
spec_lang = argv[++i];
else
@ -4029,7 +4029,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
n_args = SWITCH_TAKES_ARG (c) - (p[1] != 0);
}
if (i + n_args >= argc)
fatal ("argument to `-%s' is missing", p);
fatal ("argument to '-%s' is missing", p);
switches[n_switches].args
= xmalloc ((n_args + 1) * sizeof(const char *));
while (j < n_args)
@ -4090,7 +4090,7 @@ warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n"
}
if (n_infiles == last_language_n_infiles && spec_lang != 0)
error ("warning: `-x %s' after last input file has no effect", spec_lang);
error ("warning: '-x %s' after last input file has no effect", spec_lang);
/* Ensure we only invoke each subprocess once. */
if (target_help_flag || print_help_list)
@ -4733,7 +4733,7 @@ do_spec_1 (const char *spec, int inswitch, const char *soft_matched_part)
p += 2;
/* We don't support extra suffix characters after %O. */
if (*p == '.' || ISALPHA ((unsigned char) *p))
fatal ("spec '%s' has invalid `%%0%c'", spec, *p);
fatal ("spec '%s' has invalid '%%0%c'", spec, *p);
if (suffix_length == 0)
suffix = TARGET_OBJECT_SUFFIX;
else
@ -4930,7 +4930,7 @@ do_spec_1 (const char *spec, int inswitch, const char *soft_matched_part)
int cur_index = argbuf_index;
/* Handle the {...} following the %W. */
if (*p != '{')
fatal ("spec `%s' has invalid `%%W%c", spec, *p);
fatal ("spec '%s' has invalid '%%W%c", spec, *p);
p = handle_braces (p + 1);
if (p == 0)
return -1;
@ -4961,7 +4961,7 @@ do_spec_1 (const char *spec, int inswitch, const char *soft_matched_part)
/* Skip past the option value and make a copy. */
if (*p != '{')
fatal ("spec `%s' has invalid `%%x%c'", spec, *p);
fatal ("spec '%s' has invalid '%%x%c'", spec, *p);
while (*p++ != '}')
;
string = save_string (p1 + 1, p - p1 - 2);
@ -5342,7 +5342,7 @@ eval_spec_function (const char *func, const char *args)
sf = lookup_spec_function (func);
if (sf == NULL)
fatal ("unknown spec function `%s'", func);
fatal ("unknown spec function '%s'", func);
/* Push the spec processing context. */
save_argbuf_index = argbuf_index;
@ -5361,7 +5361,7 @@ eval_spec_function (const char *func, const char *args)
alloc_args ();
if (do_spec_2 (args) < 0)
fatal ("error in args to spec function `%s'", func);
fatal ("error in args to spec function '%s'", func);
/* argbuf_index is an index for the next argument to be inserted, and
so contains the count of the args already inserted. */
@ -5654,7 +5654,7 @@ handle_braces (const char *p)
return p;
invalid:
fatal ("braced spec `%s' is invalid at `%c'", orig, *p);
fatal ("braced spec '%s' is invalid at '%c'", orig, *p);
#undef SKIP_WHITE
}
@ -5742,7 +5742,7 @@ process_brace_body (const char *p, const char *atom, const char *end_atom,
return p;
invalid:
fatal ("braced spec body `%s' is invalid", body);
fatal ("braced spec body '%s' is invalid", body);
}
/* Return 0 iff switch number SWITCHNUM is obsoleted by a later switch
@ -6271,7 +6271,7 @@ main (int argc, const char **argv)
for (i = 0; (int) i < n_switches; i++)
if (! switches[i].validated)
error ("unrecognized option `-%s'", switches[i].part1);
error ("unrecognized option '-%s'", switches[i].part1);
/* Obey some of the options. */
@ -6467,7 +6467,7 @@ main (int argc, const char **argv)
value = do_spec (input_file_compiler->spec);
infiles[i].preprocessed = true;
if (!have_o_argbuf_index)
fatal ("spec `%s' is invalid", input_file_compiler->spec);
fatal ("spec '%s' is invalid", input_file_compiler->spec);
infiles[i].name = argbuf[have_o_argbuf_index];
infiles[i].incompiler
= lookup_compiler (infiles[i].name,
@ -6935,7 +6935,7 @@ used_arg (const char *p, int len)
if (*q == '\0')
{
invalid_matches:
fatal ("multilib spec `%s' is invalid", multilib_matches);
fatal ("multilib spec '%s' is invalid", multilib_matches);
}
q++;
}
@ -7127,7 +7127,7 @@ set_multilib_dir (void)
if (*p == '\0')
{
invalid_exclusions:
fatal ("multilib exclusions `%s' is invalid",
fatal ("multilib exclusions '%s' is invalid",
multilib_exclusions);
}
@ -7185,7 +7185,7 @@ set_multilib_dir (void)
if (*p == '\0')
{
invalid_select:
fatal ("multilib select `%s' is invalid",
fatal ("multilib select '%s' is invalid",
multilib_select);
}
++p;
@ -7326,7 +7326,7 @@ print_multilib_info (void)
if (*p == '\0')
{
invalid_select:
fatal ("multilib select `%s' is invalid", multilib_select);
fatal ("multilib select '%s' is invalid", multilib_select);
}
++p;
@ -7364,7 +7364,7 @@ print_multilib_info (void)
if (*e == '\0')
{
invalid_exclusion:
fatal ("multilib exclusion `%s' is invalid",
fatal ("multilib exclusion '%s' is invalid",
multilib_exclusions);
}

View File

@ -537,16 +537,16 @@ process_file (const char *file_name)
if (gcov_file)
{
fnotice (stdout, "%s:creating `%s'\n",
fnotice (stdout, "%s:creating '%s'\n",
src->name, gcov_file_name);
output_lines (gcov_file, src);
if (ferror (gcov_file))
fnotice (stderr, "%s:error writing output file `%s'\n",
fnotice (stderr, "%s:error writing output file '%s'\n",
src->name, gcov_file_name);
fclose (gcov_file);
}
else
fnotice (stderr, "%s:could not open output file `%s'\n",
fnotice (stderr, "%s:could not open output file '%s'\n",
src->name, gcov_file_name);
free (gcov_file_name);
}
@ -716,7 +716,7 @@ read_graph_file (void)
GCOV_UNSIGNED2STRING (v, version);
GCOV_UNSIGNED2STRING (e, GCOV_VERSION);
fnotice (stderr, "%s:version `%.4s', prefer `%.4s'\n",
fnotice (stderr, "%s:version '%.4s', prefer '%.4s'\n",
bbg_file_name, v, e);
}
bbg_stamp = gcov_read_unsigned ();
@ -768,7 +768,7 @@ read_graph_file (void)
else if (fn && tag == GCOV_TAG_BLOCKS)
{
if (fn->blocks)
fnotice (stderr, "%s:already seen blocks for `%s'\n",
fnotice (stderr, "%s:already seen blocks for '%s'\n",
bbg_file_name, fn->name);
else
{
@ -978,7 +978,7 @@ read_count_file (void)
GCOV_UNSIGNED2STRING (v, version);
GCOV_UNSIGNED2STRING (e, GCOV_VERSION);
fnotice (stderr, "%s:version `%.4s', prefer version `%.4s'\n",
fnotice (stderr, "%s:version '%.4s', prefer version '%.4s'\n",
da_file_name, v, e);
}
tag = gcov_read_unsigned ();
@ -1010,7 +1010,7 @@ read_count_file (void)
fn_n = NULL;
else
{
fnotice (stderr, "%s:unknown function `%u'\n",
fnotice (stderr, "%s:unknown function '%u'\n",
da_file_name, ident);
break;
}
@ -1023,7 +1023,7 @@ read_count_file (void)
else if (gcov_read_unsigned () != fn->checksum)
{
mismatch:;
fnotice (stderr, "%s:profile mismatch for `%s'\n",
fnotice (stderr, "%s:profile mismatch for '%s'\n",
da_file_name, fn->name);
goto cleanup;
}
@ -1066,12 +1066,12 @@ solve_flow_graph (function_t *fn)
block_t *invalid_blocks = NULL; /* invalid, but inferable blocks. */
if (fn->num_blocks < 2)
fnotice (stderr, "%s:`%s' lacks entry and/or exit blocks\n",
fnotice (stderr, "%s:'%s' lacks entry and/or exit blocks\n",
bbg_file_name, fn->name);
else
{
if (fn->blocks[0].num_pred)
fnotice (stderr, "%s:`%s' has arcs to entry block\n",
fnotice (stderr, "%s:'%s' has arcs to entry block\n",
bbg_file_name, fn->name);
else
/* We can't deduce the entry block counts from the lack of
@ -1079,7 +1079,7 @@ solve_flow_graph (function_t *fn)
fn->blocks[0].num_pred = ~(unsigned)0;
if (fn->blocks[fn->num_blocks - 1].num_succ)
fnotice (stderr, "%s:`%s' has arcs from exit block\n",
fnotice (stderr, "%s:'%s' has arcs from exit block\n",
bbg_file_name, fn->name);
else
/* Likewise, we can't deduce exit block counts from the lack
@ -1287,7 +1287,7 @@ solve_flow_graph (function_t *fn)
for (ix = 0; ix < fn->num_blocks; ix++)
if (!fn->blocks[ix].count_valid)
{
fnotice (stderr, "%s:graph is unsolvable for `%s'\n",
fnotice (stderr, "%s:graph is unsolvable for '%s'\n",
bbg_file_name, fn->name);
break;
}
@ -1367,7 +1367,7 @@ format_gcov (gcov_type top, gcov_type bottom, int dp)
static void
function_summary (const coverage_t *coverage, const char *title)
{
fnotice (stdout, "%s `%s'\n", title, coverage->name);
fnotice (stdout, "%s '%s'\n", title, coverage->name);
if (coverage->lines)
fnotice (stdout, "Lines executed:%s of %d\n",
@ -1537,7 +1537,7 @@ add_line_counts (coverage_t *coverage, function_t *fn)
}
}
if (!line)
fnotice (stderr, "%s:no lines for `%s'\n", bbg_file_name, fn->name);
fnotice (stderr, "%s:no lines for '%s'\n", bbg_file_name, fn->name);
}
/* Accumulate the line counts of a file. */
@ -1796,7 +1796,7 @@ output_lines (FILE *gcov_file, const source_t *src)
if (!fstat (fileno (source_file), &status)
&& status.st_mtime > bbg_file_time)
{
fnotice (stderr, "%s:source file is newer than graph file `%s'\n",
fnotice (stderr, "%s:source file is newer than graph file '%s'\n",
src->name, bbg_file_name);
fprintf (gcov_file, "%9s:%5d:Source is newer than graph\n",
"-", 0);

View File

@ -1,3 +1,7 @@
2004-11-09 Joseph S. Myers <joseph@codesourcery.com>
* objc-act.c: Use %q, %< and %> for quoting in diagnostics.
2004-11-08 Andrew Pinski <pinskia@physics.uc.edu>
PR objc/16546

View File

@ -750,7 +750,7 @@ objc_finish_implementation (void)
objc_implementation_context = NULL_TREE;
}
else
warning ("`@end' must appear in an @implementation context");
warning ("%<@end%> must appear in an @implementation context");
}
void
@ -898,7 +898,7 @@ objc_comptypes (tree lhs, tree rhs, int reflexive)
if (!rproto)
warning
("object does not conform to the `%s' protocol",
("object does not conform to the %qs protocol",
IDENTIFIER_POINTER (PROTOCOL_NAME (p)));
}
return 1;
@ -988,7 +988,7 @@ objc_comptypes (tree lhs, tree rhs, int reflexive)
}
if (!rproto)
warning ("class `%s' does not implement the `%s' protocol",
warning ("class %qs does not implement the %qs protocol",
IDENTIFIER_POINTER (OBJC_TYPE_NAME (TREE_TYPE (rhs))),
IDENTIFIER_POINTER (PROTOCOL_NAME (p)));
}
@ -1065,7 +1065,7 @@ objc_comptypes (tree lhs, tree rhs, int reflexive)
}
if (!lproto)
warning ("class `%s' does not implement the `%s' protocol",
warning ("class %qs does not implement the %qs protocol",
IDENTIFIER_POINTER (OBJC_TYPE_NAME
(TREE_TYPE (lhs))),
IDENTIFIER_POINTER (PROTOCOL_NAME (p)));
@ -1171,7 +1171,7 @@ objc_check_decl (tree decl)
if (TREE_CODE (type) != RECORD_TYPE)
return;
if (OBJC_TYPE_NAME (type) && (type = objc_is_class_name (OBJC_TYPE_NAME (type))))
error ("statically allocated instance of Objective-C class `%s'",
error ("statically allocated instance of Objective-C class %qs",
IDENTIFIER_POINTER (type));
}
@ -1228,7 +1228,7 @@ check_protocol_recursively (tree proto, tree list)
pp = lookup_protocol (pp);
if (pp == proto)
fatal_error ("protocol `%s' has circular dependency",
fatal_error ("protocol %qs has circular dependency",
IDENTIFIER_POINTER (PROTOCOL_NAME (pp)));
if (pp)
check_protocol_recursively (proto, PROTOCOL_LIST (pp));
@ -1250,7 +1250,7 @@ lookup_and_install_protocols (tree protocols)
tree p = lookup_protocol (ident);
if (!p)
error ("cannot find protocol declaration for `%s'",
error ("cannot find protocol declaration for %qs",
IDENTIFIER_POINTER (ident));
else
return_value = chainon (return_value,
@ -1646,16 +1646,16 @@ objc_build_string_object (tree string)
if (!constant_string_class
|| !(constant_string_type
= CLASS_STATIC_TEMPLATE (constant_string_class)))
error ("cannot find interface declaration for `%s'",
error ("cannot find interface declaration for %qs",
IDENTIFIER_POINTER (constant_string_id));
/* The NSConstantString/NXConstantString ivar layout is now known. */
else if (!check_string_class_template ())
error ("interface `%s' does not have valid constant string layout",
error ("interface %qs does not have valid constant string layout",
IDENTIFIER_POINTER (constant_string_id));
/* For the NeXT runtime, we can generate a literal reference
to the string class, don't need to run a constructor. */
else if (flag_next_runtime && !setup_string_decl ())
error ("cannot find reference tag for class `%s'",
error ("cannot find reference tag for class %qs",
IDENTIFIER_POINTER (constant_string_id));
else
{
@ -2515,7 +2515,7 @@ objc_get_class_reference (tree ident)
if (!(ident = objc_is_class_name (ident)))
{
error ("`%s' is not an Objective-C class name or alias",
error ("%qs is not an Objective-C class name or alias",
IDENTIFIER_POINTER (orig_ident));
return error_mark_node;
}
@ -2635,9 +2635,9 @@ objc_declare_alias (tree alias_ident, tree class_ident)
#endif /* OBJCPLUS */
if (!(underlying_class = objc_is_class_name (class_ident)))
warning ("cannot find class `%s'", IDENTIFIER_POINTER (class_ident));
warning ("cannot find class %qs", IDENTIFIER_POINTER (class_ident));
else if (objc_is_class_name (alias_ident))
warning ("class `%s' already exists", IDENTIFIER_POINTER (alias_ident));
warning ("class %qs already exists", IDENTIFIER_POINTER (alias_ident));
else
alias_chain = tree_cons (underlying_class, alias_ident, alias_chain);
}
@ -2662,7 +2662,7 @@ objc_declare_class (tree ident_list)
if (record && ! TREE_STATIC_TEMPLATE (record))
{
error ("`%s' redeclared as different kind of symbol",
error ("%qs redeclared as different kind of symbol",
IDENTIFIER_POINTER (ident));
error ("%Jprevious declaration of '%D'",
record, record);
@ -2780,7 +2780,7 @@ objc_get_class_ivars (tree class_name)
if (interface)
return get_class_ivars (interface);
error ("cannot find interface declaration for `%s'",
error ("cannot find interface declaration for %qs",
IDENTIFIER_POINTER (class_name));
return error_mark_node;
@ -3290,7 +3290,7 @@ objc_finish_try_stmt (void)
tree stmt;
if (c->catch_list == NULL && c->finally_body == NULL)
error ("`@try' without `@catch' or `@finally'");
error ("%<@try%> without %<@catch%> or %<@finally%>");
/* If we're doing Darwin setjmp exceptions, build the big nasty. */
if (flag_objc_sjlj_exceptions)
@ -4226,7 +4226,7 @@ synth_forward_declarations (void)
static void
error_with_ivar (const char *message, tree decl)
{
error ("%J%s `%s'", decl,
error ("%J%s %qs", decl,
message, gen_declaration (decl));
}
@ -5326,7 +5326,7 @@ check_duplicates (hash hsh, int methods, int is_class)
different types. */
attr loop;
warning ("multiple %s named `%c%s' found",
warning ("multiple %s named %<%c%s%> found",
methods ? "methods" : "selectors",
(is_class ? '+' : '-'),
IDENTIFIER_POINTER (METHOD_SEL_NAME (meth)));
@ -5551,7 +5551,7 @@ objc_finish_message_expr (tree receiver, tree sel_name, tree method_params)
{
if (!CLASS_SUPER_NAME (implementation_template))
{
error ("no super class declared in @interface for `%s'",
error ("no super class declared in @interface for %qs",
IDENTIFIER_POINTER (CLASS_NAME (implementation_template)));
return error_mark_node;
}
@ -5592,7 +5592,7 @@ objc_finish_message_expr (tree receiver, tree sel_name, tree method_params)
= lookup_method_in_protocol_list (rprotos, sel_name, 0);
if (method_prototype)
warning ("found `-%s' instead of `+%s' in protocol(s)",
warning ("found %<-%s%> instead of %<+%s%> in protocol(s)",
IDENTIFIER_POINTER (sel_name),
IDENTIFIER_POINTER (sel_name));
}
@ -5651,7 +5651,7 @@ objc_finish_message_expr (tree receiver, tree sel_name, tree method_params)
}
else
{
warning ("invalid receiver type `%s'",
warning ("invalid receiver type %qs",
gen_type_name (orig_rtype));
/* After issuing the "invalid receiver" warning, perform method
lookup as if we were messaging 'id'. */
@ -5666,7 +5666,7 @@ objc_finish_message_expr (tree receiver, tree sel_name, tree method_params)
if (!method_prototype)
{
if (rprotos)
warning ("`%c%s' not found in protocol(s)",
warning ("%<%c%s%> not found in protocol(s)",
(class_tree ? '+' : '-'),
IDENTIFIER_POINTER (sel_name));
@ -5680,7 +5680,7 @@ objc_finish_message_expr (tree receiver, tree sel_name, tree method_params)
static bool warn_missing_methods = false;
if (rtype)
warning ("`%s' may not respond to `%c%s'",
warning ("%qs may not respond to %<%c%s%>",
IDENTIFIER_POINTER (OBJC_TYPE_NAME (rtype)),
(class_tree ? '+' : '-'),
IDENTIFIER_POINTER (sel_name));
@ -5688,15 +5688,15 @@ objc_finish_message_expr (tree receiver, tree sel_name, tree method_params)
then we have failed to find _any_ instance or class method,
respectively. */
else
warning ("no `%c%s' method found",
warning ("no %<%c%s%> method found",
(class_tree ? '+' : '-'),
IDENTIFIER_POINTER (sel_name));
if (!warn_missing_methods)
{
warning ("(Messages without a matching method signature");
warning ("will be assumed to return `id' and accept");
warning ("`...' as arguments.)");
warning ("will be assumed to return %<id%> and accept");
warning ("%<...%> as arguments.)");
warn_missing_methods = true;
}
}
@ -5828,7 +5828,7 @@ objc_build_protocol_expr (tree protoname)
if (!p)
{
error ("cannot find protocol declaration for `%s'",
error ("cannot find protocol declaration for %qs",
IDENTIFIER_POINTER (protoname));
return error_mark_node;
}
@ -5927,7 +5927,7 @@ objc_build_selector_expr (tree selnamelist)
/* If still not found, print out a warning. */
if (!hsh)
{
warning ("undeclared selector `%s'", IDENTIFIER_POINTER (selname));
warning ("undeclared selector %qs", IDENTIFIER_POINTER (selname));
}
}
@ -5969,7 +5969,7 @@ build_ivar_reference (tree id)
to an instance variable. It's better to catch the cases
where this is done unknowingly than to support the above
paradigm. */
warning ("instance variable `%s' accessed in class method",
warning ("instance variable %qs accessed in class method",
IDENTIFIER_POINTER (id));
self_decl = convert (objc_instance_type, self_decl); /* cast */
}
@ -6181,7 +6181,7 @@ objc_add_method (tree class, tree method, int is_class)
if ((TREE_CODE (class) == CLASS_INTERFACE_TYPE
|| TREE_CODE (class) == CATEGORY_INTERFACE_TYPE)
&& !comp_proto_with_proto (method, mth))
error ("duplicate declaration of method `%c%s'",
error ("duplicate declaration of method %<%c%s%>",
is_class ? '+' : '-',
IDENTIFIER_POINTER (METHOD_SEL_NAME (mth)));
}
@ -6226,7 +6226,7 @@ add_category (tree class, tree category)
if (cat)
{
warning ("duplicate interface declaration for category `%s(%s)'",
warning ("duplicate interface declaration for category %<%s(%s)%>",
IDENTIFIER_POINTER (CLASS_NAME (class)),
IDENTIFIER_POINTER (CLASS_SUPER_NAME (category)));
}
@ -6253,7 +6253,7 @@ add_instance_variable (tree class, int public, tree field_decl)
#ifdef OBJCPLUS
if (TREE_CODE (field_type) == REFERENCE_TYPE)
{
error ("illegal reference type specified for instance variable `%s'",
error ("illegal reference type specified for instance variable %qs",
ivar_name);
/* Return class as is without adding this ivar. */
return class;
@ -6264,7 +6264,7 @@ add_instance_variable (tree class, int public, tree field_decl)
|| TYPE_SIZE (field_type) == error_mark_node)
/* 'type[0]' is allowed, but 'type[]' is not! */
{
error ("instance variable `%s' has unknown size", ivar_name);
error ("instance variable %qs has unknown size", ivar_name);
/* Return class as is without adding this ivar. */
return class;
}
@ -6278,8 +6278,8 @@ add_instance_variable (tree class, int public, tree field_decl)
const char *type_name = IDENTIFIER_POINTER (OBJC_TYPE_NAME (field_type));
if(TYPE_POLYMORPHIC_P (field_type)) {
/* vtable pointers are Real Bad(tm), since Obj-C cannot initialize them */
error ("type `%s' has virtual member functions", type_name);
error ("illegal aggregate type `%s' specified for instance variable `%s'",
error ("type %qs has virtual member functions", type_name);
error ("illegal aggregate type %qs specified for instance variable %qs",
type_name, ivar_name);
/* Return class as is without adding this ivar. */
return class;
@ -6287,9 +6287,9 @@ add_instance_variable (tree class, int public, tree field_decl)
/* user-defined constructors and destructors are not known to Obj-C and
hence will not be called. This may or may not be a problem. */
if (TYPE_NEEDS_CONSTRUCTING (field_type))
warning ("type `%s' has a user-defined constructor", type_name);
warning ("type %qs has a user-defined constructor", type_name);
if (TYPE_HAS_NONTRIVIAL_DESTRUCTOR (field_type))
warning ("type `%s' has a user-defined destructor", type_name);
warning ("type %qs has a user-defined destructor", type_name);
warning ("C++ constructors and destructors will not be invoked for Objective-C fields");
}
#endif
@ -6356,7 +6356,7 @@ objc_is_public (tree expr, tree identifier)
{
if (!lookup_interface (OBJC_TYPE_NAME (basetype)))
{
error ("cannot find interface declaration for `%s'",
error ("cannot find interface declaration for %qs",
IDENTIFIER_POINTER (OBJC_TYPE_NAME (basetype)));
return 0;
}
@ -6380,7 +6380,7 @@ objc_is_public (tree expr, tree identifier)
int private = is_private (decl);
if (private)
error ("instance variable `%s' is declared private",
error ("instance variable %qs is declared private",
IDENTIFIER_POINTER (DECL_NAME (decl)));
return !private;
}
@ -6389,14 +6389,14 @@ objc_is_public (tree expr, tree identifier)
non-@public ivars. We will let this slide for now... */
if (!objc_method_context)
{
warning ("instance variable `%s' is %s; "
warning ("instance variable %qs is %s; "
"this will be a hard error in the future",
IDENTIFIER_POINTER (identifier),
TREE_PRIVATE (decl) ? "@private" : "@protected");
return 1;
}
error ("instance variable `%s' is declared %s",
error ("instance variable %qs is declared %s",
IDENTIFIER_POINTER (identifier),
TREE_PRIVATE (decl) ? "private" : "protected");
return 0;
@ -6406,7 +6406,7 @@ objc_is_public (tree expr, tree identifier)
else if (objc_implementation_context && (basetype == objc_object_reference))
{
expr = convert (uprivate_record, expr);
warning ("static access to object of type `id'");
warning ("static access to object of type %<id%>");
}
}
@ -6428,16 +6428,16 @@ check_methods (tree chain, tree list, int mtype)
{
if (TREE_CODE (objc_implementation_context)
== CLASS_IMPLEMENTATION_TYPE)
warning ("incomplete implementation of class `%s'",
warning ("incomplete implementation of class %qs",
IDENTIFIER_POINTER (CLASS_NAME (objc_implementation_context)));
else if (TREE_CODE (objc_implementation_context)
== CATEGORY_IMPLEMENTATION_TYPE)
warning ("incomplete implementation of category `%s'",
warning ("incomplete implementation of category %qs",
IDENTIFIER_POINTER (CLASS_SUPER_NAME (objc_implementation_context)));
first = 0;
}
warning ("method definition for `%c%s' not found",
warning ("method definition for %<%c%s%> not found",
mtype, IDENTIFIER_POINTER (METHOD_SEL_NAME (chain)));
}
@ -6516,17 +6516,17 @@ check_methods_accessible (tree chain, tree context, int mtype)
{
if (TREE_CODE (objc_implementation_context)
== CLASS_IMPLEMENTATION_TYPE)
warning ("incomplete implementation of class `%s'",
warning ("incomplete implementation of class %qs",
IDENTIFIER_POINTER
(CLASS_NAME (objc_implementation_context)));
else if (TREE_CODE (objc_implementation_context)
== CATEGORY_IMPLEMENTATION_TYPE)
warning ("incomplete implementation of category `%s'",
warning ("incomplete implementation of category %qs",
IDENTIFIER_POINTER
(CLASS_SUPER_NAME (objc_implementation_context)));
first = 0;
}
warning ("method definition for `%c%s' not found",
warning ("method definition for %<%c%s%> not found",
mtype, IDENTIFIER_POINTER (METHOD_SEL_NAME (chain)));
}
@ -6567,7 +6567,7 @@ check_protocol (tree p, const char *type, const char *name)
}
if (!f1 || !f2)
warning ("%s `%s' does not fully implement the `%s' protocol",
warning ("%s %qs does not fully implement the %qs protocol",
type, name, IDENTIFIER_POINTER (PROTOCOL_NAME (p)));
}
@ -6625,7 +6625,7 @@ start_class (enum tree_code code, tree class_name, tree super_name,
if (objc_implementation_context)
{
warning ("`@end' missing in implementation context");
warning ("%<@end%> missing in implementation context");
finish_class (objc_implementation_context);
objc_ivar_chain = NULL_TREE;
objc_implementation_context = NULL_TREE;
@ -6638,7 +6638,7 @@ start_class (enum tree_code code, tree class_name, tree super_name,
if ((code == CLASS_INTERFACE_TYPE || code == CLASS_IMPLEMENTATION_TYPE)
&& super_name && !objc_is_class_name (super_name))
{
error ("cannot find interface declaration for `%s', superclass of `%s'",
error ("cannot find interface declaration for %qs, superclass of %qs",
IDENTIFIER_POINTER (super_name),
IDENTIFIER_POINTER (class_name));
super_name = NULL_TREE;
@ -6651,7 +6651,7 @@ start_class (enum tree_code code, tree class_name, tree super_name,
if (! objc_is_class_name (class_name)
&& (decl = lookup_name (class_name)))
{
error ("`%s' redeclared as different kind of symbol",
error ("%qs redeclared as different kind of symbol",
IDENTIFIER_POINTER (class_name));
error ("%Jprevious declaration of '%D'",
decl, decl);
@ -6665,7 +6665,7 @@ start_class (enum tree_code code, tree class_name, tree super_name,
for (chain = implemented_classes; chain; chain = TREE_CHAIN (chain))
if (TREE_VALUE (chain) == class_name)
{
error ("reimplementation of class `%s'",
error ("reimplementation of class %qs",
IDENTIFIER_POINTER (class_name));
return error_mark_node;
}
@ -6682,7 +6682,7 @@ start_class (enum tree_code code, tree class_name, tree super_name,
if (!(implementation_template = lookup_interface (class_name)))
{
warning ("cannot find interface declaration for `%s'",
warning ("cannot find interface declaration for %qs",
IDENTIFIER_POINTER (class_name));
add_class (implementation_template = objc_implementation_context);
}
@ -6696,9 +6696,9 @@ start_class (enum tree_code code, tree class_name, tree super_name,
tree previous_name = CLASS_SUPER_NAME (implementation_template);
const char *const name =
previous_name ? IDENTIFIER_POINTER (previous_name) : "";
error ("conflicting super class name `%s'",
error ("conflicting super class name %qs",
IDENTIFIER_POINTER (super_name));
error ("previous declaration of `%s'", name);
error ("previous declaration of %qs", name);
}
else if (! super_name)
@ -6712,9 +6712,9 @@ start_class (enum tree_code code, tree class_name, tree super_name,
{
if (lookup_interface (class_name))
#ifdef OBJCPLUS
error ("duplicate interface declaration for class `%s'",
error ("duplicate interface declaration for class %qs",
#else
warning ("duplicate interface declaration for class `%s'",
warning ("duplicate interface declaration for class %qs",
#endif
IDENTIFIER_POINTER (class_name));
else
@ -6735,7 +6735,7 @@ start_class (enum tree_code code, tree class_name, tree super_name,
if (!(class_category_is_assoc_with = lookup_interface (class_name)))
{
error ("cannot find interface declaration for `%s'",
error ("cannot find interface declaration for %qs",
IDENTIFIER_POINTER (class_name));
exit (FATAL_EXIT_CODE);
}
@ -6760,7 +6760,7 @@ start_class (enum tree_code code, tree class_name, tree super_name,
if (!(implementation_template = lookup_interface (class_name)))
{
error ("cannot find interface declaration for `%s'",
error ("cannot find interface declaration for %qs",
IDENTIFIER_POINTER (class_name));
exit (FATAL_EXIT_CODE);
}
@ -6974,7 +6974,7 @@ start_protocol (enum tree_code code, tree name, tree list)
}
else
{
warning ("duplicate declaration for protocol `%s'",
warning ("duplicate declaration for protocol %qs",
IDENTIFIER_POINTER (name));
}
return protocol;
@ -7490,7 +7490,7 @@ static void
warn_with_method (const char *message, int mtype, tree method)
{
/* Add a readable method name to the warning. */
warning ("%J%s `%c%s'", method,
warning ("%J%s %<%c%s%>", method,
message, mtype, gen_method_decl (method));
}
@ -7780,7 +7780,7 @@ get_super_receiver (void)
/* Barf if super used in a category of Object. */
if (!super_name)
{
error ("no super class declared in interface for `%s'",
error ("no super class declared in interface for %qs",
IDENTIFIER_POINTER (CLASS_NAME (implementation_template)));
return error_mark_node;
}
@ -7874,7 +7874,7 @@ lang_report_error_function (tree decl)
{
if (objc_method_context)
{
fprintf (stderr, "In method `%s'\n",
fprintf (stderr, "In method %qs\n",
IDENTIFIER_POINTER (METHOD_SEL_NAME (objc_method_context)));
return 1;
}
@ -8173,7 +8173,7 @@ finish_objc (void)
/* A missing @end may not be detected by the parser. */
if (objc_implementation_context)
{
warning ("`@end' missing in implementation context");
warning ("%<@end%> missing in implementation context");
finish_class (objc_implementation_context);
objc_ivar_chain = NULL_TREE;
objc_implementation_context = NULL_TREE;

View File

@ -1034,7 +1034,7 @@ handle_param (const char *carg)
{
value = integral_argument (equal + 1);
if (value == -1)
error ("invalid --param value `%s'", equal + 1);
error ("invalid --param value %qs", equal + 1);
else
{
*equal = '\0';

View File

@ -231,7 +231,7 @@ struct pretty_print_info
IDENTIFIER_POINTER (T) + IDENTIFIER_LENGTH (T))
#define pp_unsupported_tree(PP, T) \
pp_verbatim (pp_base (PP), "#`%s' not supported by %s#", \
pp_verbatim (pp_base (PP), "#%qs not supported by %s#", \
tree_code_name[(int) TREE_CODE (T)], __FUNCTION__)

View File

@ -579,7 +579,7 @@ safe_write (int desc, void *ptr, int len, const char *out_fname)
if (errno_val == EINTR)
continue;
#endif
notice ("%s: error writing file `%s': %s\n",
notice ("%s: error writing file '%s': %s\n",
pname, shortpath (NULL, out_fname), xstrerror (errno_val));
return;
}
@ -732,7 +732,7 @@ file_normally_convertible (const char *path)
if (access (path, R_OK))
{
if (!quiet_flag)
notice ("%s: warning: no read access for file `%s'\n",
notice ("%s: warning: no read access for file '%s'\n",
pname, shortpath (NULL, path));
return 0;
}
@ -740,7 +740,7 @@ file_normally_convertible (const char *path)
if (access (path, W_OK))
{
if (!quiet_flag)
notice ("%s: warning: no write access for file `%s'\n",
notice ("%s: warning: no write access for file '%s'\n",
pname, shortpath (NULL, path));
return 0;
}
@ -748,7 +748,7 @@ file_normally_convertible (const char *path)
if (access (dir_name, W_OK))
{
if (!quiet_flag)
notice ("%s: warning: no write access for dir containing `%s'\n",
notice ("%s: warning: no write access for dir containing '%s'\n",
pname, shortpath (NULL, path));
return 0;
}
@ -1633,7 +1633,7 @@ save_def_or_dec (const char *l, int is_syscalls)
{
if (strcmp (def_dec_p->ansi_decl, other->ansi_decl))
{
notice ("%s:%d: declaration of function `%s' takes different forms\n",
notice ("%s:%d: declaration of function '%s' takes different forms\n",
def_dec_p->file->hash_entry->symbol,
def_dec_p->line,
def_dec_p->hash_entry->symbol);
@ -1888,7 +1888,7 @@ gen_aux_info_file (const char *base_filename)
concat (compile_params[input_file_name_index], aux_info_suffix, NULL);
if (!quiet_flag)
notice ("%s: compiling `%s'\n",
notice ("%s: compiling '%s'\n",
pname, compile_params[input_file_name_index]);
{
@ -1973,7 +1973,7 @@ start_over: ;
{
if (is_syscalls)
{
notice ("%s: warning: missing SYSCALLS file `%s'\n",
notice ("%s: warning: missing SYSCALLS file '%s'\n",
pname, aux_info_filename);
return;
}
@ -1982,7 +1982,7 @@ start_over: ;
else
{
int errno_val = errno;
notice ("%s: can't read aux info file `%s': %s\n",
notice ("%s: can't read aux info file '%s': %s\n",
pname, shortpath (NULL, aux_info_filename),
xstrerror (errno_val));
errors++;
@ -2011,7 +2011,7 @@ start_over: ;
if (access (aux_info_filename, R_OK) == -1)
{
int errno_val = errno;
notice ("%s: can't read aux info file `%s': %s\n",
notice ("%s: can't read aux info file '%s': %s\n",
pname, shortpath (NULL, aux_info_filename),
xstrerror (errno_val));
errors++;
@ -2027,7 +2027,7 @@ start_over: ;
if (stat (aux_info_filename, &stat_buf) == -1)
{
int errno_val = errno;
notice ("%s: can't get status of aux info file `%s': %s\n",
notice ("%s: can't get status of aux info file '%s': %s\n",
pname, shortpath (NULL, aux_info_filename),
xstrerror (errno_val));
errors++;
@ -2055,7 +2055,7 @@ start_over: ;
if (stat (base_source_filename, &stat_buf) == -1)
{
int errno_val = errno;
notice ("%s: can't get status of aux info file `%s': %s\n",
notice ("%s: can't get status of aux info file '%s': %s\n",
pname, shortpath (NULL, base_source_filename),
xstrerror (errno_val));
errors++;
@ -2083,7 +2083,7 @@ start_over: ;
if ((aux_info_file = open (aux_info_filename, fd_flags, 0444 )) == -1)
{
int errno_val = errno;
notice ("%s: can't open aux info file `%s' for reading: %s\n",
notice ("%s: can't open aux info file '%s' for reading: %s\n",
pname, shortpath (NULL, aux_info_filename),
xstrerror (errno_val));
return;
@ -2101,7 +2101,7 @@ start_over: ;
(int) aux_info_size)
{
int errno_val = errno;
notice ("%s: error reading aux info file `%s': %s\n",
notice ("%s: error reading aux info file '%s': %s\n",
pname, shortpath (NULL, aux_info_filename),
xstrerror (errno_val));
free (aux_info_base);
@ -2114,7 +2114,7 @@ start_over: ;
if (close (aux_info_file))
{
int errno_val = errno;
notice ("%s: error closing aux info file `%s': %s\n",
notice ("%s: error closing aux info file '%s': %s\n",
pname, shortpath (NULL, aux_info_filename),
xstrerror (errno_val));
free (aux_info_base);
@ -2130,7 +2130,7 @@ start_over: ;
if (unlink (aux_info_filename) == -1)
{
int errno_val = errno;
notice ("%s: can't delete aux info file `%s': %s\n",
notice ("%s: can't delete aux info file '%s': %s\n",
pname, shortpath (NULL, aux_info_filename),
xstrerror (errno_val));
}
@ -2212,7 +2212,7 @@ start_over: ;
if (keep_it && unlink (aux_info_filename) == -1)
{
int errno_val = errno;
notice ("%s: can't delete file `%s': %s\n",
notice ("%s: can't delete file '%s': %s\n",
pname, shortpath (NULL, aux_info_filename),
xstrerror (errno_val));
return;
@ -2290,7 +2290,7 @@ rename_c_file (const hash_table_entry *hp)
if (rename (filename, new_filename) == -1)
{
int errno_val = errno;
notice ("%s: warning: can't rename file `%s' to `%s': %s\n",
notice ("%s: warning: can't rename file '%s' to '%s': %s\n",
pname, shortpath (NULL, filename),
shortpath (NULL, new_filename), xstrerror (errno_val));
errors++;
@ -2451,7 +2451,7 @@ find_extern_def (const def_dec_info *head, const def_dec_info *user)
{
extern_def_p = dd_p; /* save a pointer to the definition */
if (!quiet_flag)
notice ("%s: warning: using formals list from %s(%d) for function `%s'\n",
notice ("%s: warning: using formals list from %s(%d) for function '%s'\n",
pname,
shortpath (NULL, dd_p->file->hash_entry->symbol),
dd_p->line, dd_p->hash_entry->symbol);
@ -2491,13 +2491,13 @@ find_extern_def (const def_dec_info *head, const def_dec_info *user)
*p++ = '?';
strcpy (p, ");");
notice ("%s: %d: `%s' used but missing from SYSCALLS\n",
notice ("%s: %d: '%s' used but missing from SYSCALLS\n",
shortpath (NULL, file), user->line,
needed+7); /* Don't print "extern " */
}
#if 0
else
notice ("%s: %d: warning: no extern definition for `%s'\n",
notice ("%s: %d: warning: no extern definition for '%s'\n",
shortpath (NULL, file), user->line,
user->hash_entry->symbol);
#endif
@ -2527,13 +2527,13 @@ find_static_definition (const def_dec_info *user)
if (num_static_defs == 0)
{
if (!quiet_flag)
notice ("%s: warning: no static definition for `%s' in file `%s'\n",
notice ("%s: warning: no static definition for '%s' in file '%s'\n",
pname, head->hash_entry->symbol,
shortpath (NULL, user->file->hash_entry->symbol));
}
else if (num_static_defs > 1)
{
notice ("%s: multiple static defs of `%s' in file `%s'\n",
notice ("%s: multiple static defs of '%s' in file '%s'\n",
pname, head->hash_entry->symbol,
shortpath (NULL, user->file->hash_entry->symbol));
return NULL;
@ -2917,7 +2917,7 @@ edit_fn_declaration (const def_dec_info *def_dec_p,
if (setjmp (source_confusion_recovery))
{
restore_pointers ();
notice ("%s: declaration of function `%s' not converted\n",
notice ("%s: declaration of function '%s' not converted\n",
pname, function_to_edit);
return;
}
@ -3040,7 +3040,7 @@ edit_fn_declaration (const def_dec_info *def_dec_p,
else
{
if (!quiet_flag)
notice ("%s: warning: too many parameter lists in declaration of `%s'\n",
notice ("%s: warning: too many parameter lists in declaration of '%s'\n",
pname, def_dec_p->hash_entry->symbol);
check_source (0, end_formals); /* leave the declaration intact */
}
@ -3061,7 +3061,7 @@ edit_fn_declaration (const def_dec_info *def_dec_p,
if (this_f_list_chain_item)
{
if (!quiet_flag)
notice ("\n%s: warning: too few parameter lists in declaration of `%s'\n",
notice ("\n%s: warning: too few parameter lists in declaration of '%s'\n",
pname, def_dec_p->hash_entry->symbol);
check_source (0, start_formals); /* leave the decl intact */
}
@ -3157,7 +3157,7 @@ edit_formals_lists (const char *end_formals, unsigned int f_list_count,
if (func_name_len != strlen (expected)
|| strncmp (func_name_start, expected, func_name_len))
{
notice ("%s: %d: warning: found `%s' but expected `%s'\n",
notice ("%s: %d: warning: found '%s' but expected '%s'\n",
shortpath (NULL, def_dec_p->file->hash_entry->symbol),
identify_lineno (func_name_start),
dupnstr (func_name_start, func_name_len),
@ -3332,7 +3332,7 @@ add_local_decl (const def_dec_info *def_dec_p, const char *clean_text_p)
if (setjmp (source_confusion_recovery))
{
restore_pointers ();
notice ("%s: local declaration for function `%s' not inserted\n",
notice ("%s: local declaration for function '%s' not inserted\n",
pname, function_to_edit);
return;
}
@ -3359,7 +3359,7 @@ add_local_decl (const def_dec_info *def_dec_p, const char *clean_text_p)
if (*start_of_block != '{')
{
if (!quiet_flag)
notice ("\n%s: %d: warning: can't add declaration of `%s' into macro call\n",
notice ("\n%s: %d: warning: can't add declaration of '%s' into macro call\n",
def_dec_p->file->hash_entry->symbol, def_dec_p->line,
def_dec_p->hash_entry->symbol);
return;
@ -3431,7 +3431,7 @@ add_global_decls (const file_info *file_p, const char *clean_text_p)
if (setjmp (source_confusion_recovery))
{
restore_pointers ();
notice ("%s: global declarations for file `%s' not inserted\n",
notice ("%s: global declarations for file '%s' not inserted\n",
pname, shortpath (NULL, file_p->hash_entry->symbol));
return;
}
@ -3520,7 +3520,7 @@ edit_fn_definition (const def_dec_info *def_dec_p, const char *clean_text_p)
if (setjmp (source_confusion_recovery))
{
restore_pointers ();
notice ("%s: definition of function `%s' not converted\n",
notice ("%s: definition of function '%s' not converted\n",
pname, function_to_edit);
return;
}
@ -3550,7 +3550,7 @@ edit_fn_definition (const def_dec_info *def_dec_p, const char *clean_text_p)
if (edit_formals_lists (end_formals, def_dec_p->f_list_count, def_dec_p))
{
restore_pointers ();
notice ("%s: definition of function `%s' not converted\n",
notice ("%s: definition of function '%s' not converted\n",
pname, function_to_edit);
return;
}
@ -3865,7 +3865,7 @@ scan_for_missed_items (const file_info *file_p)
goto not_missed;
#if 0
notice ("%s: found definition of `%s' at %s(%d)\n",
notice ("%s: found definition of '%s' at %s(%d)\n",
pname,
func_name,
shortpath (NULL, file_p->hash_entry->symbol),
@ -3881,7 +3881,7 @@ scan_for_missed_items (const file_info *file_p)
/* If we make it here, then we did not know about this
function definition. */
notice ("%s: %d: warning: `%s' excluded by preprocessing\n",
notice ("%s: %d: warning: '%s' excluded by preprocessing\n",
shortpath (NULL, file_p->hash_entry->symbol),
identify_lineno (id_start), func_name);
notice ("%s: function definition not converted\n",
@ -3942,7 +3942,7 @@ edit_file (const hash_table_entry *hp)
&& !in_system_include_dir (convert_filename)
#endif /* defined (UNPROTOIZE) */
)
notice ("%s: `%s' not converted\n",
notice ("%s: '%s' not converted\n",
pname, shortpath (NULL, convert_filename));
return;
}
@ -3950,10 +3950,10 @@ edit_file (const hash_table_entry *hp)
/* Let the user know what we are up to. */
if (nochange_flag)
notice ("%s: would convert file `%s'\n",
notice ("%s: would convert file '%s'\n",
pname, shortpath (NULL, convert_filename));
else
notice ("%s: converting file `%s'\n",
notice ("%s: converting file '%s'\n",
pname, shortpath (NULL, convert_filename));
fflush (stderr);
@ -3963,7 +3963,7 @@ edit_file (const hash_table_entry *hp)
if (stat (convert_filename, &stat_buf) == -1)
{
int errno_val = errno;
notice ("%s: can't get status for file `%s': %s\n",
notice ("%s: can't get status for file '%s': %s\n",
pname, shortpath (NULL, convert_filename),
xstrerror (errno_val));
return;
@ -4005,7 +4005,7 @@ edit_file (const hash_table_entry *hp)
if ((input_file = open (convert_filename, fd_flags, 0444)) == -1)
{
int errno_val = errno;
notice ("%s: can't open file `%s' for reading: %s\n",
notice ("%s: can't open file '%s' for reading: %s\n",
pname, shortpath (NULL, convert_filename),
xstrerror (errno_val));
return;
@ -4020,7 +4020,7 @@ edit_file (const hash_table_entry *hp)
{
int errno_val = errno;
close (input_file);
notice ("\n%s: error reading input file `%s': %s\n",
notice ("\n%s: error reading input file '%s': %s\n",
pname, shortpath (NULL, convert_filename),
xstrerror (errno_val));
return;
@ -4054,7 +4054,7 @@ edit_file (const hash_table_entry *hp)
if ((clean_file = creat (clean_filename, 0666)) == -1)
{
int errno_val = errno;
notice ("%s: can't create/open clean file `%s': %s\n",
notice ("%s: can't create/open clean file '%s': %s\n",
pname, shortpath (NULL, clean_filename),
xstrerror (errno_val));
return;
@ -4159,7 +4159,7 @@ edit_file (const hash_table_entry *hp)
if (access (new_filename, F_OK) == 0)
{
if (!quiet_flag)
notice ("%s: warning: file `%s' already saved in `%s'\n",
notice ("%s: warning: file '%s' already saved in '%s'\n",
pname,
shortpath (NULL, convert_filename),
shortpath (NULL, new_filename));
@ -4167,7 +4167,7 @@ edit_file (const hash_table_entry *hp)
else if (rename (convert_filename, new_filename) == -1)
{
int errno_val = errno;
notice ("%s: can't link file `%s' to `%s': %s\n",
notice ("%s: can't link file '%s' to '%s': %s\n",
pname,
shortpath (NULL, convert_filename),
shortpath (NULL, new_filename),
@ -4182,7 +4182,7 @@ edit_file (const hash_table_entry *hp)
/* The file may have already been renamed. */
if (errno_val != ENOENT)
{
notice ("%s: can't delete file `%s': %s\n",
notice ("%s: can't delete file '%s': %s\n",
pname, shortpath (NULL, convert_filename),
xstrerror (errno_val));
return;
@ -4197,7 +4197,7 @@ edit_file (const hash_table_entry *hp)
if ((output_file = creat (convert_filename, 0666)) == -1)
{
int errno_val = errno;
notice ("%s: can't create/open output file `%s': %s\n",
notice ("%s: can't create/open output file '%s': %s\n",
pname, shortpath (NULL, convert_filename),
xstrerror (errno_val));
return;
@ -4230,7 +4230,7 @@ edit_file (const hash_table_entry *hp)
if (chmod (convert_filename, stat_buf.st_mode) == -1)
{
int errno_val = errno;
notice ("%s: can't change mode of file `%s': %s\n",
notice ("%s: can't change mode of file '%s': %s\n",
pname, shortpath (NULL, convert_filename),
xstrerror (errno_val));
}

View File

@ -759,7 +759,7 @@ check_asm_stack_operands (rtx insn)
if (operands_match_p (recog_data.operand[j], recog_data.operand[i]))
{
error_for_asm (insn,
"output operand %d must use `&' constraint", j);
"output operand %d must use %<&%> constraint", j);
malformed_asm = 1;
}
}

View File

@ -469,7 +469,7 @@ rtl_check_failed_bounds (rtx r, int n, const char *file, int line,
const char *func)
{
internal_error
("RTL check: access of elt %d of `%s' with last elt %d in %s, at %s:%d",
("RTL check: access of elt %d of '%s' with last elt %d in %s, at %s:%d",
n, GET_RTX_NAME (GET_CODE (r)), GET_RTX_LENGTH (GET_CODE (r)) - 1,
func, trim_filename (file), line);
}
@ -498,7 +498,7 @@ void
rtl_check_failed_code1 (rtx r, enum rtx_code code, const char *file,
int line, const char *func)
{
internal_error ("RTL check: expected code `%s', have `%s' in %s, at %s:%d",
internal_error ("RTL check: expected code '%s', have '%s' in %s, at %s:%d",
GET_RTX_NAME (code), GET_RTX_NAME (GET_CODE (r)), func,
trim_filename (file), line);
}
@ -508,7 +508,7 @@ rtl_check_failed_code2 (rtx r, enum rtx_code code1, enum rtx_code code2,
const char *file, int line, const char *func)
{
internal_error
("RTL check: expected code `%s' or `%s', have `%s' in %s, at %s:%d",
("RTL check: expected code '%s' or '%s', have '%s' in %s, at %s:%d",
GET_RTX_NAME (code1), GET_RTX_NAME (code2), GET_RTX_NAME (GET_CODE (r)),
func, trim_filename (file), line);
}
@ -530,7 +530,7 @@ rtl_check_failed_flag (const char *name, rtx r, const char *file,
int line, const char *func)
{
internal_error
("RTL flag check: %s used with unexpected rtx code `%s' in %s, at %s:%d",
("RTL flag check: %s used with unexpected rtx code '%s' in %s, at %s:%d",
name, GET_RTX_NAME (GET_CODE (r)), func, trim_filename (file), line);
}
#endif /* ENABLE_RTL_FLAG_CHECKING */

View File

@ -1,3 +1,7 @@
2004-11-09 Joseph S. Myers <joseph@codesourcery.com>
* gcc.dg/builtin-prefetch-1.c: Adjust expected messages.
2004-11-08 Steve Ellcey <sje@cup.hp.com>
* testsuite/gcc.dg/uninit-H.c: Add ifdefs for __hppa__ and __ia64__.

View File

@ -28,12 +28,12 @@ good (int *p)
void
bad (int *p)
{
__builtin_prefetch (p, -1, 0); /* { dg-warning "invalid second arg to __builtin_prefetch; using zero" } */
__builtin_prefetch (p, 2, 0); /* { dg-warning "invalid second arg to __builtin_prefetch; using zero" } */
__builtin_prefetch (p, bogus, 0); /* { dg-warning "invalid second arg to __builtin_prefetch; using zero" } */
__builtin_prefetch (p, 0, -1); /* { dg-warning "invalid third arg to __builtin_prefetch; using zero" } */
__builtin_prefetch (p, 0, 4); /* { dg-warning "invalid third arg to __builtin_prefetch; using zero" } */
__builtin_prefetch (p, 0, bogus); /* { dg-warning "invalid third arg to __builtin_prefetch; using zero" } */
__builtin_prefetch (p, -1, 0); /* { dg-warning "invalid second arg to '__builtin_prefetch'; using zero" } */
__builtin_prefetch (p, 2, 0); /* { dg-warning "invalid second arg to '__builtin_prefetch'; using zero" } */
__builtin_prefetch (p, bogus, 0); /* { dg-warning "invalid second arg to '__builtin_prefetch'; using zero" } */
__builtin_prefetch (p, 0, -1); /* { dg-warning "invalid third arg to '__builtin_prefetch'; using zero" } */
__builtin_prefetch (p, 0, 4); /* { dg-warning "invalid third arg to '__builtin_prefetch'; using zero" } */
__builtin_prefetch (p, 0, bogus); /* { dg-warning "invalid third arg to '__builtin_prefetch'; using zero" } */
}
int

View File

@ -472,7 +472,7 @@ recompile_files (void)
if (!f->args)
{
error ("repository file `%s' does not contain command-line "
error ("repository file '%s' does not contain command-line "
"arguments", f->key);
return 0;
}
@ -693,7 +693,7 @@ scan_linker_output (const char *fname)
if (sym && sym->tweaked)
{
error ("`%s' was assigned to `%s', but was not defined "
error ("'%s' was assigned to '%s', but was not defined "
"during recompilation, or vice versa",
sym->key, sym->file->key);
fclose (stream);