re PR lto/51806 (-flto ignores -Werror)

2012-01-10  Richard Guenther  <rguenther@suse.de>

	PR middle-end/51806
	c-family/
	* c-opts.c (c_common_handle_option): Move -Werror handling
	to language independent code.

	* opts.c (common_handle_option): Handle -Werror.

From-SVN: r183069
This commit is contained in:
Richard Guenther 2012-01-10 16:27:55 +00:00 committed by Richard Biener
parent b339cf22f1
commit aee1522197
4 changed files with 15 additions and 4 deletions

View file

@ -1,3 +1,8 @@
2012-01-10 Richard Guenther <rguenther@suse.de>
PR middle-end/51806
* opts.c (common_handle_option): Handle -Werror.
2012-01-10 Andreas Schwab <schwab@linux-m68k.org>
* config/m68k/sync.md ("atomic_compare_and_swap<mode>_1"): Fix

View file

@ -1,3 +1,9 @@
2012-01-10 Richard Guenther <rguenther@suse.de>
PR middle-end/51806
* c-opts.c (c_common_handle_option): Move -Werror handling
to language independent code.
2012-01-05 Richard Guenther <rguenther@suse.de>
PR middle-end/51764

View file

@ -449,10 +449,6 @@ c_common_handle_option (size_t scode, const char *arg, int value,
cpp_opts->warn_endif_labels = value;
break;
case OPT_Werror:
global_dc->warning_as_error_requested = value;
break;
case OPT_Wformat:
set_Wformat (value);
break;

View file

@ -1420,6 +1420,10 @@ common_handle_option (struct gcc_options *opts,
/* Currently handled in a prescan. */
break;
case OPT_Werror:
dc->warning_as_error_requested = value;
break;
case OPT_Werror_:
if (lang_mask == CL_DRIVER)
break;