[libcxx-commits] [libcxx] [libc++] Remove _LIBCPP_DISABLE_AVAILABILITY macro (PR #112952)
Louis Dionne via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Nov 19 15:39:11 PST 2024
https://github.com/ldionne updated https://github.com/llvm/llvm-project/pull/112952
>From 14d1e526cd4dec18b56aaf1a2134a2ecc22a7ac1 Mon Sep 17 00:00:00 2001
From: Louis Dionne <ldionne.2 at gmail.com>
Date: Fri, 18 Oct 2024 14:22:56 -0400
Subject: [PATCH] [libc++] Remove _LIBCPP_DISABLE_AVAILABILITY macro
This was slated for removal years ago, so now's a good time to remove it.
---
libcxx/docs/ReleaseNotes/20.rst | 3 +++
libcxx/include/__configuration/availability.h | 7 -------
2 files changed, 3 insertions(+), 7 deletions(-)
diff --git a/libcxx/docs/ReleaseNotes/20.rst b/libcxx/docs/ReleaseNotes/20.rst
index 9039c6f046445b..d520c46bae1ef1 100644
--- a/libcxx/docs/ReleaseNotes/20.rst
+++ b/libcxx/docs/ReleaseNotes/20.rst
@@ -102,6 +102,9 @@ Deprecations and Removals
headers as an extension and only deprecates them. The ``_LIBCPP_DISABLE_DEPRECATION_WARNINGS`` macro can be defined to
suppress deprecation for these headers.
+- 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 d805c5a4d978d3..efda2a04a4841d 100644
--- a/libcxx/include/__configuration/availability.h
+++ b/libcxx/include/__configuration/availability.h
@@ -67,13 +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)
-# undef _LIBCPP_HAS_VENDOR_AVAILABILITY_ANNOTATIONS
-# define _LIBCPP_HAS_VENDOR_AVAILABILITY_ANNOTATIONS 0
-#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)
More information about the libcxx-commits
mailing list