[llvm] e6126fa - [libc++] Remove unused macro in __config
Louis Dionne via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 23 10:09:41 PDT 2021
Author: Louis Dionne
Date: 2021-09-23T13:09:32-04:00
New Revision: e6126faba060d5341dae6c5cc99a22a80d8c4d23
URL: https://github.com/llvm/llvm-project/commit/e6126faba060d5341dae6c5cc99a22a80d8c4d23
DIFF: https://github.com/llvm/llvm-project/commit/e6126faba060d5341dae6c5cc99a22a80d8c4d23.diff
LOG: [libc++] Remove unused macro in __config
That macro was being defined but not used anywhere in libc++, so it
must be safe to remove it.
As a fly-by fix, also remove mentions of this macro in other places
in LLVM, to make sure they were not depending on the value defined in
libc++.
Differential Revision: https://reviews.llvm.org/D110289
Added:
Modified:
clang-tools-extra/clangd/unittests/JSONTransportTests.cpp
libcxx/include/__config
llvm/lib/Support/LockFileManager.cpp
Removed:
################################################################################
diff --git a/clang-tools-extra/clangd/unittests/JSONTransportTests.cpp b/clang-tools-extra/clangd/unittests/JSONTransportTests.cpp
index 07ab70edbe3f4..76b7a97a3d61b 100644
--- a/clang-tools-extra/clangd/unittests/JSONTransportTests.cpp
+++ b/clang-tools-extra/clangd/unittests/JSONTransportTests.cpp
@@ -18,8 +18,8 @@ namespace {
// No fmemopen on windows or on versions of MacOS X earlier than 10.13, so we
// can't easily run this test.
-#if !(defined(_WIN32) || (defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && \
- __MAC_OS_X_VERSION_MIN_REQUIRED < 101300))
+#if !(defined(_WIN32) || (defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && \
+ __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 101300))
// Fixture takes care of managing the input/output buffers for the transport.
class JSONTransportTest : public ::testing::Test {
diff --git a/libcxx/include/__config b/libcxx/include/__config
index eab6ffba60cd8..e8d29a1d7203a 100644
--- a/libcxx/include/__config
+++ b/libcxx/include/__config
@@ -901,13 +901,6 @@ typedef unsigned int char32_t;
# define _LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION
#endif
-#if defined(__APPLE__)
-# if !defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && \
- defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__)
-# define __MAC_OS_X_VERSION_MIN_REQUIRED __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__
-# endif
-#endif // defined(__APPLE__)
-
#if defined(_LIBCPP_HAS_NO_LIBRARY_ALIGNED_ALLOCATION) || \
(!defined(__cpp_aligned_new) || __cpp_aligned_new < 201606)
# define _LIBCPP_HAS_NO_ALIGNED_ALLOCATION
diff --git a/llvm/lib/Support/LockFileManager.cpp b/llvm/lib/Support/LockFileManager.cpp
index a2b56ab295c42..5fd52999adb5a 100644
--- a/llvm/lib/Support/LockFileManager.cpp
+++ b/llvm/lib/Support/LockFileManager.cpp
@@ -35,7 +35,7 @@
#include <unistd.h>
#endif
-#if defined(__APPLE__) && defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && (__MAC_OS_X_VERSION_MIN_REQUIRED > 1050)
+#if defined(__APPLE__) && defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ > 1050)
#define USE_OSX_GETHOSTUUID 1
#else
#define USE_OSX_GETHOSTUUID 0
More information about the llvm-commits
mailing list