
13 Apr
2008
13 Apr
'08
12:54 p.m.
I have some more questions related to the callback support. 1. If thread A is blocked waiting for a future and thread B puts a value into the promise, is A unblocked right away, or do the callbacks complete first? In other words, is A guaranteed to observe the side effects of the callbacks? 2. What is the motivation for allowing more than one callback? This turns the promise into a signal. Usually we want to keep components separate and composable. Can't we just allow set_ready_handler and F* get_ready_handler<F> (a-la function<>::target)? The client can then install a signal.