summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLouis Dionne <ldionne@apple.com>2018-08-01 13:13:14 +0000
committerLouis Dionne <ldionne@apple.com>2018-08-01 13:13:14 +0000
commitf7410f4f856eaeb9c7c088763bd4ad26db635745 (patch)
tree97210fab3e0adcc211f1f126ba518c8897ebe37b
parent80f0ca024a4d979cfb703561ad54f92a609a9760 (diff)
[libc++] Fix GCC 7.2.0 macro redefinition warning
The warning happens when LIBCXX_ENABLE_EXCEPTIONS cmake option is not set, and it fires every time __config is included, 33 in total. Patch by Jason Lovett Reviewed as https://reviews.llvm.org/D49997 git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@338531 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--include/__config2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/__config b/include/__config
index bba7f53ba..639d06c9f 100644
--- a/include/__config
+++ b/include/__config
@@ -510,7 +510,7 @@ namespace std {
#define _LIBCPP_HAS_IS_BASE_OF
#endif
-#if !__EXCEPTIONS
+#if !__EXCEPTIONS && !defined(_LIBCPP_NO_EXCEPTIONS)
#define _LIBCPP_NO_EXCEPTIONS
#endif