Le Ven 6 juin 2008 07:43, Zeljko Vrba a écrit :
> On Thu, Jun 05, 2008 at 01:38:04PM +0200, Joel Falcou wrote:
>
>>
>> Can't a boost::tuple<v1,v2..,vn> with a custom, recursive constructor
>> function do the trick ?
>>
> Seems like a good idea, if I get the "recursive constructor" part
> working :-)

Something like:

class value_tuple : public tuple<v1,v2,...,vn>
{
    typedef tuple<v1,v2,...,vn> parent;
    value_tuple(X* x) : parent(make_tuple(x,x,x,...,x)) {}
};

should work IIRC