std::ranges::enumerate_view<V>::sentinel
来自 cppreference.cn
< cpp | ranges | enumerate view
template< bool Const > class /*sentinel*/; |
(since C++23) (exposition only*) |
|
当底层视图不是 common_range 时,enumerate_view::end 的返回类型。
类型 /*sentinel*/<true> 由 const 限定的重载返回。类型 /*sentinel*/<false> 由非 const 限定的重载返回。
目录 |
[编辑] 成员类型
成员类型 | 定义 |
Base (private) |
const V if Const is true, otherwise V.(exposition-only member type*) |
[编辑] 数据成员
成员对象 | 定义 |
end_ (private) |
类型为 ranges::sentinel_t<Base> 的哨位 (exposition-only member object*) |
[编辑] 成员函数
构造一个哨位 (public member function) | |
返回一个指示范围末尾的哨位 (public member function) |
[编辑] 非成员函数
(C++23) |
将哨位与从 enumerate_view::begin 返回的迭代器进行比较 (function) |
(C++23) |
计算哨位与从 enumerate_view::begin 返回的迭代器之间的距离 (function) |
[编辑] 示例
本节尚不完整 原因:没有示例 |
[编辑] 参考文献
- C++23 标准 (ISO/IEC 14882:2024)
- 26.7.23.4 类模板 enumerate_view::sentinel [range.enumerate.sentinel]