Skip to content

Commit 17197b3

Browse files
committed
Try to fix Apple CI
1 parent f4078bf commit 17197b3

File tree

3 files changed

+18
-1
lines changed

3 files changed

+18
-1
lines changed

libcxx/include/__type_traits/reference_constructs_from_temporary.h

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,14 @@
1818

1919
_LIBCPP_BEGIN_NAMESPACE_STD
2020

21+
#if __has_builtin(__reference_converts_from_temporary) || \
22+
(defined(_LIBCPP_COMPILER_CLANG_BASED) && (__clang_major__ >= 19) && (__clang_minor__ >= 1) && \
23+
(__clang_patchlevel__ >= 2))
24+
2125
template <class _Tp, class _Up>
2226
const bool __reference_constructs_from_temporary_v = __reference_constructs_from_temporary(_Tp, _Up);
2327

24-
#if _LIBCPP_STD_VER >= 23
28+
# if _LIBCPP_STD_VER >= 23
2529

2630
template <class _Tp, class _Up>
2731
struct _LIBCPP_TEMPLATE_VIS _LIBCPP_NO_SPECIALIZATIONS reference_constructs_from_temporary
@@ -31,6 +35,8 @@ template <class _Tp, class _Up>
3135
_LIBCPP_NO_SPECIALIZATIONS inline constexpr bool reference_constructs_from_temporary_v =
3236
__reference_constructs_from_temporary_v<_Tp, _Up>;
3337

38+
# endif
39+
3440
#endif
3541

3642
_LIBCPP_END_NAMESPACE_STD

libcxx/modules/std/type_traits.inc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,11 @@ export namespace std {
107107
using std::has_unique_object_representations;
108108

109109
#if _LIBCPP_STD_VER >= 23
110+
# if __has_builtin(__reference_constructs_from_temporary) || \
111+
(defined(_LIBCPP_COMPILER_CLANG_BASED) && (__clang_major__ >= 19) && (__clang_minor__ >= 1) && \
112+
(__clang_patchlevel__ >= 2))
110113
using std::reference_constructs_from_temporary;
114+
# endif
111115
# if __has_builtin(__reference_converts_from_temporary) || \
112116
(defined(_LIBCPP_COMPILER_CLANG_BASED) && (__clang_major__ >= 19) && (__clang_minor__ >= 1) && \
113117
(__clang_patchlevel__ >= 2))
@@ -291,7 +295,11 @@ export namespace std {
291295
using std::is_unsigned_v;
292296
using std::is_volatile_v;
293297
#if _LIBCPP_STD_VER >= 23
298+
# if __has_builtin(__reference_constructs_from_temporary) || \
299+
(defined(_LIBCPP_COMPILER_CLANG_BASED) && (__clang_major__ >= 19) && (__clang_minor__ >= 1) && \
300+
(__clang_patchlevel__ >= 2))
294301
using std::reference_constructs_from_temporary_v;
302+
# endif
295303
# if __has_builtin(__reference_converts_from_temporary) || \
296304
(defined(_LIBCPP_COMPILER_CLANG_BASED) && (__clang_major__ >= 19) && (__clang_minor__ >= 1) && \
297305
(__clang_patchlevel__ >= 2))

libcxx/test/std/utilities/meta/meta.unary/meta.unary.prop/reference_constructs_from_temporary.pass.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@
88

99
// REQUIRES: std-at-least-c++23
1010

11+
// These compilers don't support std::reference_converts_from_temporary yet.
12+
// UNSUPPORTED: apple-clang, clang-19.1.0, clang-19.1.1
13+
1114
// <type_traits>
1215

1316
// template<class T, class U> struct reference_constructs_from_temporary;

0 commit comments

Comments
 (0)