aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs/cxxsupp/libcxx/include/algorithm
diff options
context:
space:
mode:
authormikhnenko <mikhnenko@yandex-team.com>2023-10-25 20:25:30 +0300
committermikhnenko <mikhnenko@yandex-team.com>2023-10-25 20:54:14 +0300
commit4e197a976205a88dd1de940b253acb2175dc47b8 (patch)
treea9cfdcc08abde7dd5206d62d23ecadd22b69238b /contrib/libs/cxxsupp/libcxx/include/algorithm
parenta2c311b015e4e9366b8da29d07f77cd4b92c1cb0 (diff)
downloadydb-4e197a976205a88dd1de940b253acb2175dc47b8.tar.gz
Upd libc++ to 1 Jun 2022 10c4eec2785a68880c287d36c262d5be3a72a128
[libc++][format] Fixes string-literal formatting. [libc++] Removes __cpp_lib_monadic_optional. [libcxx] Temporarily skip Arm configs [libc++] Reduce the verbosity when running the libc++ Lit configuration [libc++] Adds __format_string as nasty macro. [libc++] Use __enable_if_t and is_integral in cstddef [libc++] Adds missing includes. [libc++] Minor emscripten changes from downstream [libc++] Granularize more of <type_traits> [libc++] Remove unused __functional includes [libc++] Add various missing _LIBCPP_HIDE_FROM_ABI [libc++] Use __libcpp_clz for a tighter __log2i function [libc++] Enable ranges_robust_against* and niebloid tests for implemented ranges algorithms [libc++] Implement ranges::is_sorted{, _until} [libc++] Time tests during CI [libc++] Implement ranges::{all, any, none}_of [libc++] Remove temporary workaround for existing CMake caches [libc++] Implement ranges::equal [libc++] Remove conditional include [libc++] Use Python subprocess instead of libc++'s own utilities [libc++] Implement ranges::fill{, _n} [libc++] Make sure that all headers can be included with modules enabled [libc++] Rename the generic-singlethreaded CI job to generic-no-threads for consistency [libc++] Implement ranges::reverse [libc++] Replace modulus operations in std::seed_seq::generate with conditional checks. [libc++] type_traits: use __is_core_convertible in __invokable_r. [libc++] Remove duplicate tests for callable concepts [libc++] Add ranges::max_element to the synopsis and ADL-proof the __min_element_impl calls [libc++] Add auto to the list of required extensions in C++03 [libc++] Assume that push_macro and pop_macro are available [libc++] Always enable the ranges concepts [libc++] Granularize parts of <type_traits> [libc++] Improve error messages for disabled modes [libc++] Override the value of LIBCXX_CXX_ABI in the cache [libc++] Granularize algorithm benchmarks [libc++] Enable move semantics for vector in C++03 [libc++][format][5/6] Improve format_to_n.
Diffstat (limited to 'contrib/libs/cxxsupp/libcxx/include/algorithm')
-rw-r--r--contrib/libs/cxxsupp/libcxx/include/algorithm89
1 files changed, 89 insertions, 0 deletions
diff --git a/contrib/libs/cxxsupp/libcxx/include/algorithm b/contrib/libs/cxxsupp/libcxx/include/algorithm
index c30e3a6ce9..4718451e2e 100644
--- a/contrib/libs/cxxsupp/libcxx/include/algorithm
+++ b/contrib/libs/cxxsupp/libcxx/include/algorithm
@@ -45,6 +45,15 @@ namespace ranges {
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<forward_iterator I, sentinel_for<I> S, class Proj = identity,
+ indirect_strict_weak_order<projected<I, Proj>> Comp = ranges::less>
+ constexpr I ranges::max_element(I first, S last, Comp comp = {}, Proj proj = {}); // since C++20
+
+ template<forward_range R, class Proj = identity,
+ indirect_strict_weak_order<projected<iterator_t<R>, Proj>> Comp = ranges::less>
+ constexpr borrowed_iterator_t<R> ranges::max_element(R&& r, Comp comp = {}, Proj proj = {}); // since C++20
+
+
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>
@@ -265,6 +274,77 @@ namespace ranges {
indirect_unary_predicate<projected<iterator_t<R>, Proj>> Pred>
constexpr bool ranges::is_partitioned(R&& r, Pred pred, Proj proj = {}); // since C++20
+
+ template<bidirectional_iterator I, sentinel_for<I> S>
+ requires permutable<I>
+ constexpr I ranges::reverse(I first, S last); // since C++20
+
+ template<bidirectional_range R>
+ requires permutable<iterator_t<R>>
+ constexpr borrowed_iterator_t<R> ranges::reverse(R&& r); // since C++20
+
+ template<class T, output_iterator<const T&> O, sentinel_for<O> S>
+ constexpr O ranges::fill(O first, S last, const T& value); // since C++20
+
+ template<class T, output_range<const T&> R>
+ constexpr borrowed_iterator_t<R> ranges::fill(R&& r, const T& value); // since C++20
+
+ template<class T, output_iterator<const T&> O>
+ constexpr O ranges::fill_n(O first, iter_difference_t<O> n, const T& value); // since C++20
+
+ 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 bool ranges::equal(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 bool ranges::equal(R1&& r1, R2&& r2, Pred pred = {},
+ Proj1 proj1 = {}, Proj2 proj2 = {}); // since C++20
+
+ template<input_iterator I, sentinel_for<I> S, class Proj = identity,
+ indirect_unary_predicate<projected<I, Proj>> Pred>
+ constexpr bool ranges::all_of(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 bool ranges::all_of(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 bool ranges::any_of(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 bool ranges::any_of(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 bool ranges::none_of(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 bool ranges::none_of(R&& r, Pred pred, Proj proj = {}); // since C++20
+
+ template<forward_iterator I, sentinel_for<I> S, class Proj = identity,
+ indirect_strict_weak_order<projected<I, Proj>> Comp = ranges::less>
+ constexpr bool ranges::is_sorted(I first, S last, Comp comp = {}, Proj proj = {}); // since C++20
+
+ template<forward_range R, class Proj = identity,
+ indirect_strict_weak_order<projected<iterator_t<R>, Proj>> Comp = ranges::less>
+ constexpr bool ranges::is_sorted(R&& r, Comp comp = {}, Proj proj = {}); // since C++20
+
+ template<forward_iterator I, sentinel_for<I> S, class Proj = identity,
+ indirect_strict_weak_order<projected<I, Proj>> Comp = ranges::less>
+ constexpr I ranges::is_sorted_until(I first, S last, Comp comp = {}, Proj proj = {}); // since C++20
+
+ template<forward_range R, class Proj = identity,
+ indirect_strict_weak_order<projected<iterator_t<R>, Proj>> Comp = ranges::less>
+ constexpr borrowed_iterator_t<R>
+ ranges::is_sorted_until(R&& r, Comp comp = {}, Proj proj = {}); // since C++20
}
constexpr bool // constexpr in C++20
@@ -981,18 +1061,25 @@ template <class BidirectionalIterator, class Compare>
#include <__algorithm/pop_heap.h>
#include <__algorithm/prev_permutation.h>
#include <__algorithm/push_heap.h>
+#include <__algorithm/ranges_all_of.h>
+#include <__algorithm/ranges_any_of.h>
#include <__algorithm/ranges_copy.h>
#include <__algorithm/ranges_copy_backward.h>
#include <__algorithm/ranges_copy_if.h>
#include <__algorithm/ranges_copy_n.h>
#include <__algorithm/ranges_count.h>
#include <__algorithm/ranges_count_if.h>
+#include <__algorithm/ranges_equal.h>
+#include <__algorithm/ranges_fill.h>
+#include <__algorithm/ranges_fill_n.h>
#include <__algorithm/ranges_find.h>
#include <__algorithm/ranges_find_if.h>
#include <__algorithm/ranges_find_if_not.h>
#include <__algorithm/ranges_for_each.h>
#include <__algorithm/ranges_for_each_n.h>
#include <__algorithm/ranges_is_partitioned.h>
+#include <__algorithm/ranges_is_sorted.h>
+#include <__algorithm/ranges_is_sorted_until.h>
#include <__algorithm/ranges_max.h>
#include <__algorithm/ranges_max_element.h>
#include <__algorithm/ranges_min.h>
@@ -1000,6 +1087,8 @@ template <class BidirectionalIterator, class Compare>
#include <__algorithm/ranges_minmax.h>
#include <__algorithm/ranges_minmax_element.h>
#include <__algorithm/ranges_mismatch.h>
+#include <__algorithm/ranges_none_of.h>
+#include <__algorithm/ranges_reverse.h>
#include <__algorithm/ranges_swap_ranges.h>
#include <__algorithm/ranges_transform.h>
#include <__algorithm/remove.h>