Boost logo

Boost Users :

Subject: Re: [Boost-users] Boost.Signals2 - tracking an object managed with tr1::shared_ptr
From: Frank Mori Hess (frank.hess_at_[hidden])
Date: 2009-09-11 12:34:42


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Friday 11 September 2009, Frank Mori Hess wrote:
> On Thursday 10 September 2009, Monteleone, Nathan wrote:
> > Is it possible to use slot::track with a tr1::shared_ptr instead of a
> > boost::shared_ptr?
>
> Sorry, not at present. I've thought about it a bit, especially with
> respect to std::shared_ptr, but haven't gotten around to doing anything
> about it. It wouldn't be too hard to support some fixed set of shared_ptr
> types using boost::variant. Maybe an additional slow path that uses heap
> allocation and some type traits could support unforeseen shared_ptr types.
>

Oh, and the other solution would be to add yet more template parameters to the
signal class (like the SlotFunction = boost::function) to permit the
shared_ptr/weak_ptr types to be specified per-signal.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)

iEYEARECAAYFAkqqfCIACgkQ5vihyNWuA4VimACfXwscUerSBqRH7ryW9HKB78Qn
o5IAoMZ7MlW5HOEoYvpWJZ0glrFVgAMK
=eH1R
-----END PGP SIGNATURE-----


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net