Boost logo

Boost :

From: E. Gladyshev (egladysh_at_[hidden])
Date: 2003-08-26 11:41:03

--- Gregory Colvin <gregory.colvin_at_[hidden]> wrote:
> For shared_ptr the count is allocated by the following line in the
> shared_count
> constructor:
> new sp_counted_base_impl<P, D>(p, d);
> So it might be possible to make the allocation customizable by
> specializing
> sp_counted_base_impl.

I think it would be great.

However there is another problem.
You have to new your object.
shared_ptr<MyClass> s( new MyClass );

You cannot use allocator like you would expect:
shared_ptr< MyClass, std::allocator<MyClass> > s;


Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software

Boost list run by bdawes at, gregod at, cpdaniel at, john at