Sign in to follow this  

Boost serialization with char*

Recommended Posts

Excuse me in advance if this is a dumb question. For a start I'm new to C++, and secondly I'm naturally dumb (and no I'm not blonde) Anyway, when ever I try and serialize a char* data type in boost, I get ".\boost_1_32_0\boost\serialization\access.hpp(106): error C2228: left of '.serialize' must have class/struct/union type" I tried includiong the string serializer for the std::string by slapping #include <boost/serialization/string.hpp> at the top. That doesn't do anything and I wasn't expecting it as this is char* and not std::string. I know I could use std::string in place, but I don't want to do that if possible.

Share this post

Link to post
Share on other sites
Also, when using STL containers and serialization, I get a errors like ...

.\boost\serialization\collections_save_imp.hpp(36): warning C4267: 'initializing' : conversion from 'size_t' to 'unsigned int', possible loss of data

and more importantly

.\boost\serialization\split_free.hpp(55): error C2780: 'void boost::archive::load(Archive &,T &)' : expects 2 arguments - 3 provided

Can anyone tell me why this is. I did something or other and it managed to get rid of this error in one part of my code, but I dunno how I got rid if it now.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this