Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2003-10-09 21:05:38


Douglas Gregor <gregod_at_[hidden]> writes:

> At the risk of being too cute, perhaps result_of<F> could be the name for
> metafunction_result_type_computer<F>. Then we have:
>
> result_of<F(T1, T2, ..., TN)>::type returns the type of f(t1, t2, ..., tN)
> given an object f of type F and objects t1, t2, ..., tN of types T1, T2, ...,
> TN respectively
>
> result_of<F>::apply<T1, T2, ..., TN>::type == result_of<F(T1,T2,...,TN)>::type

Makes me wonder if we want that or

   result_of<F>::apply<type_sequence>::type

e.g.

   result_of<F>::apply<mpl::vector<T,U,V> >::type

It may depend on which is a more likely use-case. OTOH I'm sure it's
simple to build an MPL facility that transforms one into the other;
we may have it already; seems too useful not to have.

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk