16 #ifndef OPENKALMAN_COLLECTIONS_UNIFORMLY_GETTABLE_HPP 17 #define OPENKALMAN_COLLECTIONS_UNIFORMLY_GETTABLE_HPP 25 #if not defined(__cpp_concepts) or __cpp_generic_lambdas < 201707L 29 struct uniformly_gettable_sized_impl : std::false_type {};
31 template<
typename T, std::size_t...i>
32 struct uniformly_gettable_sized_impl<T,
std::index_sequence<i...>> : std::bool_constant<(... and gettable<i, T>)> {};
35 template<
typename T,
typename =
void>
36 struct uniformly_gettable_sized : std::false_type {};
39 struct uniformly_gettable_sized<T, std::enable_if_t<size_of<T>::value != stdex::dynamic_extent>>
40 : uniformly_gettable_sized_impl<T> {};
50 #if defined(__cpp_concepts) and __cpp_generic_lambdas >= 201707L 53 (size_of_v<T> != stdex::dynamic_extent) and
54 []<std::size_t...i>(
std::index_sequence<i...>) {
return (... and gettable<i, T>); } (std::make_index_sequence<size_of_v<T>>{});
56 inline constexpr
bool uniformly_gettable =
Namespace for collections.
Definition: collections.hpp:27
constexpr bool uniformly_gettable
T is a fixed-size object that is gettable for all indices.
Definition: uniformly_gettable.hpp:56
Definition for collections::size_of.
constexpr bool value
T is a fixed or dynamic value that is reducible to a number.
Definition: value.hpp:45
Definition for collections::sized.
Definition: trait_backports.hpp:64
Definition for collections::gettable.