16 #ifndef OPENKALMAN_COLLECTIONS_TUPLE_LIKE_HPP 17 #define OPENKALMAN_COLLECTIONS_TUPLE_LIKE_HPP 25 #if not defined(__cpp_concepts) or __cpp_generic_lambdas < 201707L 28 template<
typename T,
typename =
void>
29 struct is_tuple_like : std::false_type {};
32 struct is_tuple_like<T,
std::void_t<decltype(std::tuple_size<T>::value)>> : std::true_type {};
44 #if defined(__cpp_concepts) and __cpp_generic_lambdas >= 201707L 45 concept
tuple_like = uniformly_gettable<T> and requires
47 typename std::tuple_size<std::decay_t<T>>;
48 std::tuple_size<std::decay_t<T>>
::value;
51 constexpr
bool tuple_like = uniformly_gettable<T> and detail::is_tuple_like<std::decay_t<T>>
::value;
57 #endif //OPENKALMAN_COLLECTIONS_TUPLE_LIKE_HPP Namespace for collections.
Definition: collections.hpp:27
Definition: tuple_reverse.hpp:103
constexpr bool value
T is numerical value or is reducible to a numerical value.
Definition: value.hpp:31
Definitions relating to the availability of c++ language features.
constexpr bool tuple_like
T is a non-empty tuple, pair, array, or other type that acts like a tuple.
Definition: tuple_like.hpp:51