Boost logo

Boost :

From: Doug Gregor (dgregor_at_[hidden])
Date: 2006-02-17 09:32:29


On Feb 17, 2006, at 8:48 AM, Thorsten Ottosen wrote:
> I have just added serialization to Boost.Ptr container.
> I briefly discussed an issue with Robert, namely
> that the current implementation calls clear() before
> reading the new values.
>
> The alternative is to provide roll-back guarantee by default
> by creating a local container and swap() in the end.
> By default this would temporarily use more memory.
>
> IMO we should go for the strong guarantee.
> Any thoughts?

I think the basic guarantee is enough here. Truly paranoid users can
copy+swap themselves, but for most purposes you are better off not
having two copies of the container in memory. Most people need better
performance more than they need the strong guarantee.

        Doug


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