Boost logo

Boost :

From: Braddock Gaskill (braddock_at_[hidden])
Date: 2007-03-14 16:05:27


On Wed, 14 Mar 2007 15:50:34 -0400, Howard Hinnant wrote:
> You could call this on a promise: result(f) and a promise_functor<R,
> F> would be returned as the result (I'm not at all very attached to
> the name promise_functor). Executing that functor would be roughly
> equivalent to setting the promise:

I believe this is similar to the 'class task' wrapper that Peter Dimov proposed
in N2096 at http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2006/n2096.html

I think easy to use wrappers are a vital part of implementing future. I'm not
sure I see a great advantage to putting the wrapper functionality directly
within the promise class constructor though.


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