
28 Apr
2005
28 Apr
'05
9:19 p.m.
Pavel Antokolsky aka Zigmar wrote:
And another pitfal with both auto_ptr and shared_ptr (at least on VC7.1 compiler) is if you don't provide expicit destructor, the generated destructor will try destroy the auto_ptr, which in its turn will try to destroy you pimpl via imcomplete pointer, therefor not calling destructor.
shared_ptr will call the destructor in this case.