On Friday, Aug 29, 2003, at 12:33 America/Denver, E. Gladyshev wrote:

--- Gregory Colvin <[EMAIL PROTECTED]> wrote:


[...]
It's still not obvious to me. But I suspect I have yet to understand
your example.

Perhaps Peter can help me here. In his sample solution before, in this thread,
he addresses this problem nicely by using static functions
that take references to allocator instances. In his solution,
shared_ptr doesn't create an internal Allocator copy.

The C++ standard requires that a copy of an allocator is equivalent to the original.

Instead he binds a static function pointer to an Allocator instance
and uses the pointer as Deleter.
My sample stateful allocator will work just fine in Peter's code.

Right. If your allocators can't be copied safely then you have a problem. Peter's approach is one way to fix the problem. But I don't see that shared_ptr has a problem.

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

Reply via email to