- mdspan[meta header]
- function[meta id-type]
- std[meta namespace]
- layout_stride::mapping[meta class]
- cpp23[meta cpp]
constexpr bool is_exhaustive() const noexcept;レイアウトマッピングのExhaustive特性を取得する。
rank_ == 0のとき、trueを返す。- そうでなければ、取りうる全ての多次元インデクス値に対応する要素位置を考えたとき、アクセスされうる要素位置に隙間が生じないならば
trueを返す。 - そうでなければ、
falseを返す。
投げない
#include <cassert>
#include <array>
#include <mdspan>
int main()
{
using Ext2x3 = std::extents<size_t, 2, 3>;
using Mapping = std::layout_stride::mapping<Ext2x3>;
Mapping map1{{}, std::array{3, 1}};
assert(map1.is_exhaustive());
Mapping map2{{}, std::array{4, 1}};
assert(not map2.is_exhaustive());
}- is_exhaustive()[color ff0000]
- std::layout_stride::mapping[link ../mapping.md]
- C++23
- Clang: ??
- GCC: ??
- ICC: ??
- Visual C++: ??