[libcxx-commits] [libcxx] [libc++][NFC] Add reminder to remove _LIBCPP_HAS_EXPLICIT_THIS_PARAMETER macro (PR #127070)

Hristo Hristov via libcxx-commits libcxx-commits at lists.llvm.org
Thu Feb 13 07:06:04 PST 2025


https://github.com/H-G-Hristov created https://github.com/llvm/llvm-project/pull/127070

`__cpp_explicit_this_parameter` has been set in LLVM20
// https://github.com/llvm/llvm-project/pull/107451

>From a89edd0694b304ee4c08647876d6d3fc4b6eba9d Mon Sep 17 00:00:00 2001
From: Hristo Hristov <hghristov.rmm at gmail.com>
Date: Thu, 13 Feb 2025 17:05:22 +0200
Subject: [PATCH] [libc++][NFC] Add reminder to remove
 _LIBCPP_HAS_EXPLICIT_THIS_PARAMETER macro

`__cpp_explicit_this_parameter` has been set in LLVM20
// https://github.com/llvm/llvm-project/pull/107451
---
 libcxx/include/__config | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libcxx/include/__config b/libcxx/include/__config
index ca6aade34107b..5c8c72fce5921 100644
--- a/libcxx/include/__config
+++ b/libcxx/include/__config
@@ -1198,6 +1198,8 @@ typedef __char32_t char32_t;
 #    define _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK
 #  endif
 
+// TODO(LLVM 22): Remove this macro once LLVM19 support ends. __cpp_explicit_this_parameter has been set in LLVM20
+// https://github.com/llvm/llvm-project/pull/107451
 // Clang-18 has support for deducing this, but it does not set the FTM.
 #  if defined(__cpp_explicit_this_parameter) || (defined(_LIBCPP_CLANG_VER) && _LIBCPP_CLANG_VER >= 1800)
 #    define _LIBCPP_HAS_EXPLICIT_THIS_PARAMETER 1



More information about the libcxx-commits mailing list