Subject: Re: [std-proposals] Adding piecewise_construct - constructor to std::tuple
From: Marcin Jaczewski (marcinjaczewski86_at_[hidden])
Date: 2020-11-12 11:31:39
Why does it need to be multiple arbitrary template packs?
It could be to use one pack that accepts arbitrary types but
restricted to tuples?
require (is_tuple<T> && ...)
void f(T... t)
czw., 12 lis 2020 o 16:13 Jason McKesson via Std-Proposals
> Piecewise in-place construction of a pair is already incredibly
> cumbersome to write and read for just two values. Expanding that to N
> values is going to make for some pretty nightmarish code.
> Also, I'm not sure it's actually possible to extend it to N tuples.
> `pair`'s piecewise-construction constructor is hard-coded to have 2
> template packs in it. An N-tuple version would need to have N packs.
> You can write that for any particular N, but I don't know if it's
> possible for a generalized arbitrary N.
> So before going down the road of a proposal, you should write an
> implementation of it.
> Std-Proposals mailing list
STD-PROPOSALS list run by firstname.lastname@example.org
Standard Proposals Archives on Google Groups