[libcxx-commits] [libcxx] [libc++] Officially remove _VSTD and _LIBCPP_INLINE_VISIBILITY (PR #79885)

Louis Dionne via libcxx-commits libcxx-commits at lists.llvm.org
Mon Jan 29 11:37:22 PST 2024


https://github.com/ldionne created https://github.com/llvm/llvm-project/pull/79885

Those were deprecated and basically not used anymore after we renamed them in batch. This patch removes the macros entirely.

>From 7ebe2ca858c578bd3ce0bbb20369ca2b6e57fd8a Mon Sep 17 00:00:00 2001
From: Louis Dionne <ldionne.2 at gmail.com>
Date: Mon, 29 Jan 2024 14:36:17 -0500
Subject: [PATCH] [libc++] Officially remove _VSTD and
 _LIBCPP_INLINE_VISIBILITY

Those were deprecated and basically not used anymore after we renamed
them in batch. This patch removes the macros entirely.
---
 libcxx/docs/ReleaseNotes/19.rst            | 4 +---
 libcxx/include/__config                    | 5 -----
 libcxx/include/__format/format_functions.h | 4 ++--
 3 files changed, 3 insertions(+), 10 deletions(-)

diff --git a/libcxx/docs/ReleaseNotes/19.rst b/libcxx/docs/ReleaseNotes/19.rst
index 17a0415a8ad4364..6ba0924297bb2aa 100644
--- a/libcxx/docs/ReleaseNotes/19.rst
+++ b/libcxx/docs/ReleaseNotes/19.rst
@@ -70,9 +70,7 @@ Deprecations and Removals
 - TODO: The ``_LIBCPP_ENABLE_CXX17_REMOVED_FEATURES`` and ``_LIBCPP_ENABLE_CXX20_REMOVED_FEATURES`` macros have
   been removed in LLVM 19. C++17 and C++20 removed features can still be re-enabled individually.
 
-- TODO: The macro ``_LIBCPP_INLINE_VISIBILITY`` has been removed in LLVM 19.
-
-- TODO: The macro ``_VSTD`` has been removed in LLVM 19.
+- The ``_LIBCPP_INLINE_VISIBILITY`` and ``_VSTD`` macros have been removed in LLVM 19.
 
 
 Upcoming Deprecations and Removals
diff --git a/libcxx/include/__config b/libcxx/include/__config
index 8d27e7744e447b2..16b965db301a6b5 100644
--- a/libcxx/include/__config
+++ b/libcxx/include/__config
@@ -874,11 +874,6 @@ typedef __char32_t char32_t;
 #    define _LIBCPP_HIDE_FROM_ABI_AFTER_V1 _LIBCPP_HIDE_FROM_ABI
 #  endif
 
-// TODO(LLVM-19): Remove _LIBCPP_INLINE_VISIBILITY and _VSTD, which we're keeping around
-//                only to ease the renaming for downstreams.
-#  define _LIBCPP_INLINE_VISIBILITY _LIBCPP_HIDE_FROM_ABI
-#  define _VSTD std
-
 // Inline namespaces are available in Clang/GCC/MSVC regardless of C++ dialect.
 // clang-format off
 #  define _LIBCPP_BEGIN_NAMESPACE_STD namespace _LIBCPP_TYPE_VISIBILITY_DEFAULT std {                                  \
diff --git a/libcxx/include/__format/format_functions.h b/libcxx/include/__format/format_functions.h
index cf833ad20554412..3ee53539f4ee6cb 100644
--- a/libcxx/include/__format/format_functions.h
+++ b/libcxx/include/__format/format_functions.h
@@ -67,14 +67,14 @@ using wformat_args = basic_format_args<wformat_context>;
 
 template <class _Context = format_context, class... _Args>
 _LIBCPP_NODISCARD_EXT _LIBCPP_HIDE_FROM_ABI __format_arg_store<_Context, _Args...> make_format_args(_Args&... __args) {
-  return _VSTD::__format_arg_store<_Context, _Args...>(__args...);
+  return std::__format_arg_store<_Context, _Args...>(__args...);
 }
 
 #  ifndef _LIBCPP_HAS_NO_WIDE_CHARACTERS
 template <class... _Args>
 _LIBCPP_NODISCARD_EXT _LIBCPP_HIDE_FROM_ABI __format_arg_store<wformat_context, _Args...>
 make_wformat_args(_Args&... __args) {
-  return _VSTD::__format_arg_store<wformat_context, _Args...>(__args...);
+  return std::__format_arg_store<wformat_context, _Args...>(__args...);
 }
 #  endif
 



More information about the libcxx-commits mailing list