Boost logo

Boost Users :

From: Robert Ramey (ramey_at_[hidden])
Date: 2005-08-15 14:25:29

Thorsten Ottosen wrote:
> Robert R. wrote [privately]
>> Originally I had used scoped_ptr there. The problem is that
>> scoped_ptr isn't supported with all compilers - specifically
>> Borland. I don't know about others.
> If that is true then why do they pass the test???
> (
> ptr_release.html)

a) I don't see any tests of scoped_ptr there.
b) If I recall correctly, the borland version of scoped_ptr fails when the
type is incomplete - which makes it not useful for implementing the PIMPL
c) I was reluctant to include the whole smart_ptr machinery for just this
one case.

I am surprised that the delete in the destructor fails to delete the pimpl.
I've been unable to find the place where a constructor throws.

> If it is true scoped_ptr don't work with borland, then I suggest that
> you at least do
> template< class T >
> struct serialization_scoped_ptr
> {
> // extreamely simple stuff here
> };

I think the borland issue would still trip this up - scoped_ptr is very

Robert Ramey

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at