Namespaces
Variants

nothrow-sentinel-for, nothrow-sized-sentinel-for

From cppreference.com
 
 
Algorithm library
Constrained algorithms and algorithms on ranges (C++20)
Constrained algorithms, e.g. ranges::copy, ranges::sort, ...
Non-modifying sequence operations    
Batch operations
(C++17)
Search operations
Modifying sequence operations
Copy operations
(C++11)
(C++11)
Swap operations
Transformation operations
Generation operations
Removing operations
Order-changing operations
(until C++17)(C++11)
(C++20)(C++20)
Sampling operations
(C++17)

Sorting and related operations
Partitioning operations
(C++11)    

Sorting operations
Binary search operations
(on partitioned ranges)
Set operations (on sorted ranges)
Merge operations (on sorted ranges)
Heap operations
Minimum/maximum operations
(C++11)
(C++17)
Lexicographical comparison operations
Permutation operations


 
 
template< class S, class I >
concept /*nothrow-sentinel-for*/ = std::sentinel_for<S, I>;
(1) (exposition only*)
template< class I >
concept /*nothrow-sized-sentinel-for*/ =
    /*nothrow-sentinel-for*/<S, I> &&
    std::sized_sentinel_for<S, I>;
(2) (since C++26)
(exposition only*)

These exposition-only concepts specify that no exceptions are thrown from operations required by the specialized <memory> algorithms between iterators and sentinels.

Semantic requirements

1) Types S and I model nothrow-sentinel-for only if no exceptions are thrown from copy construction, move construction, copy assignment, move assignment, or comparisons between valid values of type I and S.
2) Types S and I model nothrow-sized-sentinel-for only if no exceptions are thrown from the - operator for valid values of type I and S.

Notes

These concepts allow some sentinel_for and sized_sentinel_for operations to throw exceptions.

See also

specifies a type is a sentinel for an input_or_output_iterator type
(concept) [edit]
specifies that the - operator can be applied to an iterator and a sentinel to calculate their difference in constant time
(concept) [edit]
Morty Proxy This is a proxified and sanitized view of the page, visit original site.