svn commit: r260592 - in stable/8/contrib/gcc: . doc
Pedro F. Giffuni
pfg at FreeBSD.org
Mon Jan 13 15:32:38 UTC 2014
Author: pfg
Date: Mon Jan 13 15:32:37 2014
New Revision: 260592
URL: http://svnweb.freebsd.org/changeset/base/260592
Log:
MFC r259920:
gcc: Implement -Wmost for compatibility with clang.
This is equivalent to -Wall -Wno-parentheses.
Obtained from: Apple GCC 4.2 - 5531
Modified:
stable/8/contrib/gcc/c-opts.c
stable/8/contrib/gcc/c.opt
stable/8/contrib/gcc/doc/invoke.texi
Directory Properties:
stable/8/ (props changed)
stable/8/contrib/ (props changed)
stable/8/contrib/gcc/ (props changed)
Modified: stable/8/contrib/gcc/c-opts.c
==============================================================================
--- stable/8/contrib/gcc/c-opts.c Mon Jan 13 15:28:39 2014 (r260591)
+++ stable/8/contrib/gcc/c-opts.c Mon Jan 13 15:32:37 2014 (r260592)
@@ -385,12 +385,17 @@ c_common_handle_option (size_t scode, co
break;
case OPT_Wall:
+ /* APPLE LOCAL -Wmost */
+ case OPT_Wmost:
set_Wunused (value);
set_Wformat (value);
set_Wimplicit (value);
warn_char_subscripts = value;
warn_missing_braces = value;
- warn_parentheses = value;
+ /* APPLE LOCAL begin -Wmost --dpatel */
+ if (code != OPT_Wmost)
+ warn_parentheses = value;
+ /* APPLE LOCAL end -Wmost --dpatel */
warn_return_type = value;
warn_sequence_point = value; /* Was C only. */
if (c_dialect_cxx ())
Modified: stable/8/contrib/gcc/c.opt
==============================================================================
--- stable/8/contrib/gcc/c.opt Mon Jan 13 15:28:39 2014 (r260591)
+++ stable/8/contrib/gcc/c.opt Mon Jan 13 15:32:37 2014 (r260592)
@@ -284,6 +284,12 @@ Wmissing-prototypes
C ObjC Var(warn_missing_prototypes)
Warn about global functions without prototypes
+; APPLE LOCAL begin -Wmost
+Wmost
+C ObjC C++ ObjC++
+Like -Wall but without -Wparentheses
+; APPLE LOCAL end -Wmost
+
Wmultichar
C ObjC C++ ObjC++
Warn about use of multi-character character constants
Modified: stable/8/contrib/gcc/doc/invoke.texi
==============================================================================
--- stable/8/contrib/gcc/doc/invoke.texi Mon Jan 13 15:28:39 2014 (r260591)
+++ stable/8/contrib/gcc/doc/invoke.texi Mon Jan 13 15:32:37 2014 (r260592)
@@ -238,6 +238,8 @@ Objective-C and Objective-C++ Dialects}.
-Wmain -Wmissing-braces -Wmissing-field-initializers @gol
-Wmissing-format-attribute -Wmissing-include-dirs @gol
-Wmissing-noreturn @gol
+ at c APPLE LOCAL -Wmost
+-Wmost (APPLE ONLY) @gol
-Wno-multichar -Wnonnull -Wno-overflow @gol
-Woverlength-strings -Wpacked -Wpadded @gol
-Wparentheses -Wpointer-arith -Wno-pointer-to-int-cast @gol
@@ -2897,7 +2899,12 @@ that are easy to avoid (or modify to pre
conjunction with macros. This also enables some language-specific
warnings described in @ref{C++ Dialect Options} and
@ref{Objective-C and Objective-C++ Dialect Options}.
+ at c APPLE LOCAL begin -Wmost
+ at item -Wmost
+ at opindex Wmost
+This is equivalent to -Wall -Wno-parentheses. (Apple compatible)
@end table
+ at c APPLE LOCAL end -Wmost
The following @option{-W at dots{}} options are not implied by @option{-Wall}.
Some of them warn about constructions that users generally do not
More information about the svn-src-stable-8
mailing list