命名空间
变体
视图
操作

std::ranges::chunk_by_view<V,Pred>::iterator::operator++,--

From cppreference.cn
< cpp‎ | ranges‎ | chunk by view‎ | iterator
 
 
范围库
范围适配器
 
 
constexpr /*iterator*/& operator++();
(1) (since C++23)
constexpr /*iterator*/ operator++(int);
(2) (since C++23)
constexpr /*iterator*/& operator--() requires ranges::bidirectional_range<V>;
(3) (since C++23)
constexpr /*iterator*/ operator--(int) requires ranges::bidirectional_range<V>;
(4) (since C++23)

递增或递减迭代器

parent_current_next_iterator 的适当底层(仅用于演示)数据成员。

find-nextfind-prevranges::chunk_by_view 的适当(仅用于演示)成员函数。

1) 等价于
current_ = next_;
next_ = parent_->/*find-next*/(current_);
return *this;
若在此运算符调用前 current_ 等于 next_,则行为未定义。
2) 等价于: auto tmp = *this; ++*this; return tmp;
3) 等价于
next_ = current_;
current_ = parent_->/*find-prev*/(next_);
return *this;
4) 等价于: auto tmp = *this; --*this; return tmp;

[编辑] 参数

(无)

[编辑] 返回值

1,3) *this
2,4) *this 的副本,该副本在更改前创建。