diff options
author | mikhnenko <mikhnenko@yandex-team.com> | 2023-12-15 19:01:31 +0300 |
---|---|---|
committer | mikhnenko <mikhnenko@yandex-team.com> | 2023-12-15 23:42:15 +0300 |
commit | 0d259c4e4b9c15299d4b7aa3e875bff771c1eecb (patch) | |
tree | b837d24d62cf0751d194559536d1919887ff8cb2 | |
parent | 575896e786912fe28f56c16df6edd2f14dcdafb5 (diff) | |
download | ydb-0d259c4e4b9c15299d4b7aa3e875bff771c1eecb.tar.gz |
Remove more old patches
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/__config | 3 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/__tuple | 7 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/__utility/integer_sequence.h | 11 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/cstddef | 4 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/deque | 4 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/mutex | 2 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/numbers | 26 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/type_traits | 8 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/valarray | 2 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/variant | 13 | ||||
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/src/include/refstring.h | 2 |
11 files changed, 29 insertions, 53 deletions
diff --git a/contrib/libs/cxxsupp/libcxx/include/__config b/contrib/libs/cxxsupp/libcxx/include/__config index 8436f608cd..552cfb757c 100644 --- a/contrib/libs/cxxsupp/libcxx/include/__config +++ b/contrib/libs/cxxsupp/libcxx/include/__config @@ -41,9 +41,6 @@ # else # define _LIBCPP_STD_VER 14 # endif - -# define Y_UCRT_INCLUDE_NEXT(x) <Y_UCRT_INCLUDE/x> -# define Y_MSVC_INCLUDE_NEXT(x) <Y_MSVC_INCLUDE/x> #endif #ifdef __cplusplus diff --git a/contrib/libs/cxxsupp/libcxx/include/__tuple b/contrib/libs/cxxsupp/libcxx/include/__tuple index 533bad01de..9c7b9464fe 100644 --- a/contrib/libs/cxxsupp/libcxx/include/__tuple +++ b/contrib/libs/cxxsupp/libcxx/include/__tuple @@ -87,6 +87,9 @@ template <size_t...> struct __tuple_indices {}; template <class _IdxType, _IdxType... _Values> struct __integer_sequence { + template <template <class _OIdxType, _OIdxType...> class _ToIndexSeq, class _ToIndexType> + using __convert = _ToIndexSeq<_ToIndexType, _Values...>; + template <size_t _Sp> using __to_tuple_indices = __tuple_indices<(_Values + _Sp)...>; }; @@ -402,13 +405,13 @@ template <bool ..._Preds> struct __all_dummy; template <bool ..._Pred> -struct __all : _IsSame<__all_dummy<_Pred...>, __all_dummy<(_Pred, true)...>>{}; +struct __all : _IsSame<__all_dummy<_Pred...>, __all_dummy<((void)_Pred, true)...>> {}; struct __tuple_sfinae_base { template <template <class, class...> class _Trait, class ..._LArgs, class ..._RArgs> static auto __do_test(__tuple_types<_LArgs...>, __tuple_types<_RArgs...>) - -> __all<_Trait<_LArgs, _RArgs>::value...>; + -> __all<__enable_if_t<_Trait<_LArgs, _RArgs>::value, bool>{true}...>; template <template <class...> class> static auto __do_test(...) -> false_type; diff --git a/contrib/libs/cxxsupp/libcxx/include/__utility/integer_sequence.h b/contrib/libs/cxxsupp/libcxx/include/__utility/integer_sequence.h index 00a944dd02..633f1333e2 100644 --- a/contrib/libs/cxxsupp/libcxx/include/__utility/integer_sequence.h +++ b/contrib/libs/cxxsupp/libcxx/include/__utility/integer_sequence.h @@ -43,17 +43,8 @@ using __make_integer_sequence _LIBCPP_NODEBUG = __make_integer_seq<integer_seque #else -template <class _Tp, class _T> struct __integer_sequence_convert { - using type = integer_sequence<_Tp>; -}; - -template<class _Tp, class _Tp2, _Tp... _Values> -struct __integer_sequence_convert<_Tp, __integer_sequence<_Tp2, _Values...>> { - using type = integer_sequence<_Tp, _Values...>; -}; - template<typename _Tp, _Tp _Np> using __make_integer_sequence_unchecked _LIBCPP_NODEBUG = - typename __integer_sequence_convert<_Tp, typename __detail::__make<_Np>::type>::type; + typename __detail::__make<_Np>::type::template __convert<integer_sequence, _Tp>; template <class _Tp, _Tp _Ep> struct __make_integer_sequence_checked diff --git a/contrib/libs/cxxsupp/libcxx/include/cstddef b/contrib/libs/cxxsupp/libcxx/include/cstddef index 5e3e99fb66..8daba076d7 100644 --- a/contrib/libs/cxxsupp/libcxx/include/cstddef +++ b/contrib/libs/cxxsupp/libcxx/include/cstddef @@ -45,10 +45,6 @@ Types: # pragma GCC system_header #endif -#ifdef _LIBCPP_ABI_VCRUNTIME -typedef double max_align_t; -#endif - _LIBCPP_BEGIN_NAMESPACE_STD using ::nullptr_t; diff --git a/contrib/libs/cxxsupp/libcxx/include/deque b/contrib/libs/cxxsupp/libcxx/include/deque index 8ffa97c756..8e8d98eebc 100644 --- a/contrib/libs/cxxsupp/libcxx/include/deque +++ b/contrib/libs/cxxsupp/libcxx/include/deque @@ -2431,7 +2431,7 @@ void deque<_Tp, _Allocator>::__add_front_capacity() { allocator_type& __a = __base::__alloc(); - if (__back_spare() >= size_type(__base::__block_size)) + if (__back_spare() >= __base::__block_size) { __base::__start_ += __base::__block_size; pointer __pt = __base::__map_.back(); @@ -2576,7 +2576,7 @@ void deque<_Tp, _Allocator>::__add_back_capacity() { allocator_type& __a = __base::__alloc(); - if (__front_spare() >= size_type(__base::__block_size)) + if (__front_spare() >= __base::__block_size) { __base::__start_ -= __base::__block_size; pointer __pt = __base::__map_.front(); diff --git a/contrib/libs/cxxsupp/libcxx/include/mutex b/contrib/libs/cxxsupp/libcxx/include/mutex index 1d1d3e05e2..d207c2664b 100644 --- a/contrib/libs/cxxsupp/libcxx/include/mutex +++ b/contrib/libs/cxxsupp/libcxx/include/mutex @@ -717,7 +717,7 @@ call_once(once_flag& __flag, const _Callable& __func) #if defined(_LIBCPP_ABI_MICROSOFT) if (__flag.__state_.load(memory_order_relaxed) != ~once_flag::_State_type(0)) #else - if (__flag.__state_ != ~once_flag::_State_type(0)) + if (__libcpp_acquire_load(&__flag.__state_) != ~once_flag::_State_type(0)) #endif { __call_once_param<const _Callable> __p(__func); diff --git a/contrib/libs/cxxsupp/libcxx/include/numbers b/contrib/libs/cxxsupp/libcxx/include/numbers index ca32c466f3..3c8527dfc2 100644 --- a/contrib/libs/cxxsupp/libcxx/include/numbers +++ b/contrib/libs/cxxsupp/libcxx/include/numbers @@ -97,19 +97,19 @@ template <class _Tp> inline constexpr _Tp inv_sqrt3_v = __illformed<_Tp>{}; template <class _Tp> inline constexpr _Tp egamma_v = __illformed<_Tp>{}; template <class _Tp> inline constexpr _Tp phi_v = __illformed<_Tp>{}; -template <floating_point _Tp> inline constexpr _Tp e_v<_Tp> = 2.718281828459045235360287471352662L; -template <floating_point _Tp> inline constexpr _Tp log2e_v<_Tp> = 1.442695040888963407359924681001892L; -template <floating_point _Tp> inline constexpr _Tp log10e_v<_Tp> = 0.434294481903251827651128918916605L; -template <floating_point _Tp> inline constexpr _Tp pi_v<_Tp> = 3.141592653589793238462643383279502L; -template <floating_point _Tp> inline constexpr _Tp inv_pi_v<_Tp> = 0.318309886183790671537767526745028L; -template <floating_point _Tp> inline constexpr _Tp inv_sqrtpi_v<_Tp> = 0.564189583547756286948079451560772L; -template <floating_point _Tp> inline constexpr _Tp ln2_v<_Tp> = 0.693147180559945309417232121458176L; -template <floating_point _Tp> inline constexpr _Tp ln10_v<_Tp> = 2.302585092994045684017991454684364L; -template <floating_point _Tp> inline constexpr _Tp sqrt2_v<_Tp> = 1.414213562373095048801688724209698L; -template <floating_point _Tp> inline constexpr _Tp sqrt3_v<_Tp> = 1.732050807568877293527446341505872L; -template <floating_point _Tp> inline constexpr _Tp inv_sqrt3_v<_Tp> = 0.577350269189625764509148780501957L; -template <floating_point _Tp> inline constexpr _Tp egamma_v<_Tp> = 0.577215664901532860606512090082402L; -template <floating_point _Tp> inline constexpr _Tp phi_v<_Tp> = 1.618033988749894848204586834365638L; +template <floating_point _Tp> inline constexpr _Tp e_v<_Tp> = 2.718281828459045235360287471352662; +template <floating_point _Tp> inline constexpr _Tp log2e_v<_Tp> = 1.442695040888963407359924681001892; +template <floating_point _Tp> inline constexpr _Tp log10e_v<_Tp> = 0.434294481903251827651128918916605; +template <floating_point _Tp> inline constexpr _Tp pi_v<_Tp> = 3.141592653589793238462643383279502; +template <floating_point _Tp> inline constexpr _Tp inv_pi_v<_Tp> = 0.318309886183790671537767526745028; +template <floating_point _Tp> inline constexpr _Tp inv_sqrtpi_v<_Tp> = 0.564189583547756286948079451560772; +template <floating_point _Tp> inline constexpr _Tp ln2_v<_Tp> = 0.693147180559945309417232121458176; +template <floating_point _Tp> inline constexpr _Tp ln10_v<_Tp> = 2.302585092994045684017991454684364; +template <floating_point _Tp> inline constexpr _Tp sqrt2_v<_Tp> = 1.414213562373095048801688724209698; +template <floating_point _Tp> inline constexpr _Tp sqrt3_v<_Tp> = 1.732050807568877293527446341505872; +template <floating_point _Tp> inline constexpr _Tp inv_sqrt3_v<_Tp> = 0.577350269189625764509148780501957; +template <floating_point _Tp> inline constexpr _Tp egamma_v<_Tp> = 0.577215664901532860606512090082402; +template <floating_point _Tp> inline constexpr _Tp phi_v<_Tp> = 1.618033988749894848204586834365638; inline constexpr double e = e_v<double>; inline constexpr double log2e = log2e_v<double>; diff --git a/contrib/libs/cxxsupp/libcxx/include/type_traits b/contrib/libs/cxxsupp/libcxx/include/type_traits index 2d160e4e29..d731cca0ba 100644 --- a/contrib/libs/cxxsupp/libcxx/include/type_traits +++ b/contrib/libs/cxxsupp/libcxx/include/type_traits @@ -553,14 +553,6 @@ struct _LIBCPP_TEMPLATE_VIS __dependent_type : public _Tp {}; // is_same -// Workaround for MSVC. Sometimes compiler thinks that sizeof...(Type) is parameter pack rather than the number. -// So it doesn't allow sizeof...(Type) in expression that goes into the boolean template parameter of _MetaBase. -// This simple wrapper allows us to hide sizeof... from the compiler. -template<class... _Pack> -struct _Sizeof { - static constexpr size_t value = sizeof...(_Pack); -}; - template <class _Tp> using __test_for_primary_template = __enable_if_t< _IsSame<_Tp, typename _Tp::__primary_template>::value diff --git a/contrib/libs/cxxsupp/libcxx/include/valarray b/contrib/libs/cxxsupp/libcxx/include/valarray index 4f7a61065c..6f8a3b8419 100644 --- a/contrib/libs/cxxsupp/libcxx/include/valarray +++ b/contrib/libs/cxxsupp/libcxx/include/valarray @@ -2795,7 +2795,7 @@ public: }; template<class _ValExpr> -__val_expr<_ValExpr>::operator valarray<typename __val_expr<_ValExpr>::__result_type>() const +__val_expr<_ValExpr>::operator valarray<__val_expr::__result_type>() const { valarray<__result_type> __r; size_t __n = __expr_.size(); diff --git a/contrib/libs/cxxsupp/libcxx/include/variant b/contrib/libs/cxxsupp/libcxx/include/variant index e1a4120d1b..b74416b62d 100644 --- a/contrib/libs/cxxsupp/libcxx/include/variant +++ b/contrib/libs/cxxsupp/libcxx/include/variant @@ -1250,21 +1250,18 @@ struct __all_overloads : _Bases... { using _Bases::operator()...; }; -// Change metaprogramming to satisfy MSVC. It doesn't like expression -// __overload<_Types, _Idx>... when _Types comes from using parameter but -// _Idx comes from structure template parameter. So I made them both -// structure template parameters. -template <class _IdxSeq, class ..._Types> +template <class IdxSeq> struct __make_overloads_imp; -template <size_t ..._Idx, class ..._Types> -struct __make_overloads_imp<__tuple_indices<_Idx...>, _Types... > { +template <size_t ..._Idx> +struct __make_overloads_imp<__tuple_indices<_Idx...> > { + template <class ..._Types> using _Apply _LIBCPP_NODEBUG = __all_overloads<__overload<_Types, _Idx>...>; }; template <class ..._Types> using _MakeOverloads _LIBCPP_NODEBUG = typename __make_overloads_imp< - __make_indices_imp<_Sizeof<_Types...>::value, 0>, _Types...>::_Apply; + __make_indices_imp<sizeof...(_Types), 0> >::template _Apply<_Types...>; template <class _Tp, class... _Types> using __best_match_t = diff --git a/contrib/libs/cxxsupp/libcxx/src/include/refstring.h b/contrib/libs/cxxsupp/libcxx/src/include/refstring.h index 6a0ebda6a2..c32630c6c2 100644 --- a/contrib/libs/cxxsupp/libcxx/src/include/refstring.h +++ b/contrib/libs/cxxsupp/libcxx/src/include/refstring.h @@ -146,7 +146,7 @@ __libcpp_refstring::~__libcpp_refstring() { #ifdef _LIBCPP_USE_ATOMIC if (rep->count.fetch_sub(1) == 0) { #else - if (__sync_add_and_fetch(&rep->count, count_t(-1)) < 0) { + if (__libcpp_atomic_add(&rep->count, count_t(-1)) < 0) { #endif ::operator delete(rep); } |