diff options
author | Pedro F. Giffuni <pfg@FreeBSD.org> | 2013-12-26 18:09:16 +0000 |
---|---|---|
committer | Pedro F. Giffuni <pfg@FreeBSD.org> | 2013-12-26 18:09:16 +0000 |
commit | 99dee3f5ae6e9d8493a4ff855f1a2200902d4d20 (patch) | |
tree | 670d4959615f613d312a17e30a84df526cfa3e71 /contrib/gcc/c-opts.c | |
parent | f870cb7f3b114e33d7b21a456979b4edffcc28e7 (diff) | |
download | src-99dee3f5ae6e9d8493a4ff855f1a2200902d4d20.tar.gz src-99dee3f5ae6e9d8493a4ff855f1a2200902d4d20.zip |
gcc: Implement -Wmost for compatibility with clang.
This is equivalent to -Wall -Wno-parentheses.
Obtained from: Apple GCC 4.2 - 5531
MFC after: 1 week
Notes
Notes:
svn path=/head/; revision=259920
Diffstat (limited to 'contrib/gcc/c-opts.c')
-rw-r--r-- | contrib/gcc/c-opts.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/contrib/gcc/c-opts.c b/contrib/gcc/c-opts.c index 6b290687c76d..39abfb33006d 100644 --- a/contrib/gcc/c-opts.c +++ b/contrib/gcc/c-opts.c @@ -385,12 +385,17 @@ c_common_handle_option (size_t scode, const char *arg, int value) 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 ()) |