[libc++] Replace _LIBCPP_HAS_NO_CONCEPTS with _LIBCPP_STD_VER > 17. NFCI.

All supported compilers that support C++20 now support concepts. So, remove
`_LIB_LIBCPP_HAS_NO_CONCEPTS` in favor of `_LIBCPP_STD_VER > 17`. Similarly in
the tests, remove `// UNSUPPORTED: libcpp-no-concepts`.

Differential Revision: https://reviews.llvm.org/D121528
This commit is contained in:
Joe Loser 2022-03-12 10:46:57 -05:00
parent c2592c374e
commit d2baefae68
No known key found for this signature in database
GPG Key ID: 1CDBEBC050EA230D
709 changed files with 292 additions and 1059 deletions

View File

@ -18,7 +18,7 @@
# pragma GCC system_header
#endif
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_BEGIN_NAMESPACE_STD
@ -44,6 +44,6 @@ struct in_found_result {
_LIBCPP_END_NAMESPACE_STD
#endif // _LIBCPP_HAS_NO_CONCEPTS
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP___ALGORITHM_IN_FOUND_RESULT_H

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#ifndef _LIBCPP_HAS_NO_CONCEPTS
#if _LIBCPP_STD_VER > 17
namespace ranges {
template <class _Ip, class _Fp>
@ -42,7 +42,7 @@ struct in_fun_result {
};
} // namespace ranges
#endif // _LIBCPP_HAS_NO_RANGES
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
@ -47,7 +47,7 @@ struct in_in_out_result {
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
namespace ranges {
@ -44,7 +44,7 @@ struct in_in_result {
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#ifndef _LIBCPP_HAS_NO_CONCEPTS
#if _LIBCPP_STD_VER > 17
namespace ranges {
template <class _I1, class _O1, class _O2>
@ -45,7 +45,7 @@ struct in_out_out_result {
};
} // namespace ranges
#endif // _LIBCPP_HAS_NO_CONCEPTS
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
@ -47,7 +47,7 @@ struct in_out_result {
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -23,7 +23,7 @@ _LIBCPP_PUSH_MACROS
_LIBCPP_BEGIN_NAMESPACE_STD
#if!defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
@ -47,7 +47,7 @@ struct min_max_result {
} // namespace ranges
#endif
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -23,7 +23,7 @@
# pragma GCC system_header
#endif
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_BEGIN_NAMESPACE_STD
@ -66,6 +66,6 @@ inline namespace __cpo {
_LIBCPP_END_NAMESPACE_STD
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP___ALGORITHM_RANGES_MAX_ELEMENT_H

View File

@ -24,7 +24,7 @@
# pragma GCC system_header
#endif
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_BEGIN_NAMESPACE_STD
@ -67,6 +67,6 @@ inline namespace __cpo {
_LIBCPP_END_NAMESPACE_STD
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP___ALGORITHM_RANGES_MIN_ELEMENT_H

View File

@ -27,7 +27,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
namespace ranges {
@ -78,7 +78,7 @@ inline namespace __cpo {
} // namespace __cpo
} // namespace ranges
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_RANGES)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -22,7 +22,7 @@
# pragma GCC system_header
#endif
#ifndef _LIBCPP_HAS_NO_CONCEPTS
#if _LIBCPP_STD_VER > 17
_LIBCPP_BEGIN_NAMESPACE_STD
@ -64,6 +64,6 @@ inline namespace __cpo {
_LIBCPP_END_NAMESPACE_STD
#endif // _LIBCPP_HAS_NO_RANGES
#endif // _LIBCPP_STD_VER > 17
#endif // _LIBCPP___ALGORITHM_RANGES_SWAP_RANGES_H

View File

@ -21,7 +21,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 20 && !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 20
template <integral _Tp>
_LIBCPP_HIDE_FROM_ABI constexpr _Tp byteswap(_Tp __val) noexcept {
@ -48,7 +48,7 @@ _LIBCPP_HIDE_FROM_ABI constexpr _Tp byteswap(_Tp __val) noexcept {
}
}
#endif // _LIBCPP_STD_VER > 20 && !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 20
_LIBCPP_END_NAMESPACE_STD

View File

@ -22,7 +22,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [cmp.alg]
namespace __compare_partial_order_fallback {
@ -66,7 +66,7 @@ inline namespace __cpo {
inline constexpr auto compare_partial_order_fallback = __compare_partial_order_fallback::__fn{};
} // namespace __cpo
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -22,7 +22,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [cmp.alg]
namespace __compare_strong_order_fallback {
@ -63,7 +63,7 @@ inline namespace __cpo {
inline constexpr auto compare_strong_order_fallback = __compare_strong_order_fallback::__fn{};
} // namespace __cpo
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
struct _LIBCPP_TEMPLATE_VIS compare_three_way
{
@ -34,7 +34,7 @@ struct _LIBCPP_TEMPLATE_VIS compare_three_way
using is_transparent = void;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -22,7 +22,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [cmp.alg]
namespace __compare_weak_order_fallback {
@ -63,7 +63,7 @@ inline namespace __cpo {
inline constexpr auto compare_weak_order_fallback = __compare_weak_order_fallback::__fn{};
} // namespace __cpo
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -23,7 +23,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [cmp.alg]
namespace __partial_order {
@ -64,7 +64,7 @@ inline namespace __cpo {
inline constexpr auto partial_order = __partial_order::__fn{};
} // namespace __cpo
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -29,7 +29,7 @@ _LIBCPP_PUSH_MACROS
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [cmp.alg]
namespace __strong_order {
@ -127,7 +127,7 @@ inline namespace __cpo {
inline constexpr auto strong_order = __strong_order::__fn{};
} // namespace __cpo
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -21,7 +21,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [expos.only.func]
@ -44,7 +44,7 @@ _LIBCPP_HIDE_FROM_ABI inline constexpr auto __synth_three_way =
template <class _Tp, class _Up = _Tp>
using __synth_three_way_result = decltype(std::__synth_three_way(declval<_Tp&>(), declval<_Up&>()));
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -24,7 +24,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template<class _Tp, class _Cat>
concept __compares_as =
@ -51,7 +51,7 @@ concept three_way_comparable_with =
{ __u <=> __t } -> __compares_as<_Cat>;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -24,7 +24,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [cmp.alg]
namespace __weak_order {
@ -93,7 +93,7 @@ inline namespace __cpo {
inline constexpr auto weak_order = __weak_order::__fn{};
} // namespace __cpo
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -18,7 +18,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concepts.arithmetic], arithmetic concepts
@ -41,7 +41,7 @@ concept __libcpp_unsigned_integer = __libcpp_is_unsigned_integer<_Tp>::value;
template <class _Tp>
concept __libcpp_signed_integer = __libcpp_is_signed_integer<_Tp>::value;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -21,7 +21,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.assignable]
@ -33,7 +33,7 @@ concept assignable_from =
{ __lhs = _VSTD::forward<_Rhs>(__rhs) } -> same_as<_Lhs>;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -19,7 +19,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concepts.booleantestable]
@ -31,7 +31,7 @@ concept __boolean_testable = __boolean_testable_impl<_Tp> && requires(_Tp&& __t)
{ !_VSTD::forward<_Tp>(__t) } -> __boolean_testable_impl;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -18,7 +18,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// Whether a type is a class type or enumeration type according to the Core wording.
@ -30,7 +30,7 @@ concept __class_or_enum = is_class_v<_Tp> || is_union_v<_Tp> || is_enum_v<_Tp>;
template<class _Tp>
concept __workaround_52970 = is_class_v<__uncvref_t<_Tp>> || is_union_v<__uncvref_t<_Tp>>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.commonref]
@ -30,7 +30,7 @@ concept common_reference_with =
convertible_to<_Tp, common_reference_t<_Tp, _Up>> &&
convertible_to<_Up, common_reference_t<_Tp, _Up>>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.common]
@ -40,7 +40,7 @@ concept common_with =
add_lvalue_reference_t<const _Tp>,
add_lvalue_reference_t<const _Up>>>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.constructible]
template<class _Tp, class... _Args>
@ -49,7 +49,7 @@ concept copy_constructible =
constructible_from<_Tp, const _Tp&> && convertible_to<const _Tp&, _Tp> &&
constructible_from<_Tp, const _Tp> && convertible_to<const _Tp, _Tp>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -19,7 +19,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.convertible]
@ -30,7 +30,7 @@ concept convertible_to =
static_cast<_To>(declval<_From>());
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concepts.object]
@ -32,7 +32,7 @@ concept copyable =
assignable_from<_Tp&, const _Tp&> &&
assignable_from<_Tp&, const _Tp>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -18,7 +18,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.derived]
@ -27,7 +27,7 @@ concept derived_from =
is_base_of_v<_Bp, _Dp> &&
is_convertible_v<const volatile _Dp*, const volatile _Bp*>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -18,14 +18,14 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.destructible]
template<class _Tp>
concept destructible = is_nothrow_destructible_v<_Tp>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -19,12 +19,12 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template<class _Tp, class _Up>
concept __different_from = !same_as<remove_cvref_t<_Tp>, remove_cvref_t<_Up>>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.equalitycomparable]
@ -46,7 +46,7 @@ concept equality_comparable_with =
__make_const_lvalue_ref<_Up>>> &&
__weakly_equality_comparable_with<_Tp, _Up>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.invocable]
@ -34,7 +34,7 @@ concept invocable = requires(_Fn&& __fn, _Args&&... __args) {
template<class _Fn, class... _Args>
concept regular_invocable = invocable<_Fn, _Args...>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -21,7 +21,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concepts.object]
@ -32,7 +32,7 @@ concept movable =
assignable_from<_Tp&, _Tp> &&
swappable<_Tp>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.predicate]
@ -28,7 +28,7 @@ template<class _Fn, class... _Args>
concept predicate =
regular_invocable<_Fn, _Args...> && __boolean_testable<invoke_result_t<_Fn, _Args...>>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -19,14 +19,14 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.object]
template<class _Tp>
concept regular = semiregular<_Tp> && equality_comparable<_Tp>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -18,7 +18,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.relation]
@ -37,7 +37,7 @@ concept equivalence_relation = relation<_Rp, _Tp, _Up>;
template<class _Rp, class _Tp, class _Up>
concept strict_weak_order = relation<_Rp, _Tp, _Up>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -18,7 +18,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.same]
@ -28,7 +28,7 @@ concept __same_as_impl = _IsSame<_Tp, _Up>::value;
template<class _Tp, class _Up>
concept same_as = __same_as_impl<_Tp, _Up> && __same_as_impl<_Up, _Tp>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -19,14 +19,14 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.object]
template<class _Tp>
concept semiregular = copyable<_Tp> && default_initializable<_Tp>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -25,7 +25,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.swappable]
@ -109,7 +109,7 @@ concept swappable_with =
ranges::swap(_VSTD::forward<_Up>(__u), _VSTD::forward<_Tp>(__t));
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [concept.totallyordered]
@ -50,7 +50,7 @@ concept totally_ordered_with =
__make_const_lvalue_ref<_Up>>> &&
__partially_ordered_with<_Tp, _Up>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -763,10 +763,6 @@ typedef unsigned int char32_t;
# define _LIBCPP_CONSTEVAL consteval
#endif
#if _LIBCPP_STD_VER <= 17 || !defined(__cpp_concepts) || __cpp_concepts < 201907L
#define _LIBCPP_HAS_NO_CONCEPTS
#endif
#ifdef __GNUC__
# define _LIBCPP_NOALIAS __attribute__((__malloc__))
#else

View File

@ -137,7 +137,7 @@ _LIBCPP_AVAILABILITY_FILESYSTEM_POP
_LIBCPP_END_NAMESPACE_FILESYSTEM
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template <>
_LIBCPP_AVAILABILITY_FILESYSTEM
@ -147,7 +147,7 @@ template <>
_LIBCPP_AVAILABILITY_FILESYSTEM
inline constexpr bool _VSTD::ranges::enable_view<_VSTD_FS::directory_iterator> = true;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
#endif // _LIBCPP_CXX03_LANG

View File

@ -168,7 +168,7 @@ _LIBCPP_AVAILABILITY_FILESYSTEM_POP
_LIBCPP_END_NAMESPACE_FILESYSTEM
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template <>
_LIBCPP_AVAILABILITY_FILESYSTEM
@ -178,7 +178,7 @@ template <>
_LIBCPP_AVAILABILITY_FILESYSTEM
inline constexpr bool _VSTD::ranges::enable_view<_VSTD_FS::recursive_directory_iterator> = true;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
#endif // _LIBCPP_CXX03_LANG

View File

@ -30,12 +30,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format {
/// The type stored in @ref basic_format_arg.
///
@ -279,8 +273,6 @@ private:
}) {}
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -23,12 +23,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
template <class _Context>
class _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT basic_format_args {
public:
@ -57,8 +51,6 @@ private:
const basic_format_arg<_Context>* __data_{nullptr};
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -31,12 +31,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
template <class _OutIt, class _CharT>
requires output_iterator<_OutIt, const _CharT&>
class _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT basic_format_context;
@ -151,8 +145,6 @@ private:
#endif
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -21,12 +21,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
template <class _Context>
class _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT basic_format_arg;
@ -36,8 +30,6 @@ struct _LIBCPP_TEMPLATE_VIS __format_arg_store;
template <class _Tp, class _CharT = char>
struct _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT formatter;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -22,12 +22,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
template <class _CharT>
class _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT basic_format_parse_context {
public:
@ -100,8 +94,6 @@ using format_parse_context = basic_format_parse_context<char>;
using wformat_parse_context = basic_format_parse_context<wchar_t>;
#endif
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -24,12 +24,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format {
template <class _CharT>
@ -160,8 +154,6 @@ __parse_arg_id(const _CharT* __begin, const _CharT* __end, auto& __parse_ctx) {
} // namespace __format
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -21,19 +21,12 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
template <class _OutIt>
struct _LIBCPP_TEMPLATE_VIS format_to_n_result {
_OutIt out;
iter_difference_t<_OutIt> size;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -32,12 +32,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
/// The default formatter template.
///
/// [format.formatter.spec]/5
@ -279,8 +273,6 @@ __write_unicode(output_iterator<const _CharT&> auto __out_it,
} // namespace __formatter
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -31,12 +31,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format_spec {
template <class _CharT>
@ -134,8 +128,6 @@ struct _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT formatter<bool, _CharT>
}
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -26,12 +26,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format_spec {
template <class _CharT>
@ -95,7 +89,6 @@ struct _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT
formatter<wchar_t, wchar_t>
: public __format_spec::__formatter_char<wchar_t> {};
#endif // _LIBCPP_HAS_NO_WIDE_CHARACTERS
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17

View File

@ -46,12 +46,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
# if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format_spec {
template <floating_point _Tp>
@ -707,8 +701,6 @@ template <__formatter::__char_type _CharT>
struct _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT formatter<long double, _CharT>
: public __format_spec::__formatter_floating_point<_CharT> {};
# endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -30,12 +30,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format_spec {
template <class _CharT>
@ -159,8 +153,6 @@ struct _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT
};
#endif
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -42,12 +42,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
/**
* Integral formatting classes.
*
@ -454,8 +448,6 @@ private:
} // namespace __format_spec
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -30,12 +30,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
# if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format_spec {
template <__formatter::__char_type _CharT>
@ -81,8 +75,6 @@ template <__formatter::__char_type _CharT>
struct _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT formatter<const void*, _CharT>
: public __format_spec::__formatter_pointer<_CharT> {};
# endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -27,12 +27,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format_spec {
template <__formatter::__char_type _CharT>
@ -149,8 +143,6 @@ struct _LIBCPP_TEMPLATE_VIS _LIBCPP_AVAILABILITY_FORMAT formatter<basic_string_v
}
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -34,12 +34,6 @@ _LIBCPP_BEGIN_NAMESPACE_STD
#if _LIBCPP_STD_VER > 17
// TODO FMT Remove this once we require compilers with proper C++20 support.
// If the compiler has no concepts support, the format header will be disabled.
// Without concepts support enable_if needs to be used and that too much effort
// to support compilers with partial C++20 support.
# if !defined(_LIBCPP_HAS_NO_CONCEPTS)
namespace __format_spec {
/**
@ -1389,8 +1383,6 @@ __get_string_alignment(const _CharT* __first, const _CharT* __last,
} // namespace __format_spec
# endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif //_LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
namespace ranges {
@ -92,7 +92,7 @@ struct greater_equal {
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -65,7 +65,7 @@ void advance(_InputIter& __i, _Distance __orig_n) {
_VSTD::__advance(__i, __n, typename iterator_traits<_InputIter>::iterator_category());
}
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
// [range.iter.op.advance]
@ -193,7 +193,7 @@ inline namespace __cpo {
} // namespace __cpo
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -27,7 +27,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template<class _Iter>
concept __can_use_postfix_proxy =
@ -263,7 +263,7 @@ struct iterator_traits<common_iterator<_Iter, _Sent>> {
using reference = iter_reference_t<_Iter>;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -26,7 +26,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [iterator.concept.readable]
template<class _In>
@ -273,7 +273,7 @@ concept indirectly_copyable_storable =
// Note: indirectly_swappable is located in iter_swap.h to prevent a dependency cycle
// (both iter_swap and indirectly_swappable require indirectly_readable).
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -30,7 +30,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template<class>
struct __counted_iterator_concept {};
@ -296,7 +296,7 @@ struct iterator_traits<counted_iterator<_Iter>> : iterator_traits<_Iter> {
add_pointer_t<iter_reference_t<_Iter>>, void>;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -52,7 +52,7 @@ distance(_InputIter __first, _InputIter __last)
return _VSTD::__distance(__first, __last, typename iterator_traits<_InputIter>::iterator_category());
}
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
// [range.iter.op.distance]
@ -100,7 +100,7 @@ inline namespace __cpo {
} // namespace __cpo
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [incrementable.traits]
template<class> struct incrementable_traits {};
@ -65,7 +65,7 @@ using iter_difference_t = typename conditional_t<__is_primary_template<iterator_
incrementable_traits<remove_cvref_t<_Ip> >,
iterator_traits<remove_cvref_t<_Ip> > >::difference_type;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -21,13 +21,13 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template <class _I1, class _I2, class _Rp, class _P1 = identity, class _P2 = identity>
concept indirectly_comparable =
indirect_binary_predicate<_Rp, projected<_I1, _P1>, projected<_I2, _P2>>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -24,7 +24,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
template <class _Container>
using __insert_iterator_iter_t = ranges::iterator_t<_Container>;
#else

View File

@ -23,7 +23,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [iterator.cust.move]
@ -92,7 +92,7 @@ template<__dereferenceable _Tp>
requires requires(_Tp& __t) { { ranges::iter_move(__t) } -> __can_reference; }
using iter_rvalue_reference_t = decltype(ranges::iter_move(declval<_Tp&>()));
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -25,7 +25,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [iter.cust.swap]
@ -99,7 +99,7 @@ concept indirectly_swappable =
ranges::iter_swap(__i2, __i1);
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -22,7 +22,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template <class _Tp>
using __with_reference = _Tp&;
@ -41,7 +41,7 @@ concept __dereferenceable = requires(_Tp& __t) {
template<__dereferenceable _Tp>
using iter_reference_t = decltype(*declval<_Tp&>());
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
template <class _Iter>
struct _LIBCPP_TEMPLATE_VIS iterator_traits;
@ -139,7 +139,7 @@ public:
static const bool value = sizeof(__test<_Tp>(nullptr)) == 1;
};
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// The `cpp17-*-iterator` exposition-only concepts are easily confused with the Cpp17*Iterator tables,
// so they've been banished to a namespace that makes it obvious they have a niche use-case.
@ -362,7 +362,7 @@ struct iterator_traits : __iterator_traits<_Ip> {
using __primary_template = iterator_traits;
};
#else // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#else // _LIBCPP_STD_VER > 17
template <class _Iter, bool> struct __iterator_traits {};
@ -399,10 +399,10 @@ struct _LIBCPP_TEMPLATE_VIS iterator_traits
using __primary_template = iterator_traits;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
template<class _Tp>
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
requires is_object_v<_Tp>
#endif
struct _LIBCPP_TEMPLATE_VIS iterator_traits<_Tp*>

View File

@ -22,7 +22,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template <class _Input1, class _Input2, class _Output,
class _Comp = ranges::less, class _Proj1 = identity, class _Proj2 = identity>
@ -34,7 +34,7 @@ concept mergeable =
indirectly_copyable<_Input2, _Output> &&
indirect_strict_weak_order<_Comp, projected<_Input1, _Proj1>, projected<_Input2, _Proj2>>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -35,7 +35,7 @@ inline _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX14
return __x;
}
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
// [range.iter.op.next]
@ -79,7 +79,7 @@ inline namespace __cpo {
} // namespace __cpo
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template <class _Iterator>
concept permutable =
@ -28,7 +28,7 @@ concept permutable =
indirectly_movable_storable<_Iterator, _Iterator> &&
indirectly_swappable<_Iterator, _Iterator>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -34,7 +34,7 @@ inline _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX14
return __x;
}
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
// [range.iter.op.prev]
@ -71,7 +71,7 @@ inline namespace __cpo {
} // namespace __cpo
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template<indirectly_readable _It, indirectly_regular_unary_invocable<_It> _Proj>
struct projected {
@ -33,7 +33,7 @@ struct incrementable_traits<projected<_It, _Proj>> {
using difference_type = iter_difference_t<_It>;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [readable.traits]
template<class> struct __cond_value_type {};
@ -79,7 +79,7 @@ using iter_value_t = typename conditional_t<__is_primary_template<iterator_trait
indirectly_readable_traits<remove_cvref_t<_Ip> >,
iterator_traits<remove_cvref_t<_Ip> > >::value_type;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -184,7 +184,7 @@ operator<=(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>&
return __x.base() >= __y.base();
}
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template <class _Iter1, three_way_comparable_with<_Iter1> _Iter2>
_LIBCPP_HIDE_FROM_ABI constexpr
compare_three_way_result_t<_Iter1, _Iter2>
@ -192,7 +192,7 @@ operator<=>(const reverse_iterator<_Iter1>& __x, const reverse_iterator<_Iter2>&
{
return __y.base() <=> __x.base();
}
#endif
#endif // _LIBCPP_STD_VER > 17
#ifndef _LIBCPP_CXX03_LANG
template <class _Iter1, class _Iter2>

View File

@ -23,14 +23,14 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
template <class _Iter, class _Comp = ranges::less, class _Proj = identity>
concept sortable =
permutable<_Iter> &&
indirect_strict_weak_order<_Comp, projected<_Iter, _Proj>>;
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -19,7 +19,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
struct unreachable_sentinel_t {
template<weakly_incrementable _Iter>
@ -31,7 +31,7 @@ struct unreachable_sentinel_t {
inline constexpr unreachable_sentinel_t unreachable_sentinel{};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -25,7 +25,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
@ -61,7 +61,7 @@ concept __nothrow_forward_range =
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -29,7 +29,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
// construct_at
@ -117,7 +117,7 @@ inline namespace __cpo {
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -32,7 +32,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
@ -311,7 +311,7 @@ inline namespace __cpo {
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -24,7 +24,7 @@ _LIBCPP_PUSH_MACROS
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
// [rand.req.urng]
template<class _Gen>
@ -36,7 +36,7 @@ concept uniform_random_bit_generator =
requires bool_constant<(_Gen::min() < _Gen::max())>::value;
};
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -23,7 +23,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
namespace ranges {
template <class _Tp>
@ -218,7 +218,7 @@ inline namespace __cpo {
} // namespace __cpo
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -28,7 +28,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges::views {
@ -75,7 +75,7 @@ using all_t = decltype(views::all(declval<_Range>()));
} // namespace ranges::views
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -30,7 +30,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
@ -128,7 +128,7 @@ inline namespace __cpo {
} // namespace views
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -32,7 +32,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
namespace ranges {
@ -139,7 +139,7 @@ namespace ranges {
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -24,7 +24,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
// __copyable_box allows turning a type that is copy-constructible (but maybe not copy-assignable) into
// a type that is both copy-constructible and copy-assignable. It does that by introducing an empty state
@ -171,7 +171,7 @@ namespace ranges {
};
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -29,7 +29,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges::views {
@ -74,7 +74,7 @@ inline namespace __cpo {
} // namespace ranges::views
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -21,7 +21,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
namespace ranges {
struct dangling {
@ -35,7 +35,7 @@ using borrowed_iterator_t = _If<borrowed_range<_Rp>, iterator_t<_Rp>, dangling>;
// borrowed_subrange_t defined in <__ranges/subrange.h>
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -24,7 +24,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
// [range.prim.data]
@ -99,7 +99,7 @@ inline namespace __cpo {
} // namespace __cpo
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -31,7 +31,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
template<view _View>
@ -120,7 +120,7 @@ public:
inline constexpr bool enable_borrowed_range<drop_view<_Tp>> = enable_borrowed_range<_Tp>;
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -22,7 +22,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
// [range.prim.empty]
@ -75,7 +75,7 @@ inline namespace __cpo {
} // namespace __cpo
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
namespace ranges {
template<class _Tp>
@ -38,7 +38,7 @@ namespace ranges {
inline constexpr bool enable_borrowed_range<empty_view<_Tp>> = true;
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS) && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_INCOMPLETE_RANGES)
_LIBCPP_END_NAMESPACE_STD

View File

@ -22,7 +22,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
namespace ranges {
@ -33,7 +33,7 @@ inline constexpr bool enable_borrowed_range = false;
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

View File

@ -20,7 +20,7 @@
_LIBCPP_BEGIN_NAMESPACE_STD
#if !defined(_LIBCPP_HAS_NO_CONCEPTS)
#if _LIBCPP_STD_VER > 17
namespace ranges {
@ -40,7 +40,7 @@ inline constexpr bool enable_view = derived_from<_Tp, view_base> ||
} // namespace ranges
#endif // !defined(_LIBCPP_HAS_NO_CONCEPTS)
#endif // _LIBCPP_STD_VER > 17
_LIBCPP_END_NAMESPACE_STD

Some files were not shown because too many files have changed in this diff Show More