On Aug 2, 2004, at 12:48 AM, Oliver Kowalke wrote:
Am Montag, 2. August 2004 01:25 schrieb Doug Gregor:
- I call sig(); and the first slot connects a new slot to signal which has a higher priority (group -> higher values are executed at first)
According to the docs,
Yes.
it's unspecified whether or not this slot will be called.
Because I need only the topmost slot called, I could add a combiner which dereferences only one time and loop over signal - could result in side effects?!
struct call_topmost { typedef void result_type;
template<typename InputIterator> result_type operator()(InputIterator first, InputIterator last) const { if ( first != last) * first; } };
Yes, this will invoke only the first slot, which is of course free to remove itself or connect other slots. Doug