Boost logo

Boost :

From: williamkempf_at_[hidden]
Date: 2001-05-08 09:21:17

--- In boost_at_y..., Douglas Gregor <gregod_at_c...> wrote:
> On Monday 07 May 2001 08:45 pm, you wrote:
> Here's what I've been considering:
> function is:
> - Assignment from any target function object
> - Clearing out the value (assignment from nil)
> - Execution of that target function object
> - A check to see if it is empty
> callback extends function:
> - Equality test
> signal is a distinct function-like concept:
> - support for multiple slots
> - notification to slot when it dies
> - method of combining multiple return values
> slot extends function:
> - knowledge of which signals it points to
> - notification to those signals when it dies
> - picks up notification of signal death
> Doug

I'm still not sold on equality testing. How do you test for equality
of two function objects that are not simple function pointer
wrappers? If they are only simple function pointer wrappers why is
there a need for the higher level abstraction at all? The use of
this concept seems to restrictive to be worth the effort.

That said, I really like the descriptions above. I'd say "signal
extends function" instead of saying it's "a distinct function-like
concept", however. A signal fullfills the "function concept"
contract even if it's going to need a radically different
implementation and has more functionality. I'd love to see
signals/slots eventually be added as part of function since they'll
likely share a lot of detail implementation.

Bill Kempf

Boost list run by bdawes at, gregod at, cpdaniel at, john at