Wrap apostrophes in gcc internal format with %'.
2019-03-11 Martin Liska <mliska@suse.cz> * check-internal-format-escaping.py: Uncomment apostrophes check. 2019-03-11 Martin Liska <mliska@suse.cz> * collect-utils.c (collect_wait): Wrap apostrophes in gcc internal format with %'. * collect2.c (main): Likewise. (scan_prog_file): Likewise. (scan_libraries): Likewise. * config/i386/i386.c (ix86_expand_call): Likewise. (ix86_handle_interrupt_attribute): Likewise. * config/nds32/nds32-intrinsic.c (nds32_expand_builtin_impl): Likewise. * config/nds32/nds32.c (nds32_insert_attributes): Likewise. * config/rl78/rl78.c (rl78_handle_saddr_attribute): Likewise. * lto-wrapper.c (find_crtoffloadtable): Likewise. * symtab.c (symtab_node::verify_base): Likewise. * tree-cfg.c (verify_gimple_label): Likewise. * tree.c (verify_type_variant): Likewise. 2019-03-11 Martin Liska <mliska@suse.cz> * c-opts.c (c_common_post_options): Wrap apostrophes in gcc internal format with %'. 2019-03-11 Martin Liska <mliska@suse.cz> * cvt.c (build_expr_type_conversion): Wrap apostrophes in gcc internal format with %'. * decl.c (check_no_redeclaration_friend_default_args): Likewise. (grokfndecl): Likewise. * name-lookup.c (do_pushtag): Likewise. * pt.c (unify_parameter_deduction_failure): Likewise. (unify_template_deduction_failure): Likewise. From-SVN: r269587
This commit is contained in:
parent
a3f9f006a8
commit
93964ebd2f
@ -1,3 +1,8 @@
|
||||
2019-03-11 Martin Liska <mliska@suse.cz>
|
||||
|
||||
* check-internal-format-escaping.py: Uncomment apostrophes
|
||||
check.
|
||||
|
||||
2019-03-11 Martin Liska <mliska@suse.cz>
|
||||
|
||||
* check-internal-format-escaping.py: New file.
|
||||
|
@ -56,8 +56,8 @@ for i, l in enumerate(lines):
|
||||
print('%s: %s' % (origin, text))
|
||||
elif p.startswith('__builtin_'):
|
||||
print('%s: %s' % (origin, text))
|
||||
# if re.search("[a-zA-Z]'[a-zA-Z]", p):
|
||||
# print('%s: %s' % (origin, text))
|
||||
if re.search("[a-zA-Z]'[a-zA-Z]", p):
|
||||
print('%s: %s' % (origin, text))
|
||||
j += 1
|
||||
|
||||
origin = None
|
||||
|
@ -1,3 +1,20 @@
|
||||
2019-03-11 Martin Liska <mliska@suse.cz>
|
||||
|
||||
* collect-utils.c (collect_wait): Wrap apostrophes
|
||||
in gcc internal format with %'.
|
||||
* collect2.c (main): Likewise.
|
||||
(scan_prog_file): Likewise.
|
||||
(scan_libraries): Likewise.
|
||||
* config/i386/i386.c (ix86_expand_call): Likewise.
|
||||
(ix86_handle_interrupt_attribute): Likewise.
|
||||
* config/nds32/nds32-intrinsic.c (nds32_expand_builtin_impl): Likewise.
|
||||
* config/nds32/nds32.c (nds32_insert_attributes): Likewise.
|
||||
* config/rl78/rl78.c (rl78_handle_saddr_attribute): Likewise.
|
||||
* lto-wrapper.c (find_crtoffloadtable): Likewise.
|
||||
* symtab.c (symtab_node::verify_base): Likewise.
|
||||
* tree-cfg.c (verify_gimple_label): Likewise.
|
||||
* tree.c (verify_type_variant): Likewise.
|
||||
|
||||
2019-03-11 Martin Liska <mliska@suse.cz>
|
||||
|
||||
* builtins.c (expand_builtin_thread_pointer): Wrap an option name
|
||||
|
@ -1,3 +1,8 @@
|
||||
2019-03-11 Martin Liska <mliska@suse.cz>
|
||||
|
||||
* c-opts.c (c_common_post_options): Wrap apostrophes
|
||||
in gcc internal format with %'.
|
||||
|
||||
2019-03-11 Martin Liska <mliska@suse.cz>
|
||||
|
||||
* c-attribs.c (handle_nocf_check_attribute): Wrap an option name
|
||||
|
@ -945,7 +945,7 @@ c_common_post_options (const char **pfilename)
|
||||
if (flag_abi_version == latest_abi_version)
|
||||
{
|
||||
auto_diagnostic_group d;
|
||||
if (warning (OPT_Wabi, "%<-Wabi%> won't warn about anything"))
|
||||
if (warning (OPT_Wabi, "%<-Wabi%> won%'t warn about anything"))
|
||||
{
|
||||
inform (input_location, "%<-Wabi%> warns about differences "
|
||||
"from the most up-to-date ABI, which is also used "
|
||||
|
@ -65,7 +65,7 @@ collect_wait (const char *prog, struct pex_obj *pex)
|
||||
int status;
|
||||
|
||||
if (!pex_get_status (pex, 1, &status))
|
||||
fatal_error (input_location, "can't get program status: %m");
|
||||
fatal_error (input_location, "can%'t get program status: %m");
|
||||
pex_free (pex);
|
||||
|
||||
if (response_file && !save_temps)
|
||||
|
@ -1396,7 +1396,7 @@ main (int argc, char **argv)
|
||||
|
||||
stream = fopen (list_filename, "r");
|
||||
if (stream == NULL)
|
||||
fatal_error (input_location, "can't open %s: %m",
|
||||
fatal_error (input_location, "can%'t open %s: %m",
|
||||
list_filename);
|
||||
|
||||
while (fgets (buf, sizeof buf, stream) != NULL)
|
||||
@ -2470,7 +2470,7 @@ scan_prog_file (const char *prog_name, scanpass which_pass,
|
||||
|
||||
inf = pex_read_output (pex, 0);
|
||||
if (inf == NULL)
|
||||
fatal_error (input_location, "can't open nm output: %m");
|
||||
fatal_error (input_location, "can%'t open nm output: %m");
|
||||
|
||||
if (debug)
|
||||
fprintf (stderr, "\nnm output with constructors/destructors.\n");
|
||||
@ -2639,7 +2639,7 @@ scan_libraries (const char *prog_name)
|
||||
|
||||
inf = pex_read_output (pex, 0);
|
||||
if (inf == NULL)
|
||||
fatal_error (input_location, "can't open ldd output: %m");
|
||||
fatal_error (input_location, "can%'t open ldd output: %m");
|
||||
|
||||
if (debug)
|
||||
notice ("\nldd output with constructors/destructors.\n");
|
||||
|
@ -28399,7 +28399,7 @@ ix86_expand_call (rtx retval, rtx fnaddr, rtx callarg1,
|
||||
if (fndecl
|
||||
&& (lookup_attribute ("interrupt",
|
||||
TYPE_ATTRIBUTES (TREE_TYPE (fndecl)))))
|
||||
error ("interrupt service routine can't be called directly");
|
||||
error ("interrupt service routine can%'t be called directly");
|
||||
}
|
||||
else
|
||||
fndecl = NULL_TREE;
|
||||
@ -38375,7 +38375,7 @@ rdseed_step:
|
||||
mode0 = insn_data[icode].operand[0].mode;
|
||||
if (!insn_data[icode].operand[0].predicate (op0, mode0))
|
||||
{
|
||||
error ("the xabort's argument must be an 8-bit immediate");
|
||||
error ("xabort argument must be an 8-bit immediate");
|
||||
return const0_rtx;
|
||||
}
|
||||
emit_insn (gen_xabort (op0));
|
||||
@ -41440,7 +41440,7 @@ ix86_handle_interrupt_attribute (tree *node, tree, tree, int, bool *)
|
||||
error ("interrupt service routine can only have a pointer argument "
|
||||
"and an optional integer argument");
|
||||
if (! VOID_TYPE_P (return_type))
|
||||
error ("interrupt service routine can't have non-void return value");
|
||||
error ("interrupt service routine can%'t have non-void return value");
|
||||
|
||||
return NULL_TREE;
|
||||
}
|
||||
|
@ -1000,7 +1000,7 @@ nds32_expand_builtin_impl (tree exp,
|
||||
if (!NDS32_EXT_DSP_P ()
|
||||
&& fcode > NDS32_BUILTIN_DSP_BEGIN
|
||||
&& fcode < NDS32_BUILTIN_DSP_END)
|
||||
error ("don't support DSP extension instructions");
|
||||
error ("don%'t support DSP extension instructions");
|
||||
|
||||
switch (fcode)
|
||||
{
|
||||
@ -1059,7 +1059,7 @@ nds32_expand_builtin_impl (tree exp,
|
||||
case NDS32_BUILTIN_CLO:
|
||||
if (!TARGET_EXT_PERF)
|
||||
{
|
||||
error ("don't support performance extension instructions");
|
||||
error ("don%'t support performance extension instructions");
|
||||
return NULL_RTX;
|
||||
}
|
||||
break;
|
||||
@ -1071,7 +1071,7 @@ nds32_expand_builtin_impl (tree exp,
|
||||
case NDS32_BUILTIN_BSP:
|
||||
if (!TARGET_EXT_PERF2)
|
||||
{
|
||||
error ("don't support performance extension "
|
||||
error ("don%'t support performance extension "
|
||||
"version 2 instructions");
|
||||
return NULL_RTX;
|
||||
}
|
||||
@ -1083,7 +1083,7 @@ nds32_expand_builtin_impl (tree exp,
|
||||
case NDS32_BUILTIN_FLMISM:
|
||||
if (!TARGET_EXT_STRING)
|
||||
{
|
||||
error ("don't support string extension instructions");
|
||||
error ("don%'t support string extension instructions");
|
||||
return NULL_RTX;
|
||||
}
|
||||
break;
|
||||
|
@ -3944,7 +3944,7 @@ nds32_insert_attributes (tree decl, tree *attributes)
|
||||
new_attrs = tree_cons (get_identifier ("noclone"), NULL, new_attrs);
|
||||
|
||||
if (!TREE_PUBLIC (decl))
|
||||
error("indirect_call attribute can't apply for static function");
|
||||
error ("indirect_call attribute can%'t apply for static function");
|
||||
|
||||
*attributes = new_attrs;
|
||||
}
|
||||
|
@ -864,7 +864,7 @@ rl78_handle_saddr_attribute (tree * node,
|
||||
|
||||
if (TREE_CODE (* node) == FUNCTION_DECL)
|
||||
{
|
||||
warning (OPT_Wattributes, "%qE attribute doesn't apply to functions",
|
||||
warning (OPT_Wattributes, "%qE attribute doesn%'t apply to functions",
|
||||
name);
|
||||
* no_add_attrs = true;
|
||||
}
|
||||
|
@ -1,3 +1,13 @@
|
||||
2019-03-11 Martin Liska <mliska@suse.cz>
|
||||
|
||||
* cvt.c (build_expr_type_conversion): Wrap apostrophes
|
||||
in gcc internal format with %'.
|
||||
* decl.c (check_no_redeclaration_friend_default_args): Likewise.
|
||||
(grokfndecl): Likewise.
|
||||
* name-lookup.c (do_pushtag): Likewise.
|
||||
* pt.c (unify_parameter_deduction_failure): Likewise.
|
||||
(unify_template_deduction_failure): Likewise.
|
||||
|
||||
2019-03-11 Martin Liska <mliska@suse.cz>
|
||||
|
||||
* call.c (convert_arg_to_ellipsis): Wrap an option name
|
||||
|
@ -1822,7 +1822,7 @@ build_expr_type_conversion (int desires, tree expr, bool complain)
|
||||
if (TREE_CODE (cand) == TEMPLATE_DECL)
|
||||
{
|
||||
if (complain)
|
||||
error ("default type conversion can't deduce template"
|
||||
error ("default type conversion can%'t deduce template"
|
||||
" argument for %qD", cand);
|
||||
return error_mark_node;
|
||||
}
|
||||
|
@ -1305,7 +1305,7 @@ check_no_redeclaration_friend_default_args (tree olddecl, tree newdecl,
|
||||
auto_diagnostic_group d;
|
||||
if (permerror (DECL_SOURCE_LOCATION (newdecl),
|
||||
"friend declaration of %q#D specifies default "
|
||||
"arguments and isn't the only declaration", newdecl))
|
||||
"arguments and isn%'t the only declaration", newdecl))
|
||||
inform (DECL_SOURCE_LOCATION (olddecl),
|
||||
"previous declaration of %q#D", olddecl);
|
||||
return;
|
||||
@ -8913,7 +8913,7 @@ grokfndecl (tree ctype,
|
||||
{
|
||||
permerror (DECL_SOURCE_LOCATION (decl),
|
||||
"friend declaration of %qD specifies default "
|
||||
"arguments and isn't a definition", decl);
|
||||
"arguments and isn%'t a definition", decl);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -6897,7 +6897,7 @@ do_pushtag (tree name, tree type, tag_scope scope)
|
||||
&& !CLASSTYPE_TEMPLATE_INFO (type))
|
||||
{
|
||||
error ("declaration of %<std::initializer_list%> does not match "
|
||||
"%<#include <initializer_list>%>, isn't a template");
|
||||
"%<#include <initializer_list>%>, isn%'t a template");
|
||||
return error_mark_node;
|
||||
}
|
||||
}
|
||||
|
@ -6364,7 +6364,7 @@ unify_parameter_deduction_failure (bool explain_p, tree parm)
|
||||
{
|
||||
if (explain_p)
|
||||
inform (input_location,
|
||||
" couldn't deduce template parameter %qD", parm);
|
||||
" couldn%'t deduce template parameter %qD", parm);
|
||||
return unify_invalid (explain_p);
|
||||
}
|
||||
|
||||
@ -6540,7 +6540,7 @@ unify_template_deduction_failure (bool explain_p, tree parm, tree arg)
|
||||
{
|
||||
if (explain_p)
|
||||
inform (input_location,
|
||||
" can't deduce a template for %qT from non-template type %qT",
|
||||
" can%'t deduce a template for %qT from non-template type %qT",
|
||||
parm, arg);
|
||||
return unify_invalid (explain_p);
|
||||
}
|
||||
|
@ -960,7 +960,7 @@ find_crtoffloadtable (void)
|
||||
}
|
||||
if (i == n_paths)
|
||||
fatal_error (input_location,
|
||||
"installation error, can't find crtoffloadtable.o");
|
||||
"installation error, can%'t find crtoffloadtable.o");
|
||||
|
||||
free_array_of_ptrs ((void **) paths, n_paths);
|
||||
}
|
||||
|
@ -1155,7 +1155,7 @@ symtab_node::verify_base (void)
|
||||
}
|
||||
if (implicit_section && !get_section ())
|
||||
{
|
||||
error ("implicit_section flag is set but section isn't");
|
||||
error ("implicit_section flag is set but section isn%'t");
|
||||
error_found = true;
|
||||
}
|
||||
if (get_section () && get_comdat_group ()
|
||||
@ -1174,14 +1174,14 @@ symtab_node::verify_base (void)
|
||||
|| strcmp (get_section(),
|
||||
get_alias_target ()->get_section ())))
|
||||
{
|
||||
error ("Alias and target's section differs");
|
||||
error ("Alias and target%'s section differs");
|
||||
get_alias_target ()->dump (stderr);
|
||||
error_found = true;
|
||||
}
|
||||
if (alias && definition
|
||||
&& get_comdat_group () != get_alias_target ()->get_comdat_group ())
|
||||
{
|
||||
error ("Alias and target's comdat groups differs");
|
||||
error ("Alias and target%'s comdat groups differs");
|
||||
get_alias_target ()->dump (stderr);
|
||||
error_found = true;
|
||||
}
|
||||
@ -1196,7 +1196,7 @@ symtab_node::verify_base (void)
|
||||
ultimate_transparent_alias_target (DECL_ASSEMBLER_NAME (to->decl)));
|
||||
if (!symbol_table::assembler_names_equal_p (name1, name2))
|
||||
{
|
||||
error ("Transparent alias and target's assembler names differs");
|
||||
error ("Transparent alias and target%'s assembler names differs");
|
||||
get_alias_target ()->dump (stderr);
|
||||
error_found = true;
|
||||
}
|
||||
|
@ -4827,7 +4827,7 @@ verify_gimple_label (glabel *stmt)
|
||||
if (!DECL_NONLOCAL (decl) && !FORCED_LABEL (decl)
|
||||
&& DECL_CONTEXT (decl) != current_function_decl)
|
||||
{
|
||||
error ("label's context is not the current function decl");
|
||||
error ("label%'s context is not the current function decl");
|
||||
err |= true;
|
||||
}
|
||||
|
||||
|
16
gcc/tree.c
16
gcc/tree.c
@ -13815,9 +13815,9 @@ verify_type_variant (const_tree t, tree tv)
|
||||
TYPE_SIZE_UNIT (tv), 0));
|
||||
error ("type variant has different TYPE_SIZE_UNIT");
|
||||
debug_tree (tv);
|
||||
error ("type variant's TYPE_SIZE_UNIT");
|
||||
error ("type variant%'s TYPE_SIZE_UNIT");
|
||||
debug_tree (TYPE_SIZE_UNIT (tv));
|
||||
error ("type's TYPE_SIZE_UNIT");
|
||||
error ("type%'s TYPE_SIZE_UNIT");
|
||||
debug_tree (TYPE_SIZE_UNIT (t));
|
||||
return false;
|
||||
}
|
||||
@ -13888,9 +13888,9 @@ verify_type_variant (const_tree t, tree tv)
|
||||
{
|
||||
error ("type variant has different TYPE_BINFO");
|
||||
debug_tree (tv);
|
||||
error ("type variant's TYPE_BINFO");
|
||||
error ("type variant%'s TYPE_BINFO");
|
||||
debug_tree (TYPE_BINFO (tv));
|
||||
error ("type's TYPE_BINFO");
|
||||
error ("type%'s TYPE_BINFO");
|
||||
debug_tree (TYPE_BINFO (t));
|
||||
return false;
|
||||
}
|
||||
@ -13952,9 +13952,9 @@ verify_type_variant (const_tree t, tree tv)
|
||||
{
|
||||
error ("type variant has different TREE_TYPE");
|
||||
debug_tree (tv);
|
||||
error ("type variant's TREE_TYPE");
|
||||
error ("type variant%'s TREE_TYPE");
|
||||
debug_tree (TREE_TYPE (tv));
|
||||
error ("type's TREE_TYPE");
|
||||
error ("type%'s TREE_TYPE");
|
||||
debug_tree (TREE_TYPE (t));
|
||||
return false;
|
||||
}
|
||||
@ -13963,9 +13963,9 @@ verify_type_variant (const_tree t, tree tv)
|
||||
{
|
||||
error ("type is not compatible with its variant");
|
||||
debug_tree (tv);
|
||||
error ("type variant's TREE_TYPE");
|
||||
error ("type variant%'s TREE_TYPE");
|
||||
debug_tree (TREE_TYPE (tv));
|
||||
error ("type's TREE_TYPE");
|
||||
error ("type%'s TREE_TYPE");
|
||||
debug_tree (TREE_TYPE (t));
|
||||
return false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user