Classes ds::Signal and ds::Slot provide variant of observer pattern. See https://en.wikipedia.org/wiki/Signals_and_slots.
Design goals:
- slots are automatically disconnected when they go out of scope.
- exception in slot is not propagated to signal caller(), does not influence other slot invocations.
There are quite a few existing implementations. But all investigated ones require extra wrapper to fulfill the desired design goals. Implementation based on std::function and on boost::intrusive::list<auto_unlink> is simple enough and avoids extra layering and dependencies.
Implementation is not thread safe. Synchronization is required at higher level.