Boost logo

Boost Users :

Subject: Re: [Boost-users] [Serialization] Linker errors issue with using binary_wiarchive.hpp and binary_woarchive.hpp
From: Lord Metritutus Merkwurdichliebe (flying_saucers_at_[hidden])
Date: 2012-05-04 12:56:25


It will function without issues you say? That's very useful to know, thanks. Out of interest, why are there wide character versions then if they are unnecessary?
Regards.

> To: boost-users_at_[hidden]
> From: ramey_at_[hidden]
> Date: Fri, 4 May 2012 09:57:01 -0800
> Subject: Re: [Boost-users] [Serialization] Linker errors issue with using binary_wiarchive.hpp and binary_woarchive.hpp
>
> Lord Metritutus Merkwurdichliebe wrote:
> > Hello there, I've never used one of these Mailing List conversations
> > before so I apologise for any mistakes.
> >
> >
> > To the point: I'm having issues trying to get the wide character
> > version of Boost's serialization libaries working. When I attempt to
> > compile the result is a multitude of Linker errors. After Googling
> > failed to turn up anything I posted the question on Stack Overflow,
> > where a reply suggested there may be 'a bug in Boost.Serialization'.
> > Stack Overflow features nice syntax highlighting so it is easy to see
> > the code, I pieced it together from other normal character examples:
> > http://stackoverflow.com/questions/10439984/serialization-example-of-boost-archive-binary-woarchive-hpp-and-or-boost-archive
> >
> >
> > If there is a rule against posting external links, I apologise. Or
> > if people want me to paste the code directly in to an email for this
> > mailing list I will do so. The Stack Overflow question was
> > originally based on my thought that I had made a mistake in my code.
> > If this IS the case then I do apologise, and I would appreciate
> > knowing just where I've gone wrong.
> >
> >
> > Regards.
>
> Here is the problem:
> #include <boost/archive/binary_woarchive.hpp>
> #include <boost/archive/binary_wiarchive.hpp>
>
> These headers exist in the package. They were added in to satisfy
> my natural predudice for symetry and completeness. However,
> I've never been able to see why anyone would have a reason to use
> them. The build doesn't build the corresponding library components
> and they aren't tested. Think of them as either your appendix or maybe
> the Higgs Boson of the serialization library.
>
> Just use
>
> #include <boost/archive/binary_oarchive.hpp>
> #include <boost/archive/binary_iarchive.hpp>
>
> These should serve your purpose. Note that all the archive classes
> can save/restore wide char data types. This respects the principle
> that all archives handle any data type.
>
> Robert Ramey
>
>
>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
                                               



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