std::ranges::drop_while_view<V,Pred>::end
From cppreference.com
< cpp | ranges | drop while view
| constexpr auto end(); |
(C++20以降) | |
drop_while_viewの終端を表すセンチネルまたはイテレータを返します。
実質的に、base_(基になるビュー)に対してranges::end(base_)を返します。
目次 |
[編集] パラメータ
(なし)
[編集] 戻り値
ビューの終端を表すセンチネルまたはイテレータ。
[編集] 例
このコードを実行
#include <cassert> #include <iostream> #include <ranges> int main() { static constexpr auto 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); }
[編集] 関連項目
| 先頭へのイテレータを返す (public メンバ関数) |