Closed EmilyBourne closed 3 months ago
When working with type sequences to deduce new types it is useful to be able to check the number of arguments to the type seq. I would suggest calling this accessor type_seq_rank_v to match the rank property used elsewhere, eg: https://github.com/CExA-project/ddc/blob/362bb29f3dba481351340700d1fad225c5d6bf07/include/ddc/discrete_domain.hpp#L66-L69
type_seq_rank_v
rank
However it seems that this accessor already exists and does something else: https://github.com/CExA-project/ddc/blob/362bb29f3dba481351340700d1fad225c5d6bf07/include/ddc/detail/type_seq.hpp#L185-L187
type_seq_length_v could be implemented simply as:
type_seq_length_v
template <class TypeSeq> constexpr std::size_t type_seq_length_v = std::numeric_limits<std::size_t>::max(); template <class... Tags> constexpr std::size_t type_seq_length_v<ddc::detail::TypeSeq<Tags...>> = sizeof...(Tags);
Seems fairly reasonable
When working with type sequences to deduce new types it is useful to be able to check the number of arguments to the type seq. I would suggest calling this accessor
type_seq_rank_v
to match therank
property used elsewhere, eg: https://github.com/CExA-project/ddc/blob/362bb29f3dba481351340700d1fad225c5d6bf07/include/ddc/discrete_domain.hpp#L66-L69However it seems that this accessor already exists and does something else: https://github.com/CExA-project/ddc/blob/362bb29f3dba481351340700d1fad225c5d6bf07/include/ddc/detail/type_seq.hpp#L185-L187
type_seq_length_v
could be implemented simply as: