cpp / latest / ranges / subrange / end.html /

std::ranges::subrange<I,S,K>::end

constexpr S end() const;
(since C++20)

Returns the sentinel indicating the end of the subrange.

range-begin-end.svg

Parameters

(none).

Return value

A sentinel copy-constructed from the stored sentinel.

Example

See also

(C++20)
obtains the iterator
(public member function)
(C++11)(C++14)
returns an iterator to the end of a container or array
(function template)
(C++20)
returns a sentinel indicating the end of a range
(customization point object)

© cppreference.com
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.
https://en.cppreference.com/w/cpp/ranges/subrange/end