命名空间
变体
操作

std::ranges::slide_view<V>::iterator<Const>::operator[]

来自 cppreference.cn
< cpp‎ | ranges‎ | slide view‎ | iterator
 
 
范围库
范围适配器
 
 
constexpr auto operator[]( difference_type pos ) const
    requires ranges::random_access_range<Base>;
(自 C++23 起)

返回指定相对位置的元素。

current_n_ 为底层数据成员。等价于: return views::counted(current_ + pos, n_);

内容

[编辑] 参数

pos - 相对于当前位置的位置

[编辑] 返回值

位移为 pos 相对于当前位置的元素(类型为 value_type)。

[编辑] 示例

[编辑] 参见

(C++23)
访问元素
(公共成员函数)