summaryrefslogtreecommitdiff
path: root/gcc/opts.c
diff options
context:
space:
mode:
authormanu <manu@138bc75d-0d04-0410-961f-82ee72b054a4>2012-05-17 11:50:37 +0000
committermanu <manu@138bc75d-0d04-0410-961f-82ee72b054a4>2012-05-17 11:50:37 +0000
commitdb490cb60617aeb04e2e2e6633b258237d581a31 (patch)
tree9b9ef6fa3edd4dba37b6733c714b6a1103bd602c /gcc/opts.c
parent255b5d15717f1288b62041a9bc962d1b1fe86af0 (diff)
downloadgcc-db490cb60617aeb04e2e2e6633b258237d581a31.tar.gz
2012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
c-family/ * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here. * c-opts.c (c_common_handle_option): Do not handle explicitly Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors. gcc/ * opts.c (common_handle_option): -pedantic-errors enables -Wpedantic. (enable_warning_as_error): Do not special case Wuninitialized. * optc-gen.awk: Add sanity checks. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@187628 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/opts.c')
-rw-r--r--gcc/opts.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/gcc/opts.c b/gcc/opts.c
index ac43d4a2da7..58199c3bc3e 100644
--- a/gcc/opts.c
+++ b/gcc/opts.c
@@ -1712,8 +1712,11 @@ common_handle_option (struct gcc_options *opts,
break;
case OPT_pedantic_errors:
- opts->x_pedantic = 1;
dc->pedantic_errors = 1;
+ control_warning_option (OPT_Wpedantic, DK_ERROR, value,
+ loc, lang_mask,
+ handlers, opts, opts_set,
+ dc);
break;
case OPT_flto:
@@ -2012,9 +2015,6 @@ enable_warning_as_error (const char *arg, int value, unsigned int lang_mask,
control_warning_option (option_index, (int) kind, value,
loc, lang_mask,
handlers, opts, opts_set, dc);
- if (option_index == OPT_Wuninitialized)
- enable_warning_as_error ("maybe-uninitialized", value, lang_mask,
- handlers, opts, opts_set, loc, dc);
}
free (new_option);
}