| ||||||||||||||||||||||
| Range primitives | |||||||
| |||||||
| Range concepts | |||||||||||||||||||
| |||||||||||||||||||
| Range factories | |||||||||
| |||||||||
| Range adaptors | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Helper items | |||||||||||||||||
| |||||||||||||||||
constexprauto end(); | (since C++20) | |
Returns a sentinel or an iterator representing the end of thedrop_while_view.
Effectively returnsranges::end(base_), wherebase_ is the underlying view.
Contents |
(none)
A sentinel or an iterator representing the end of the view.
#include <cassert>#include <iostream>#include <ranges> int main(){staticconstexprauto data={0,-1,-2,3,1,4,1,5};auto view= std::ranges::drop_while_view{data,[](int x){return x<=0;}};assert(view.end()[-1]==5);}
| returns an iterator to the beginning (public member function)[edit] |