9 Iterators library [iterators]

9.7 Iterator adaptors [iterators.predef]

9.7.3 Move iterators and sentinels [iterators.move]

9.7.3.4 move_sentinel operations [move.sent.ops]

9.7.3.4.1 move_sentinel constructors [move.sent.op.const]

constexpr move_sentinel();

Effects: Constructs a move_sentinel, value-initializing last. If is_trivially_default_constructible<S>::value is true, then this constructor is a constexpr constructor.

explicit move_sentinel(S s);

Effects: Constructs a move_sentinel, initializing last with s.

move_sentinel(const move_sentinel<ConvertibleTo<S>>& s);

Effects: Constructs a move_sentinel, initializing last with s.last.

9.7.3.4.2 move_sentinel::operator= [move.sent.op=]

move_sentinel& operator=(const move_sentinel<ConvertibleTo<S>>& s);

Effects: Assigns s.last to last.

Returns: *this.

9.7.3.4.3 move_sentinel comparisons [move.sent.op.comp]

template <class I, Sentinel<I> S> constexpr bool operator==( const move_iterator<I>& i, const move_sentinel<S>& s); template <class I, Sentinel<I> S> constexpr bool operator==( const move_sentinel<S>& s, const move_iterator<I>& i);

Effects: Equivalent to: return i.current == s.last;

template <class I, Sentinel<I> S> constexpr bool operator!=( const move_iterator<I>& i, const move_sentinel<S>& s); template <class I, Sentinel<I> S> constexpr bool operator!=( const move_sentinel<S>& s, const move_iterator<I>& i);

Effects: Equivalent to: return !(i == s);

9.7.3.4.4 move_sentinel non-member functions [move.sent.nonmember]

template <class I, SizedSentinel<I> S> constexpr difference_type_t<I> operator-( const move_sentinel<S>& s, const move_iterator<I>& i);

Effects: Equivalent to: return s.last - i.current;

template <class I, SizedSentinel<I> S> constexpr difference_type_t<I> operator-( const move_iterator<I>& i, const move_sentinel<S>& s);

Effects: Equivalent to: return i.current - s.last;

template <Semiregular S> constexpr move_sentinel<S> make_move_sentinel(S s);

Returns: move_sentinel<S>(s).