|
Boost : |
Subject: Re: [boost] [review][mp11] Formal review of Mp11
From: Peter Dimov (lists_at_[hidden])
Date: 2017-07-17 21:03:13
Joaquin M López Muñoz wrote:
> Something more generic can be provided
>
> struct mp_mpl_sequence_folder
> {
> template<typename T,typename L>
> struct apply{using type=mp_push_front<T,L>;};
> };
>
> template<typename MplSequence>
> struct mp_mpl_sequence_impl:boost::mpl::reverse_fold<
> MplSequence,
> mp_list<>,
> mp_mpl_sequence_folder
> >{};
>
> template<typename MplSequence>
> using mp_mpl_sequence=typename mp_mpl_sequence_impl<MplSequence>::type;
How about we provide it in MPL instead?
namespace mpl {
template<class Seq, template<class...> class L = std::tuple> using to_tuple
= /*as above*/
}
to_tuple subject to bikeshedding (to_variadic? as_variadic_sequence?).
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk