diff options
author | halyavin <[email protected]> | 2022-07-21 11:17:19 +0300 |
---|---|---|
committer | halyavin <[email protected]> | 2022-07-21 11:17:19 +0300 |
commit | b78ae8ac7797d88986dfa1526ea11fcbdb4f5f6f (patch) | |
tree | f4368f9265036a664df40ae4943cabd4f272d414 /contrib/libs/cxxsupp/libcxx/include/iterator | |
parent | b651f08845dea01bbd05b6b7d56aba3992374706 (diff) |
Update libc++ to 34313583 (20 Feb 2022).
Notable changes:
* replace _LIBCPP_INLINE_VISIBILITY with _LIBCPP_HIDE_FROM_ABI in __filesystem/operations.h
* implement sortable and mergeable concepts
* replace __uncvref with __uncvref_t
* implement consistent stateful allocator behavior in std::basic_string::operator+
* remove some _LIBCPP_CXX03_LANG ifdef's
* move _LIBCPP_ASSERT related code to a separate file
* enable std::hash<Enum> in C++11 mode
* make algorithm includes more granular
* implement range functionality for std::istream_iterator
* add debug check in basic_string::insert
* replace "" with <> in includes in src/ files for consistency with include/
* add push/pop macros defines in src/ files for consistency with include/
* add availability annotations to optional operations
* remove conditional noexcept from view_interface --- this is allowed by the standard
* replace _LIBCPP_SAFE_STATIC with _LIBCPP_CONSTINIT
* guard most of std::ranges under _LIBCPP_HAS_NO_INCOMPLETE_RANGES
* remove priority pragma for AIX from locale.cpp because it is ignored anyway
Diffstat (limited to 'contrib/libs/cxxsupp/libcxx/include/iterator')
-rw-r--r-- | contrib/libs/cxxsupp/libcxx/include/iterator | 35 |
1 files changed, 25 insertions, 10 deletions
diff --git a/contrib/libs/cxxsupp/libcxx/include/iterator b/contrib/libs/cxxsupp/libcxx/include/iterator index 202667809dc..6e2eb4a78c2 100644 --- a/contrib/libs/cxxsupp/libcxx/include/iterator +++ b/contrib/libs/cxxsupp/libcxx/include/iterator @@ -138,24 +138,33 @@ template<class In, class Out> // [alg.req.ind.copy], concept indirectly_copyable template<class In, class Out> - concept indirectly_copyable = see below; // since C++20 + concept indirectly_copyable = see below; // since C++20 template<class In, class Out> - concept indirectly_copyable_storable = see below; // since C++20 + concept indirectly_copyable_storable = see below; // since C++20 // [alg.req.ind.swap], concept indirectly_swappable template<class I1, class I2 = I1> concept indirectly_swappable = see below; // since C++20 -// [alg.req.permutable], concept permutable // since C++20 -template<class I> - concept permutable = see below; - template<class I1, class I2, class R, class P1 = identity, class P2 = identity> concept indirectly_comparable = indirect_binary_predicate<R, projected<I1, P1>, projected<I2, P2>>; // since C++20 +// [alg.req.permutable], concept permutable +template<class I> + concept permutable = see below; // since C++20 + + // [alg.req.mergeable], concept mergeable +template<class I1, class I2, class Out, + class R = ranges::less, class P1 = identity, class P2 = identity> + concept mergeable = see below; // since C++20 + +// [alg.req.sortable], concept sortable +template<class I, class R = ranges::less, class P = identity> + concept sortable = see below; // since C++20 + template<input_or_output_iterator I, sentinel_for<I> S> requires (!same_as<I, S> && copyable<I>) class common_iterator; // since C++20 @@ -448,7 +457,8 @@ public: typedef traits traits_type; typedef basic_istream<charT, traits> istream_type; - constexpr istream_iterator(); + istream_iterator(); // constexpr since C++11 + constexpr istream_iterator(default_sentinel_t); // since C++20 istream_iterator(istream_type& s); istream_iterator(const istream_iterator& x); ~istream_iterator(); @@ -457,6 +467,7 @@ public: const T* operator->() const; istream_iterator& operator++(); istream_iterator operator++(int); + friend bool operator==(const istream_iterator& i, default_sentinel_t); // since C++20 }; template <class T, class charT, class traits, class Distance> @@ -464,7 +475,7 @@ bool operator==(const istream_iterator<T,charT,traits,Distance>& x, const istream_iterator<T,charT,traits,Distance>& y); template <class T, class charT, class traits, class Distance> bool operator!=(const istream_iterator<T,charT,traits,Distance>& x, - const istream_iterator<T,charT,traits,Distance>& y); + const istream_iterator<T,charT,traits,Distance>& y); // until C++20 template <class T, class charT = char, class traits = char_traits<charT> > class ostream_iterator @@ -510,7 +521,8 @@ public: typedef basic_streambuf<charT, traits> streambuf_type; typedef basic_istream<charT, traits> istream_type; - istreambuf_iterator() noexcept; + istreambuf_iterator() noexcept; // constexpr since C++11 + constexpr istreambuf_iterator(default_sentinel_t) noexcept; // since C++20 istreambuf_iterator(istream_type& s) noexcept; istreambuf_iterator(streambuf_type* s) noexcept; istreambuf_iterator(a-private-type) noexcept; @@ -521,6 +533,7 @@ public: a-private-type operator++(int); bool equal(const istreambuf_iterator& b) const; + friend bool operator==(const istreambuf_iterator& i, default_sentinel_t s); // since C++20 }; template <class charT, class traits> @@ -528,7 +541,7 @@ bool operator==(const istreambuf_iterator<charT,traits>& a, const istreambuf_iterator<charT,traits>& b); template <class charT, class traits> bool operator!=(const istreambuf_iterator<charT,traits>& a, - const istreambuf_iterator<charT,traits>& b); + const istreambuf_iterator<charT,traits>& b); // until C++20 template <class charT, class traits = char_traits<charT> > class ostreambuf_iterator @@ -619,6 +632,7 @@ template <class E> constexpr const E* data(initializer_list<E> il) noexcept; #include <__iterator/iter_swap.h> #include <__iterator/iterator.h> #include <__iterator/iterator_traits.h> +#include <__iterator/mergeable.h> #include <__iterator/move_iterator.h> #include <__iterator/next.h> #include <__iterator/ostream_iterator.h> @@ -630,6 +644,7 @@ template <class E> constexpr const E* data(initializer_list<E> il) noexcept; #include <__iterator/reverse_access.h> #include <__iterator/reverse_iterator.h> #include <__iterator/size.h> +#include <__iterator/sortable.h> #include <__iterator/unreachable_sentinel.h> #include <__iterator/wrap_iter.h> #include <__memory/addressof.h> |