Boost logo

Boost :

From: Larry Evans (cppljevans_at_[hidden])
Date: 2005-05-05 16:42:49


On 05/04/2005 05:08 PM, Larry Evans wrote:
[snip]
>
> However, in that file, the shared_storage class, contains:
>
> detail::shared_count count_;
>
> IOW, count_, unlike that in shared_ptr, contains no information
> about the type of pointee_; hence, I can't understand how policy_ptr's
> smart_ptr<...>, can emulate boost's shared_ptr with existing policies.
>
> What have I missed?
I missed that shared_count takes checked_deleter<U>() in:

         template <typename U>
         explicit shared_storage(U* p)
         : pointee_(p), count_(p, checked_deleter<U>(), p)

which does contain information about the pointee_. OTOH, it
also has an error: 3 args instead of 2. This, as well as
other errors, are corrected in the obvious zip file at:

http://boost-sandbox.sourceforge.net/vault/index.php?&direction=0&order=&directory=cppljevans

I'll be happy to upload these to the sandbox with David's permission;
however, I've not been able to contact him for several days :(


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk