5#ifndef INCLUDE_GUARD_ARENE_BASE_ARENE_BASE_TYPE_LIST_REMOVE_NTH_HPP_
6#define INCLUDE_GUARD_ARENE_BASE_ARENE_BASE_TYPE_LIST_REMOVE_NTH_HPP_
8#include "arene/base/stdlib_choice/cstddef.hpp"
9#include "arene/base/stdlib_choice/integer_sequence.hpp"
19namespace remove_nth_detail {
28template <
template <
class...>
class List,
class... Ts,
std::size_t... Js>
30 -> List<type_lists::at_t<List<Ts...>, Js>...>;
37template <
typename List,
typename Indices>
38using select_elements_from_t =
decltype(select_elements_from_impl(type_identity<List>{}, Indices{}));
52template <
typename List, std::
size_t Index>
59template <
template <
class...>
class List,
class... Ts,
std::size_t Index>
60class remove_nth_impl<List<Ts...>, Index> {
62 static_assert(Index <
sizeof...(Ts),
"The index must be less than the size of the list");
65 using type = select_elements_from_t<
79template <
class List, std::
size_t Index>
80using remove_nth = arene::base::type_lists::remove_nth_detail::remove_nth_impl<List, Index>;
88template <
class List, std::
size_t Index>
Definition apply_all.hpp:14
typename remove_nth< List, Index >::type remove_nth_t
Filter a type-list to remove the element at the specified index.
Definition remove_nth.hpp:89
arene::base::type_lists::remove_nth_detail::remove_nth_impl< List, Index > remove_nth
Filter a type-list to remove the element at the specified index.
Definition remove_nth.hpp:80
Definition accumulate.hpp:37
Definition accumulate.hpp:36
make_integer_sequence< size_t, Size > make_index_sequence
A helper alias template for make_integer_sequence<size_t, Size>
Definition integer_sequence.hpp:224
integer_sequence< size_t, Ints... > index_sequence
A helper alias template for integer_sequence<size_t, Ints>
Definition integer_sequence.hpp:218
::size_t size_t
A type suitable for holding the size of an object.
Definition cstddef.hpp:29