Boost logo

Boost Users :

Subject: Re: [Boost-users] serialization of standard unordered containers
From: Bjorn Reese (breese_at_[hidden])
Date: 2013-07-29 06:36:17


On 07/29/2013 01:20 AM, D. R. Evans wrote:

> I don't know what "non-intrusively" means in this context.

In this context it means that you do not have to alter any Boost
classes (for further elaboration please see the Boost.Serialization
documentation on free functions.)

> I looked at the example, and the thought of trying to implement something
> similar for unordered sets sent me straight back to my user-level hole; I'll
> wait until someone who understands how this is supposed to work gets around to
> implementing it (it isn't, I assume, obvious even to those who have developed
> code for boost, otherwise it would, I expect, have been done already). I'll
> just live with old-fashioned sets in the meantime; they're fast enough for my
> current use-cases.

It is less intimidating than it looks. You can simply copy the
boost/serialization/set.hpp header and replace the type. In just five
minutes I created the attached example that uses std:tr1::unordered_set.




Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net