From: Jakub Jelinek Date: Wed, 4 Jan 2017 21:26:50 +0000 (+0100) Subject: optc-gen.awk: Emit #error for -W*/-f*/-m* Enum without RejectNegative. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=742b18041a2624da73d57abfaa44b04fbe55fe37;p=gcc.git optc-gen.awk: Emit #error for -W*/-f*/-m* Enum without RejectNegative. * optc-gen.awk: Emit #error for -W*/-f*/-m* Enum without RejectNegative. From-SVN: r244073 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 242bf697bc4..5181fe80e06 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,8 @@ 2017-01-04 Jakub Jelinek + * optc-gen.awk: Emit #error for -W*/-f*/-m* Enum without + RejectNegative. + * dwarf2out.c (output_loc_list): Don't throw away 64K+ location descriptions for -gdwarf-5 and emit them as uleb128 instead of 2-byte data. diff --git a/gcc/optc-gen.awk b/gcc/optc-gen.awk index dd2251566be..cb3214a711c 100644 --- a/gcc/optc-gen.awk +++ b/gcc/optc-gen.awk @@ -326,6 +326,11 @@ for (i = 0; i < n_opts; i++) { alias_data = "NULL, NULL, OPT_SPECIAL_ignore" else alias_data = "NULL, NULL, N_OPTS" + if (flag_set_p("Enum.*", flags[i])) { + if (!flag_set_p("RejectNegative", flags[i]) \ + && opts[i] ~ "^[Wfm]") + print "#error Enum allowing negative form" + } } else { alias_opt = nth_arg(0, alias_arg) alias_posarg = nth_arg(1, alias_arg)