On Tue, Jul 18, 2017 at 9:58 AM, Joaquin M López Muñoz via Boost < boost@lists.boost.org> wrote:
El 17/07/2017 a las 23:03, Peter Dimov via Boost escribió:
Joaquin M López Muñoz wrote:
Something more generic can be provided
[...]
template<typename MplSequence> using mp_mpl_sequence=typename mp_mpl_sequence_impl<MplSequen ce>::type;
How about we provide it in MPL instead?
namespace mpl {
template
class L = std::tuple> using to_tuple = /*as above*/ }
to_tuple subject to bikeshedding (to_variadic? as_variadic_sequence?).
Personally I think this doesn't belong to MPL. Actually I suggest providing a slightly more general utility that not only converts MPL Sequences, but Metafunction Classes as well and also in a recursive fashion, that is, Sequences of Sequences would be converted to variadic Lists of variadic Lists for example. Metal used to provide such a utility up until recently, when I decided to remove it, but maybe it can still serve as a source of inspiration [1]. Some usage examples are available as well [2]. [1]: https://github.com/brunocodutra/metal/blob/85d6d32f6e58e648c4573189f8bf2d763... [2]: https://github.com/brunocodutra/metal/blob/85d6d32f6e58e648c4573189f8bf2d763... Bruno