-
#include "tensorstore/rank.h" -
template <DimensionIndex Rank>
using tensorstore::StaticOrDynamicRank =
std::conditional_t<(Rank <= dynamic_rank),
DimensionIndex,
std::integral_constant<DimensionIndex, Rank>>; Template alias that evaluates to the type used for representing a static or dynamic rank.
If
Rank == dynamic_rank, this isDimensionIndex. Otherwise, it isstd::integral_constant<DimensionIndex, Rank>.