diff options
author | mikhnenko <mikhnenko@yandex-team.com> | 2023-09-27 19:43:57 +0300 |
---|---|---|
committer | mikhnenko <mikhnenko@yandex-team.com> | 2023-09-27 20:05:15 +0300 |
commit | 48a18a64bb612e73011e1c49aef96b8dad6bffba (patch) | |
tree | 88f71d26ed4c98edd9b389e3c5f1f674f34942ac /contrib/libs/cxxsupp/libcxx/include/algorithm | |
parent | a78a2d51f5c2eda80188caf7a1045a5c8bdce1b3 (diff) | |
download | ydb-48a18a64bb612e73011e1c49aef96b8dad6bffba.tar.gz |
Upd libc++ to d0af4276d62418ba9e54fec99b293d2fd7c92213 (14 Mar 2022)
Diffstat (limited to 'contrib/libs/cxxsupp/libcxx/include/algorithm')
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/algorithm | 45 |
1 files changed, 44 insertions, 1 deletions
diff --git a/contrib/libs/cxxsupp/libcxx/include/algorithm b/contrib/libs/cxxsupp/libcxx/include/algorithm index cc37d71b24..4d922807a2 100644 --- a/contrib/libs/cxxsupp/libcxx/include/algorithm +++ b/contrib/libs/cxxsupp/libcxx/include/algorithm @@ -44,6 +44,45 @@ namespace ranges { template<forward_range R, class Proj = identity, indirect_strict_weak_order<projected<iterator_t<R>, Proj>> Comp = ranges::less> // since C++20 constexpr borrowed_iterator_t<R> min_element(R&& r, Comp comp = {}, Proj proj = {}); + + template <input_iterator I1, sentinel_for<_I1> S1, input_iterator I2, sentinel_for<_I2> S2, + class Pred = ranges::equal_to, class Proj1 = identity, class Proj2 = identity> + requires indirectly_comparable<I1, I2, Pred, Proj1, Proj2> + constexpr mismatch_result<_I1, _I2> + mismatch()(I1 first1, S1 last1, I2 first2, S2 last2, Pred pred = {}, Proj1 proj1 = {}, Proj2 proj2 = {}) // since C++20 + + template <input_range R1, input_range R2, + class Pred = ranges::equal_to, class Proj1 = identity, class Proj2 = identity> + requires indirectly_comparable<iterator_t<R1>, iterator_t<R2>, Pred, Proj1, Proj2> + constexpr mismatch_result<borrowed_iterator_t<R1>, borrowed_iterator_t<R2>> + mismatch(R1&& r1, R2&& r2, Pred pred = {}, Proj1 proj1 = {}, Proj2 proj2 = {}) // since C++20 + + template<input_iterator I, sentinel_for<I> S, class T, class Proj = identity> + requires indirect_binary_predicate<ranges::equal_to, projected<I, Proj>, const T*> + constexpr I find(I first, S last, const T& value, Proj proj = {}); // since C++20 + + template<input_range R, class T, class Proj = identity> + requires indirect_binary_predicate<ranges::equal_to, projected<iterator_t<R>, Proj>, const T*> + constexpr borrowed_iterator_t<R> + find(R&& r, const T& value, Proj proj = {}); // since C++20 + + template<input_iterator I, sentinel_for<I> S, class Proj = identity, + indirect_unary_predicate<projected<I, Proj>> Pred> + constexpr I find_if(I first, S last, Pred pred, Proj proj = {}); // since C++20 + + template<input_range R, class Proj = identity, + indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred> + constexpr borrowed_iterator_t<R> + find_if(R&& r, Pred pred, Proj proj = {}); // since C++20 + + template<input_iterator I, sentinel_for<I> S, class Proj = identity, + indirect_unary_predicate<projected<I, Proj>> Pred> + constexpr I find_if_not(I first, S last, Pred pred, Proj proj = {}); // since C++20 + + template<input_range R, class Proj = identity, + indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred> + constexpr borrowed_iterator_t<R> + find_if_not(R&& r, Pred pred, Proj proj = {}); // since C++20 } template <class InputIterator, class Predicate> @@ -692,7 +731,6 @@ template <class BidirectionalIterator, class Compare> #include <iterator> #include <memory> #include <type_traits> -#include <utility> #include <version> #include <__algorithm/adjacent_find.h> @@ -762,7 +800,12 @@ template <class BidirectionalIterator, class Compare> #include <__algorithm/pop_heap.h> #include <__algorithm/prev_permutation.h> #include <__algorithm/push_heap.h> +#include <__algorithm/ranges_find.h> +#include <__algorithm/ranges_find_if.h> +#include <__algorithm/ranges_find_if_not.h> +#include <__algorithm/ranges_max_element.h> #include <__algorithm/ranges_min_element.h> +#include <__algorithm/ranges_mismatch.h> #include <__algorithm/ranges_swap_ranges.h> #include <__algorithm/remove.h> #include <__algorithm/remove_copy.h> |