On 06/06/2016 11:12 PM, Hans Dembinski wrote:
Could you tell me, what would be the advantage of non-intrusive serialization? Boost.serialization is an integral part of Boost, so I am
Faster compilation times because the serialization headers are not included, and faster linker times because the serialization library does not have to be read by the linker.
not sure why it would be useful to not require Boost.Serialization as a dependency? Boost.Serialization is used to implement the pickle protocol in the python interface for this library. So if you want to build the Python interface, you need Boost.serialization anyway.
I am not suggesting that you remove support for serialization. Instead I am suggesting that you keep serialization in a separate header, so your library users only pays the price when they need it.
The proposed library histogram is modeled after existing libs in Boost. If you look into include/boost/numeric/ublas/vector.hpp, you will see that the serialize function is also part of the public interface of class vector.
And others like Multiprecision keeps non-intrusive serialization functions in separate headers.