12 #ifndef ESTD_INTEGERSEQUENCE_HPP_ 13 #define ESTD_INTEGERSEQUENCE_HPP_ 15 #include <type_traits> 29 template<
typename T, T... Integers>
41 constexpr
static std::size_t
size() noexcept
43 return sizeof...(Integers);
55 template<std::size_t... Indexes>
68 template<
typename T, T... Integers>
84 template<
typename Sequence>
96 template<
typename T, T... Integers>
111 template<
bool Extend,
typename Sequence>
127 template<
typename T, T... Integers>
144 template<
typename T, std::
size_t N>
147 typename DoubledIntegerSequence<typename MakeIntegerSequenceImplementation<T, N / 2>::type>::type>
176 template<
typename T, T N>
177 struct MakeIntegerSequenceImplementationWrapper :
180 static_assert(N >= 0,
"Number of elements in the sequence must be non-negative!");
198 template<
typename T, T N>
199 using MakeIntegerSequence =
typename internal::MakeIntegerSequenceImplementationWrapper<T, N>::type::base;
211 template<std::
size_t N>
224 template<
typename... T>
229 #endif // ESTD_INTEGERSEQUENCE_HPP_ Collection of useful templates.
Definition: DmaChannel.hpp:121
T value_type
integer type used for the elements of the sequence
Definition: IntegerSequence.hpp:35
MakeIntegerSequence< std::size_t, N > MakeIndexSequence
Generator of IndexSequence types.
Definition: IntegerSequence.hpp:212
DoubledIntegerSequence< MakeIntegerSequenceImplementation< T, N/2 >::type >::type type
same as Sequence
Definition: IntegerSequence.hpp:115
TypedSequence optionally extended by one element.
Definition: IntegerSequence.hpp:112
Compile-time sequence of integers.
Definition: IntegerSequence.hpp:30
TypedSequence with doubled number of elements.
Definition: IntegerSequence.hpp:85
static constexpr std::size_t size() noexcept
Definition: IntegerSequence.hpp:41
IntegerSequence with two internal type aliases.
Definition: IntegerSequence.hpp:69
Implementation of generator of IntegerSequence types.
Definition: IntegerSequence.hpp:145
typename internal::MakeIntegerSequenceImplementationWrapper< T, N >::type::base MakeIntegerSequence
Generator of IntegerSequence types.
Definition: IntegerSequence.hpp:199
MakeIndexSequence< sizeof...(T)> IndexSequenceFor
Generator of IndexSequence types.
Definition: IntegerSequence.hpp:225