Re: gtkmm 3.0 and libsigc++



On Thu, 29 Jul 2010 01:29:25 +0200
Krzysztof Kosiński <tweenk pl gmail com> wrote:
> W dniu 29 lipca 2010 00:33 użytkownik Chris Vine
> <chris cvine freeserve co uk> napisał:
> > As far as I recall, signals do not know about sigc::trackable.
> >  However, slot generation in sigc::mem_fun() and helpers does have
> > to, for two reasons.
> 
> I was referring to the fact that signal_base is derived from
> trackable. I haven't examined what's necessary to make signals
> thread-safe yet.

Ah, is it, well there's another issue.

But it is only a problem if signals are to be made thread safe, and to
do that via templated mutex types the signal would have to be templated
anyway for the mutex.

But, as I say, it is the thread safety of remote trackable objects
which seems to me to be the more pressing point.  If all this is too
difficult, maybe it would be best to do it dynamically: that is,
implement plugins for trackable via virtual functions.  There could be
a new derived, sigc::safe_trackable class which remote objects could
inherit if wanted instead of the basic sigc::trackable class.  The rest
of libsigc++ could, for the moment, be left thread unsafe.  Adding
virtual functions to sigc::trackable would break ABI, but that would
happen anyway, whatever solution is adopted.

Chris




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]