Boost logo

Boost :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2005-05-11 02:05:30


Jeff Garland wrote:

>>... more stuff...
>
> FWIW, I agree that this new change in serialization is wrong. Even though
> the docs warned that this was the design in the last release, it was easy
> to overlook since it was not enforced and even the example code did not
> live to
> the 'everything to be serialized must be const' rule. So basically this
> is going to break alot of existing code and I think for dubious
> benefit....

And additionally, the change complicates the interface very much. Not
everybody wants to read all serialization docs. With previous version, I
could say to a colleague that boost::text_oarchive is just like ostream.
Now, I'd have to explain why he should write

   ar << const_cast<const Whatever*>(whaterver);

Since neither of those usages is standard for streams.

I believe this is a common situation where an error checking is introduced
with good intentions, but that error checking just gets in the way and
complicates common usage.

- Volodya

   


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