aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorarcadia-devtools <arcadia-devtools@yandex-team.ru>2022-02-17 14:08:52 +0300
committerarcadia-devtools <arcadia-devtools@yandex-team.ru>2022-02-17 14:08:52 +0300
commit3dba88133a0e2bf63394fdba2affc51a771eff03 (patch)
treed9eb307b57b580fca9129fd335395da3ecde090c
parent7db3dbedca2bc003b50e7cb8854706857eff1880 (diff)
downloadydb-3dba88133a0e2bf63394fdba2affc51a771eff03.tar.gz
intermediate changes
ref:73d3ea9a7c192b4410fcc6adf2c7999b376ed281
-rw-r--r--build/ymake.core.conf2
-rw-r--r--contrib/libs/cxxsupp/libcxx/include/tuple42
2 files changed, 38 insertions, 6 deletions
diff --git a/build/ymake.core.conf b/build/ymake.core.conf
index 6086fec0ba..8bc920940a 100644
--- a/build/ymake.core.conf
+++ b/build/ymake.core.conf
@@ -9,7 +9,7 @@
FAKEID=3141592653
SANDBOX_FAKEID=${FAKEID}.7600000
-CPP_FAKEID=9140489
+CPP_FAKEID=9140490
GO_FAKEID=9056219
ANDROID_FAKEID=8821472
CLANG_TIDY_FAKEID=8625699
diff --git a/contrib/libs/cxxsupp/libcxx/include/tuple b/contrib/libs/cxxsupp/libcxx/include/tuple
index 9b127953b3..be57f984dd 100644
--- a/contrib/libs/cxxsupp/libcxx/include/tuple
+++ b/contrib/libs/cxxsupp/libcxx/include/tuple
@@ -132,11 +132,14 @@ template <class T1, class... T>
// 20.4.1.6, relational operators:
template<class... T, class... U> bool operator==(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14
-template<class... T, class... U> bool operator<(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14
-template<class... T, class... U> bool operator!=(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14
-template<class... T, class... U> bool operator>(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14
-template<class... T, class... U> bool operator<=(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14
-template<class... T, class... U> bool operator>=(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14
+template<class... T, class... U> bool operator<(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14, removed in C++20
+template<class... T, class... U> bool operator!=(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14, removed in C++20
+template<class... T, class... U> bool operator>(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14, removed in C++20
+template<class... T, class... U> bool operator<=(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14, removed in C++20
+template<class... T, class... U> bool operator>=(const tuple<T...>&, const tuple<U...>&); // constexpr in C++14, removed in C++20
+template<class... T, class... U>
+ constexpr common_comparison_category_t<synth-three-way-result<T, U>...>
+ operator<=>(const tuple<T...>&, const tuple<U...>&); // since C++20
template <class... Types, class Alloc>
struct uses_allocator<tuple<Types...>, Alloc>;
@@ -149,6 +152,8 @@ template <class... Types>
*/
+#include <__compare/common_comparison_category.h>
+#include <__compare/synth_three_way.h>
#include <__config>
#include <__functional/unwrap_ref.h>
#include <__functional_base>
@@ -156,6 +161,7 @@ template <class... Types>
#include <__memory/uses_allocator.h>
#include <__tuple>
#include <__utility/forward.h>
+#include <__utility/integer_sequence.h>
#include <__utility/move.h>
#include <compare>
#include <cstddef>
@@ -1317,6 +1323,30 @@ operator==(const tuple<_Tp...>& __x, const tuple<_Up...>& __y)
return __tuple_equal<sizeof...(_Tp)>()(__x, __y);
}
+#if _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_SPACESHIP_OPERATOR) && !defined(_LIBCPP_HAS_NO_CONCEPTS)
+
+// operator<=>
+
+template <class ..._Tp, class ..._Up, size_t ..._Is>
+_LIBCPP_HIDE_FROM_ABI constexpr
+auto
+__tuple_compare_three_way(const tuple<_Tp...>& __x, const tuple<_Up...>& __y, index_sequence<_Is...>) {
+ common_comparison_category_t<__synth_three_way_result<_Tp, _Up>...> __result = strong_ordering::equal;
+ static_cast<void>(((__result = _VSTD::__synth_three_way(_VSTD::get<_Is>(__x), _VSTD::get<_Is>(__y)), __result != 0) || ...));
+ return __result;
+}
+
+template <class ..._Tp, class ..._Up>
+requires (sizeof...(_Tp) == sizeof...(_Up))
+_LIBCPP_HIDE_FROM_ABI constexpr
+common_comparison_category_t<__synth_three_way_result<_Tp, _Up>...>
+operator<=>(const tuple<_Tp...>& __x, const tuple<_Up...>& __y)
+{
+ return _VSTD::__tuple_compare_three_way(__x, __y, index_sequence_for<_Tp...>{});
+}
+
+#else // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_SPACESHIP_OPERATOR) && !defined(_LIBCPP_HAS_NO_CONCEPTS)
+
template <class ..._Tp, class ..._Up>
inline _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX11
bool
@@ -1385,6 +1415,8 @@ operator<=(const tuple<_Tp...>& __x, const tuple<_Up...>& __y)
return !(__y < __x);
}
+#endif // _LIBCPP_STD_VER > 17 && !defined(_LIBCPP_HAS_NO_SPACESHIP_OPERATOR) && !defined(_LIBCPP_HAS_NO_CONCEPTS)
+
// tuple_cat
template <class _Tp, class _Up> struct __tuple_cat_type;