OSDN Git Service

2012-01-10 Richard Guenther <rguenther@suse.de>
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 10 Jan 2012 16:27:55 +0000 (16:27 +0000)
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 10 Jan 2012 16:27:55 +0000 (16:27 +0000)
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.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@183069 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/c-family/ChangeLog
gcc/c-family/c-opts.c
gcc/opts.c

index 22535bd..cfd0a86 100644 (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
index 95ce166..10a9ddd 100644 (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
index 3a4d8a8..4f0d886 100644 (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;
index 2ed5560..6532b56 100644 (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;