std::layout_stride::mapping<Extents>::mapping-traits
static constexpr bool is_unique() noexcept; | (1) | (since C++23) |
constexpr bool is_exhaustive() const noexcept; | (2) | (since C++23) |
static constexpr bool is_strided() noexcept; | (3) | (since C++23) |
static constexpr bool is_always_unique() noexcept; | (4) | (since C++23) |
static constexpr bool is_always_exhaustive() noexcept; | (5) | (since C++23) |
static constexpr bool is_always_strided() noexcept; | (6) | (since C++23) |
Every instance of every specialization of mapping is unique and strided.
The mapping is exhaustive if one of the following conditions is true:
-
rank_is0, or - there exists a permutation
pof the integers in the range[0,rank_)such that:
-
stride(p[0])equals1and -
stride(p[i])equalsstride(p[i - 1]) * extents().extent(p[i - 1])
-
- for all
iin[1,rank_), wherep[i]is the ith element ofp.
(rank_ is an exposition-only static member constant defined in std::layout_stride::mapping.)
See LayoutMapping for the semantics of these predicate mapping traits.
Parameters
(none)
Return value
1,3-4,6)
true
2)
true if the mapping is exhaustive (see above)
5)
false
Example
See also
© cppreference.com
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.
https://en.cppreference.com/cpp/container/mdspan/layout_stride/mapping/mapping_traits