diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-03-06 17:55:01 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-03-06 17:55:01 +0100 |
commit | f536bf6d4518e2c66e635e39820d53f672021d87 (patch) | |
tree | 2e6f505322191eb8753ed0dc46ccf7b11e1b60f9 | |
parent | fc6f16b57ce988cea6d07b5f2d5054711aad6bbf (diff) | |
download | vim-git-f536bf6d4518e2c66e635e39820d53f672021d87.tar.gz |
patch 8.0.1584: using C99 in Mac file gives compiler warning messagesv8.0.1584
Problem: Using C99 in Mac file gives compiler warning messages.
Solution: Add #prama's to avoid the warnings. (Kazunobu Kuriyama)
-rw-r--r-- | src/os_macosx.m | 14 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 16 insertions, 0 deletions
diff --git a/src/os_macosx.m b/src/os_macosx.m index 6fd72fd28..b0d29d947 100644 --- a/src/os_macosx.m +++ b/src/os_macosx.m @@ -11,6 +11,14 @@ * os_macosx.m -- Mac specific things for Mac OS X. */ +/* Suppress compiler warnings to non-C89 code. */ +#if defined(__clang__) && defined(__STRICT_ANSI__) +# pragma clang diagnostic push +# pragma clang diagnostic ignored "-Wc99-extensions" +# pragma clang diagnostic push +# pragma clang diagnostic ignored "-Wdeclaration-after-statement" +#endif + /* Avoid a conflict for the definition of Boolean between Mac header files and * X11 header files. */ #define NO_X11_INCLUDES @@ -189,3 +197,9 @@ releasepool: } #endif /* FEAT_CLIPBOARD */ + +/* Lift the compiler warning suppression. */ +#if defined(__clang__) && defined(__STRICT_ANSI__) +# pragma clang diagnostic pop +# pragma clang diagnostic pop +#endif diff --git a/src/version.c b/src/version.c index 40b161a14..a2165f20e 100644 --- a/src/version.c +++ b/src/version.c @@ -767,6 +767,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 1584, +/**/ 1583, /**/ 1582, |