[libcxx-commits] [libcxx] [libc++] Remove _LIBCPP_DISABLE_AVAILABILITY macro (PR #112952)
via libcxx-commits
libcxx-commits at lists.llvm.org
Fri Oct 18 11:24:19 PDT 2024
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-libcxx
Author: Louis Dionne (ldionne)
<details>
<summary>Changes</summary>
This was slated for removal years ago, so now's a good time to remove it.
---
Full diff: https://github.com/llvm/llvm-project/pull/112952.diff
2 Files Affected:
- (modified) libcxx/docs/ReleaseNotes/20.rst (+3)
- (modified) libcxx/include/__configuration/availability.h (-8)
``````````diff
diff --git a/libcxx/docs/ReleaseNotes/20.rst b/libcxx/docs/ReleaseNotes/20.rst
index 44912d2ddafac6..a212921ee1d73c 100644
--- a/libcxx/docs/ReleaseNotes/20.rst
+++ b/libcxx/docs/ReleaseNotes/20.rst
@@ -85,6 +85,9 @@ Deprecations and Removals
- The function ``__libcpp_verbose_abort()`` is now ``noexcept``, to match ``std::terminate()``. (The combination of
``noexcept`` and ``[[noreturn]]`` has special significance for function effects analysis.)
+- The ``_LIBCPP_DISABLE_AVAILABILITY`` macro that was used to force-disable availability markup has now been removed.
+ Whether availability markup is used by the library is now solely controlled at configuration-time.
+
Upcoming Deprecations and Removals
----------------------------------
diff --git a/libcxx/include/__configuration/availability.h b/libcxx/include/__configuration/availability.h
index f42ff460db4544..8dee132e2b0803 100644
--- a/libcxx/include/__configuration/availability.h
+++ b/libcxx/include/__configuration/availability.h
@@ -67,14 +67,6 @@
//
// [1]: https://clang.llvm.org/docs/AttributeReference.html#availability
-// For backwards compatibility, allow users to define _LIBCPP_DISABLE_AVAILABILITY
-// for a while.
-#if defined(_LIBCPP_DISABLE_AVAILABILITY)
-# if !defined(_LIBCPP_HAS_NO_VENDOR_AVAILABILITY_ANNOTATIONS)
-# define _LIBCPP_HAS_NO_VENDOR_AVAILABILITY_ANNOTATIONS
-# endif
-#endif
-
// Availability markup is disabled when building the library, or when a non-Clang
// compiler is used because only Clang supports the necessary attributes.
#if defined(_LIBCPP_BUILDING_LIBRARY) || defined(_LIBCXXABI_BUILDING_LIBRARY) || !defined(_LIBCPP_COMPILER_CLANG_BASED)
``````````
</details>
https://github.com/llvm/llvm-project/pull/112952
More information about the libcxx-commits
mailing list