Skip to content

Conversation

@ldionne
Copy link
Member

@ldionne ldionne commented May 15, 2025

An LLVM 19-aligned libc++ was released with macOS 15.4 (and corresponding OSes), and LLVM-20 aligned with macOS 26.0. This patch adds availability markup to reflect that.

@ldionne ldionne requested a review from a team as a code owner May 15, 2025 14:56
@llvmbot llvmbot added the libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. label May 15, 2025
@llvmbot
Copy link
Member

llvmbot commented May 15, 2025

@llvm/pr-subscribers-libcxxabi

@llvm/pr-subscribers-libcxx

Author: Louis Dionne (ldionne)

Changes

An LLVM 19-aligned libc++ was released with macOS 15.4 (and corresponding OSes). This patch adds availability markup to reflect that.


Full diff: https://github.com/llvm/llvm-project/pull/140072.diff

1 Files Affected:

  • (modified) libcxx/include/__configuration/availability.h (+15-3)
diff --git a/libcxx/include/__configuration/availability.h b/libcxx/include/__configuration/availability.h
index bbcdfdc784e9d..78969c3a1cc1d 100644
--- a/libcxx/include/__configuration/availability.h
+++ b/libcxx/include/__configuration/availability.h
@@ -134,9 +134,21 @@
 #  define _LIBCPP_INTRODUCED_IN_LLVM_20_ATTRIBUTE __attribute__((unavailable))
 
 // LLVM 19
-// TODO: Fill this in
-#  define _LIBCPP_INTRODUCED_IN_LLVM_19 0
-#  define _LIBCPP_INTRODUCED_IN_LLVM_19_ATTRIBUTE __attribute__((unavailable))
+#  if (defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 150400) ||       \
+      (defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) && __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__ < 180400) ||     \
+      (defined(__ENVIRONMENT_TV_OS_VERSION_MIN_REQUIRED__) && __ENVIRONMENT_TV_OS_VERSION_MIN_REQUIRED__ < 180400) ||             \
+      (defined(__ENVIRONMENT_WATCH_OS_VERSION_MIN_REQUIRED__) && __ENVIRONMENT_WATCH_OS_VERSION_MIN_REQUIRED__ < 110400) ||       \
+      (defined(__ENVIRONMENT_BRIDGE_OS_VERSION_MIN_REQUIRED__) && __ENVIRONMENT_BRIDGE_OS_VERSION_MIN_REQUIRED__ < 90400)
+#    define _LIBCPP_INTRODUCED_IN_LLVM_19 0
+#  else
+#    define _LIBCPP_INTRODUCED_IN_LLVM_19 1
+#  endif
+#  define _LIBCPP_INTRODUCED_IN_LLVM_19_ATTRIBUTE                                                                 \
+    __attribute__((availability(macos, strict, introduced = 15.4)))                                               \
+    __attribute__((availability(ios, strict, introduced = 18.4)))                                                 \
+    __attribute__((availability(tvos, strict, introduced = 18.4)))                                                \
+    __attribute__((availability(watchos, strict, introduced = 11.4)))                                             \
+    __attribute__((availability(bridgeos, strict, introduced = 9.4)))
 
 // LLVM 18
 #  if (defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 150000) ||       \

An LLVM 19-aligned libc++ was released with macOS 15.4 (and
corresponding OSes). This patch adds availability markup to
reflect that.
@ldionne ldionne force-pushed the review/upstream-llvm-19-availability branch from 25771e2 to 310f995 Compare October 31, 2025 19:58
@ldionne ldionne requested a review from a team as a code owner October 31, 2025 20:00
@llvmbot llvmbot added the libc++abi libc++abi C++ Runtime Library. Not libc++. label Oct 31, 2025
@ldionne ldionne changed the title [libc++] Add availability markup for LLVM 19 [libc++] Add availability markup for LLVM 19 and LLVM 20 Nov 3, 2025
@ldionne ldionne merged commit 3252e11 into llvm:main Nov 3, 2025
78 checks passed
@ldionne ldionne deleted the review/upstream-llvm-19-availability branch November 3, 2025 01:24
DEBADRIBASAK pushed a commit to DEBADRIBASAK/llvm-project that referenced this pull request Nov 3, 2025
An LLVM 19-aligned libc++ was released with macOS 15.4 (and corresponding OSes),
and LLVM-20 aligned with macOS 26.0. This patch adds availability markup to
reflect that.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

libc++abi libc++abi C++ Runtime Library. Not libc++. libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants