Wrap option names in gcc internal messages with %< and %>.
authorMartin Liska <mliska@suse.cz>
Mon, 11 Mar 2019 13:58:44 +0000 (14:58 +0100)
committerMartin Liska <marxin@gcc.gnu.org>
Mon, 11 Mar 2019 13:58:44 +0000 (13:58 +0000)
commita3f9f006a8e24bfc2a045b918a4f3665407f0018
tree0681cfed14dcbfd9b59a61ace8c6b34b885c20fd
parent355d4eb36aeb970743537e2f9b98d4c53c9e0eab
Wrap option names in gcc internal messages with %< and %>.

2019-03-11  Martin Liska  <mliska@suse.cz>

* check-internal-format-escaping.py: New file.
2019-03-11  Martin Liska  <mliska@suse.cz>

* builtins.c (expand_builtin_thread_pointer): Wrap an option name
in a string format message and fix GNU coding style.
(expand_builtin_set_thread_pointer): Likewise.
* common/config/aarch64/aarch64-common.c (aarch64_rewrite_selected_cpu): Likewise.
* common/config/alpha/alpha-common.c (alpha_handle_option): Likewise.
* common/config/arc/arc-common.c (arc_handle_option): Likewise.
* common/config/arm/arm-common.c (arm_parse_fpu_option): Likewise.
* common/config/bfin/bfin-common.c (bfin_handle_option): Likewise.
* common/config/i386/i386-common.c (ix86_handle_option): Likewise.
* common/config/ia64/ia64-common.c (ia64_handle_option): Likewise.
* common/config/m68k/m68k-common.c (m68k_handle_option): Likewise.
* common/config/msp430/msp430-common.c (msp430_handle_option): Likewise.
* common/config/nds32/nds32-common.c (nds32_handle_option): Likewise.
* common/config/powerpcspe/powerpcspe-common.c (rs6000_handle_option): Likewise.
* common/config/riscv/riscv-common.c (riscv_subset_list::parsing_subset_version): Likewise.
(riscv_subset_list::parse_std_ext): Likewise.
(riscv_subset_list::parse_sv_or_non_std_ext): Likewise.
(riscv_subset_list::parse): Likewise.
* common/config/rs6000/rs6000-common.c (rs6000_handle_option): Likewise.
* config/aarch64/aarch64.c (aarch64_parse_one_option_token): Likewise.
(aarch64_override_options_internal): Likewise.
(aarch64_validate_mcpu): Likewise.
(aarch64_validate_march): Likewise.
(aarch64_validate_mtune): Likewise.
(aarch64_override_options): Likewise.
* config/alpha/alpha.c (alpha_option_override): Likewise.
* config/arc/arc.c (arc_init): Likewise.
(parse_mrgf_banked_regs_option): Likewise.
(arc_override_options): Likewise.
(arc_expand_builtin_aligned): Likewise.
* config/arm/arm-builtins.c (arm_expand_neon_builtin): Likewise.
(arm_expand_builtin): Likewise.
* config/arm/arm.c (arm_option_check_internal): Likewise.
(arm_configure_build_target): Likewise.
(arm_option_override): Likewise.
(arm_options_perform_arch_sanity_checks): Likewise.
(arm_handle_cmse_nonsecure_entry): Likewise.
(arm_handle_cmse_nonsecure_call): Likewise.
(arm_tls_referenced_p): Likewise.
(thumb1_expand_prologue): Likewise.
* config/avr/avr.c (avr_option_override): Likewise.
* config/bfin/bfin.c (bfin_option_override): Likewise.
* config/c6x/c6x.c (c6x_option_override): Likewise.
* config/cr16/cr16.c (cr16_override_options): Likewise.
* config/cris/cris.c (cris_option_override): Likewise.
* config/csky/csky.c (csky_handle_isr_attribute): Likewise.
* config/darwin-c.c (macosx_version_as_macro): Likewise.
* config/darwin.c (darwin_override_options): Likewise.
* config/frv/frv.c (frv_expand_builtin): Likewise.
* config/h8300/h8300.c (h8300_option_override): Likewise.
* config/i386/i386.c (parse_mtune_ctrl_str): Likewise.
(ix86_option_override_internal): Likewise.
(warn_once_call_ms2sysv_xlogues): Likewise.
(ix86_expand_prologue): Likewise.
(split_stack_prologue_scratch_regno): Likewise.
(ix86_warn_parameter_passing_abi): Likewise.
* config/ia64/ia64.c (fix_range): Likewise.
* config/m68k/m68k.c (m68k_option_override): Likewise.
* config/microblaze/microblaze.c (microblaze_option_override): Likewise.
* config/mips/mips.c (mips_emit_probe_stack_range): Likewise.
(mips_set_compression_mode): Likewise.
* config/mmix/mmix.c (mmix_option_override): Likewise.
* config/mn10300/mn10300.c (mn10300_option_override): Likewise.
* config/msp430/msp430.c (msp430_option_override): Likewise.
* config/nds32/nds32.c (nds32_option_override): Likewise.
* config/nios2/nios2.c (nios2_custom_check_insns): Likewise.
(nios2_option_override): Likewise.
(nios2_expand_custom_builtin): Likewise.
* config/nvptx/mkoffload.c (main): Likewise.
* config/nvptx/nvptx.c (diagnose_openacc_conflict): Likewise.
* config/pa/pa.c (fix_range): Likewise.
(pa_option_override): Likewise.
* config/riscv/riscv.c (riscv_parse_cpu): Likewise.
(riscv_option_override): Likewise.
* config/rl78/rl78.c (rl78_option_override): Likewise.
* config/rs6000/aix61.h: Likewise.
* config/rs6000/aix71.h: Likewise.
* config/rs6000/aix72.h: Likewise.
* config/rs6000/driver-rs6000.c (elf_platform): Likewise.
* config/rs6000/freebsd64.h: Likewise.
* config/rs6000/linux64.h: Likewise.
* config/rs6000/rs6000.c (rs6000_option_override_internal): Likewise.
(rs6000_expand_zeroop_builtin): Likewise.
(rs6000_expand_mtfsb_builtin): Likewise.
(rs6000_expand_set_fpscr_rn_builtin): Likewise.
(rs6000_expand_set_fpscr_drn_builtin): Likewise.
(rs6000_invalid_builtin): Likewise.
(rs6000_expand_split_stack_prologue): Likewise.
* config/rs6000/rtems.h: Likewise.
* config/rx/rx.c (valid_psw_flag): Likewise.
(rx_expand_builtin): Likewise.
* config/s390/s390-c.c (s390_resolve_overloaded_builtin): Likewise.
* config/s390/s390.c (s390_expand_builtin): Likewise.
(s390_function_profiler): Likewise.
(s390_option_override_internal): Likewise.
(s390_option_override): Likewise.
* config/sh/sh.c (sh_option_override): Likewise.
(sh_builtin_saveregs): Likewise.
(sh_fix_range): Likewise.
* config/sh/vxworks.h: Likewise.
* config/sparc/sparc.c (sparc_option_override): Likewise.
* config/spu/spu.c (spu_option_override): Likewise.
(fix_range): Likewise.
* config/visium/visium.c (visium_option_override): Likewise.
(visium_handle_interrupt_attr): Likewise.
* config/xtensa/xtensa.c (xtensa_option_override): Likewise.
* dbgcnt.c (dbg_cnt_set_limit_by_name): Likewise.
(dbg_cnt_process_opt): Likewise.
* dwarf2out.c (output_dwarf_version): Likewise.
* except.c (expand_eh_return): Likewise.
* gcc.c (defined): Likewise.
(driver_handle_option): Likewise.
(process_command): Likewise.
(compare_files): Likewise.
(driver::prepare_infiles): Likewise.
(driver::do_spec_on_infiles): Likewise.
(driver::maybe_run_linker): Likewise.
* omp-offload.c (oacc_parse_default_dims): Likewise.
* opts-global.c (handle_common_deferred_options): Likewise.
* opts.c (parse_sanitizer_options): Likewise.
(common_handle_option): Likewise.
(enable_warning_as_error): Likewise.
* passes.c (enable_disable_pass): Likewise.
* plugin.c (parse_plugin_arg_opt): Likewise.
(default_plugin_dir_name): Likewise.
* targhooks.c (default_expand_builtin_saveregs): Likewise.
(default_pch_valid_p): Likewise.
* toplev.c (init_asm_output): Likewise.
(process_options): Likewise.
(toplev::run_self_tests): Likewise.
* tree-cfg.c (verify_gimple_call): Likewise.
* tree-inline.c (inline_forbidden_p_stmt): Likewise.
(tree_inlinable_function_p): Likewise.
* var-tracking.c (vt_find_locations): Likewise.
2019-03-11  Martin Liska  <mliska@suse.cz>

* gcc-interface/misc.c (gnat_post_options) Wrap an option name
in a string format message and fix GNU coding style.:
2019-03-11  Martin Liska  <mliska@suse.cz>

* c-attribs.c (handle_nocf_check_attribute): Wrap an option name
in a string format message and fix GNU coding style.
* c-common.c (vector_types_convertible_p): Likewise.
(c_build_vec_perm_expr): Likewise.
* c-indentation.c (get_visual_column): Likewise.
* c-opts.c (c_common_handle_option): Likewise.
(c_common_post_options): Likewise.
(sanitize_cpp_opts): Likewise.
* c-pch.c (c_common_pch_pragma): Likewise.
* c-pragma.c (handle_pragma_pack): Likewise.
2019-03-11  Martin Liska  <mliska@suse.cz>

* c-decl.c (check_for_loop_decls): Wrap an option name
in a string format message and fix GNU coding style.
* c-parser.c (c_parser_declspecs): Likewise.
2019-03-11  Martin Liska  <mliska@suse.cz>

* call.c (convert_arg_to_ellipsis): Wrap an option name
in a string format message and fix GNU coding style.
(build_over_call): Likewise.
* class.c (check_field_decl): Likewise.
(layout_nonempty_base_or_field): Likewise.
* constexpr.c (cxx_eval_loop_expr): Likewise.
* cvt.c (type_promotes_to): Likewise.
* decl.c (cxx_init_decl_processing): Likewise.
(mark_inline_variable): Likewise.
(grokdeclarator): Likewise.
* decl2.c (record_mangling): Likewise.
* error.c (maybe_warn_cpp0x): Likewise.
* except.c (doing_eh): Likewise.
* mangle.c (maybe_check_abi_tags): Likewise.
* parser.c (cp_parser_diagnose_invalid_type_name): Likewise.
(cp_parser_userdef_numeric_literal): Likewise.
(cp_parser_primary_expression): Likewise.
(cp_parser_unqualified_id): Likewise.
(cp_parser_pseudo_destructor_name): Likewise.
(cp_parser_builtin_offsetof): Likewise.
(cp_parser_lambda_expression): Likewise.
(cp_parser_lambda_introducer): Likewise.
(cp_parser_lambda_declarator_opt): Likewise.
(cp_parser_selection_statement): Likewise.
(cp_parser_init_statement): Likewise.
(cp_parser_decomposition_declaration): Likewise.
(cp_parser_function_specifier_opt): Likewise.
(cp_parser_static_assert): Likewise.
(cp_parser_simple_type_specifier): Likewise.
(cp_parser_namespace_definition): Likewise.
(cp_parser_using_declaration): Likewise.
(cp_parser_ctor_initializer_opt_and_function_body): Likewise.
(cp_parser_initializer_list): Likewise.
(cp_parser_type_parameter_key): Likewise.
(cp_parser_member_declaration): Likewise.
(cp_parser_try_block): Likewise.
(cp_parser_std_attribute_spec): Likewise.
(cp_parser_requires_clause_opt): Likewise.
* pt.c (check_template_variable): Likewise.
(check_default_tmpl_args): Likewise.
(push_tinst_level_loc): Likewise.
(instantiate_pending_templates): Likewise.
(invalid_nontype_parm_type_p): Likewise.
* repo.c (get_base_filename): Likewise.
* rtti.c (typeid_ok_p): Likewise.
(build_dynamic_cast_1): Likewise.
* tree.c (maybe_warn_parm_abi): Likewise.
2019-03-11  Martin Liska  <mliska@suse.cz>

* decl.c (match_record_decl): Wrap an option name
in a string format message and fix GNU coding style.
(gfc_match_pointer): Likewise.
* expr.c (find_array_section): Likewise.
* intrinsic.c (gfc_is_intrinsic): Likewise.
* options.c (gfc_post_options): Likewise.
* primary.c (match_integer_constant): Likewise.
* trans-common.c (translate_common): Likewise.
2019-03-11  Martin Liska  <mliska@suse.cz>

* lto-lang.c (lto_post_options): Wrap an option name
in a string format message and fix GNU coding style.
* lto-symtab.c (lto_symtab_merge_decls_2): Likewise.
2019-03-11  Martin Liska  <mliska@suse.cz>

* g++.dg/conversion/simd3.C (foo): Wrap option names
with apostrophe character.
* g++.dg/cpp1z/decomp3.C (test): Likewise.
(test3): Likewise.
* g++.dg/cpp1z/decomp4.C (test): Likewise.
* g++.dg/cpp1z/decomp44.C (foo): Likewise.
* g++.dg/cpp1z/decomp45.C (f): Likewise.
* g++.dg/opt/pr34036.C: Likewise.
* g++.dg/spellcheck-c++-11-keyword.C: Likewise.
* gcc.dg/c90-fordecl-1.c (foo): Likewise.
* gcc.dg/cpp/dir-only-4.c: Likewise.
* gcc.dg/cpp/dir-only-5.c: Likewise.
* gcc.dg/cpp/pr71591.c: Likewise.
* gcc.dg/format/opt-1.c: Likewise.
* gcc.dg/format/opt-2.c: Likewise.
* gcc.dg/format/opt-3.c: Likewise.
* gcc.dg/format/opt-4.c: Likewise.
* gcc.dg/format/opt-5.c: Likewise.
* gcc.dg/format/opt-6.c: Likewise.
* gcc.dg/pr22231.c: Likewise.
* gcc.dg/pr33007.c: Likewise.
* gcc.dg/simd-1.c (hanneke): Likewise.
* gcc.dg/simd-5.c: Likewise.
* gcc.dg/simd-6.c: Likewise.
* gcc.dg/spellcheck-options-14.c: Likewise.
* gcc.dg/spellcheck-options-15.c: Likewise.
* gcc.dg/spellcheck-options-16.c: Likewise.
* gcc.dg/spellcheck-options-17.c: Likewise.
* gcc.dg/tree-ssa/pr23109.c: Likewise.
* gcc.dg/tree-ssa/recip-5.c: Likewise.
* gcc.target/i386/cet-notrack-1a.c (func): Likewise.
(__attribute__): Likewise.
* gcc.target/i386/cet-notrack-icf-1.c (fn3): Likewise.
* gcc.target/i386/cet-notrack-icf-3.c (__attribute__): Likewise.
* gcc.target/powerpc/warn-1.c: Likewise.
* gcc.target/powerpc/warn-2.c: Likewise.

From-SVN: r269586
149 files changed:
contrib/ChangeLog
contrib/check-internal-format-escaping.py [new file with mode: 0755]
gcc/ChangeLog
gcc/ada/ChangeLog
gcc/ada/gcc-interface/misc.c
gcc/builtins.c
gcc/c-family/ChangeLog
gcc/c-family/c-attribs.c
gcc/c-family/c-common.c
gcc/c-family/c-indentation.c
gcc/c-family/c-opts.c
gcc/c-family/c-pch.c
gcc/c-family/c-pragma.c
gcc/c/ChangeLog
gcc/c/c-decl.c
gcc/c/c-parser.c
gcc/common/config/aarch64/aarch64-common.c
gcc/common/config/alpha/alpha-common.c
gcc/common/config/arc/arc-common.c
gcc/common/config/arm/arm-common.c
gcc/common/config/bfin/bfin-common.c
gcc/common/config/i386/i386-common.c
gcc/common/config/ia64/ia64-common.c
gcc/common/config/m68k/m68k-common.c
gcc/common/config/msp430/msp430-common.c
gcc/common/config/nds32/nds32-common.c
gcc/common/config/powerpcspe/powerpcspe-common.c
gcc/common/config/riscv/riscv-common.c
gcc/common/config/rs6000/rs6000-common.c
gcc/config/aarch64/aarch64.c
gcc/config/alpha/alpha.c
gcc/config/arc/arc.c
gcc/config/arm/arm-builtins.c
gcc/config/arm/arm.c
gcc/config/avr/avr.c
gcc/config/bfin/bfin.c
gcc/config/c6x/c6x.c
gcc/config/cr16/cr16.c
gcc/config/cris/cris.c
gcc/config/csky/csky.c
gcc/config/darwin-c.c
gcc/config/darwin.c
gcc/config/frv/frv.c
gcc/config/h8300/h8300.c
gcc/config/i386/i386.c
gcc/config/ia64/ia64.c
gcc/config/m68k/m68k.c
gcc/config/microblaze/microblaze.c
gcc/config/mips/mips.c
gcc/config/mmix/mmix.c
gcc/config/mn10300/mn10300.c
gcc/config/msp430/msp430.c
gcc/config/nds32/nds32.c
gcc/config/nios2/nios2.c
gcc/config/nvptx/mkoffload.c
gcc/config/nvptx/nvptx.c
gcc/config/pa/pa.c
gcc/config/riscv/riscv.c
gcc/config/rl78/rl78.c
gcc/config/rs6000/aix61.h
gcc/config/rs6000/aix71.h
gcc/config/rs6000/aix72.h
gcc/config/rs6000/driver-rs6000.c
gcc/config/rs6000/freebsd64.h
gcc/config/rs6000/linux64.h
gcc/config/rs6000/rs6000.c
gcc/config/rs6000/rtems.h
gcc/config/rx/rx.c
gcc/config/s390/s390-c.c
gcc/config/s390/s390.c
gcc/config/sh/sh.c
gcc/config/sh/vxworks.h
gcc/config/sparc/sparc.c
gcc/config/spu/spu.c
gcc/config/visium/visium.c
gcc/config/xtensa/xtensa.c
gcc/cp/ChangeLog
gcc/cp/call.c
gcc/cp/class.c
gcc/cp/constexpr.c
gcc/cp/cvt.c
gcc/cp/decl.c
gcc/cp/decl2.c
gcc/cp/error.c
gcc/cp/except.c
gcc/cp/mangle.c
gcc/cp/parser.c
gcc/cp/pt.c
gcc/cp/repo.c
gcc/cp/rtti.c
gcc/cp/tree.c
gcc/dbgcnt.c
gcc/dwarf2out.c
gcc/except.c
gcc/fortran/ChangeLog
gcc/fortran/decl.c
gcc/fortran/expr.c
gcc/fortran/intrinsic.c
gcc/fortran/options.c
gcc/fortran/primary.c
gcc/fortran/trans-common.c
gcc/gcc.c
gcc/lto/ChangeLog
gcc/lto/lto-lang.c
gcc/lto/lto-symtab.c
gcc/omp-offload.c
gcc/opts-global.c
gcc/opts.c
gcc/passes.c
gcc/plugin.c
gcc/targhooks.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/conversion/simd3.C
gcc/testsuite/g++.dg/cpp1z/decomp3.C
gcc/testsuite/g++.dg/cpp1z/decomp4.C
gcc/testsuite/g++.dg/cpp1z/decomp44.C
gcc/testsuite/g++.dg/cpp1z/decomp45.C
gcc/testsuite/g++.dg/opt/pr34036.C
gcc/testsuite/g++.dg/spellcheck-c++-11-keyword.C
gcc/testsuite/gcc.dg/c90-fordecl-1.c
gcc/testsuite/gcc.dg/cpp/dir-only-4.c
gcc/testsuite/gcc.dg/cpp/dir-only-5.c
gcc/testsuite/gcc.dg/cpp/pr71591.c
gcc/testsuite/gcc.dg/format/opt-1.c
gcc/testsuite/gcc.dg/format/opt-2.c
gcc/testsuite/gcc.dg/format/opt-3.c
gcc/testsuite/gcc.dg/format/opt-4.c
gcc/testsuite/gcc.dg/format/opt-5.c
gcc/testsuite/gcc.dg/format/opt-6.c
gcc/testsuite/gcc.dg/pr22231.c
gcc/testsuite/gcc.dg/pr33007.c
gcc/testsuite/gcc.dg/simd-1.c
gcc/testsuite/gcc.dg/simd-5.c
gcc/testsuite/gcc.dg/simd-6.c
gcc/testsuite/gcc.dg/spellcheck-options-14.c
gcc/testsuite/gcc.dg/spellcheck-options-15.c
gcc/testsuite/gcc.dg/spellcheck-options-16.c
gcc/testsuite/gcc.dg/spellcheck-options-17.c
gcc/testsuite/gcc.dg/tree-ssa/pr23109.c
gcc/testsuite/gcc.dg/tree-ssa/recip-5.c
gcc/testsuite/gcc.target/i386/cet-notrack-1a.c
gcc/testsuite/gcc.target/i386/cet-notrack-icf-1.c
gcc/testsuite/gcc.target/i386/cet-notrack-icf-3.c
gcc/testsuite/gcc.target/powerpc/warn-1.c
gcc/testsuite/gcc.target/powerpc/warn-2.c
gcc/toplev.c
gcc/tree-cfg.c
gcc/tree-inline.c
gcc/var-tracking.c