template <template <class...> With, typename Pipe = ml::ToList>
struct ZipWithVariadic {
template <typename ...Ts>
using f = /* .... */;
};
ZipWithVariadic<With, Pipe>
is a metafunction takes a parameter pack of ml::ListT
<Ts...>....,
ml::ListT
<Us...>...
and passes to Pipe
a parameter pack With<T0, U0, ...> ... With<Tn, Un, ...>
. Pipe
defaults to ml::ToList
.
f:: ml::ListT<Ts...>, ml::ListT<Us...>... -> With<T0, U0, ...> ... With<Tn, Un, ...> >-> Pipe
With must be a variadic template.
NOTE: for non-variadic template With
, see ml::ZipWith
.
using T0 = ml::f<
ml::ZipWithVariadic<std::pair>,
ml::ListT<int, char>,
ml::ListT<float, double>>;
static_assert(
std::is_same_v<
T,
ml::ListT<
std::pair<int, float>,
std::pair<char, double>>>);