On Thu, Sep 6, 2012 at 6:19 AM, Avi Bahra
This is question about use of asserts in boost serialisation.
As a program migrates from one release to another the api changes. This is expected. In my case I have client/server that uses boost serialisation.
I was expecting an throw due to the incompatibility not a an assert. The assert crashes my client, giving no chance for recovery, and informing the user that they are using previous out of date release/server.
This is an interesting policy point that's broader than the serialization library. The Boost.Coroutine library is being reviewed right now, and one reviewer has requested that the library use assert rather than throw for precondition violations. Maybe I'm conflating failure conditions that are conceptually distinct. If so, I apologize. If there is already text on the Boost website that clarifies when a Boost library should use assert vs. throw, please point me to it. If there is not -- perhaps there should be.