Namespaces
Variants

std::layout_left::mapping<Extents>:: stride

From cppreference.net
constexpr index_type stride ( rank_type i ) const noexcept ;
(C++23 起)

返回在秩索引 i 处的映射步长。等价于 return extents ( ) . fwd-prod-of-extents ( i ) ;

此重载仅当 extents_type​ :: ​rank ( ) > 0 true 时参与重载决议。

i >= extents_type :: rank ( ) true 时,其行为是未定义的。

目录

参数

i - 范围 [ 0 , extents_type :: rank ( ) ) 内的秩索引

返回值

指定层级索引处的跨度。

示例

参见

获取指定维度的步长
( std::layout_stride::mapping<Extents> 的公开成员函数)
获取指定维度的步长
( std::mdspan<T,Extents,LayoutPolicy,AccessorPolicy> 的公开成员函数)