Hi
I'm using RCF 1.3.1 for a while now in my app.
I'm having compiler problems while building in VS2015. I was building my app with all older Visual Studio versions (2008, 2010, 2012, 2013) without any problems, and now I cannot build it anymore, because of numerous compiler errors, without some clear point what is wrong.
Then I downloaded version RCF 2.1.0.0, combined with boost 1.55 or 1.59, I have only one error: Error C2039 'serialize': is not a member of boost::shared_ptr<Repository::CMyClass>'
Note that this error was never here in onlder VS versions, and everything was working well.
But, if I use latest boost (1.6), then I get this error: Error C2665 'SF::sfNewImpl': none of the 2 overloads could convert all the argument types RepositoryClientPlugin_RSNetwork xxxx\RCF-2\include\SF\SfNew.hpp
First error suggests that I do not have serialize implemented in my class, but I do not know what second error actually means.
Any hints?
Thank you
Visual Studio 2015
Re: Visual Studio 2015
Hi,
We have a new RCF release which is just about ready to go out the door. It has been tested against both VS 2015 and Boost 1.60.0 , so most likely that will resolve your issues. It should be on the website within the next few days.
We have a new RCF release which is just about ready to go out the door. It has been tested against both VS 2015 and Boost 1.60.0 , so most likely that will resolve your issues. It should be on the website within the next few days.
Re: Visual Studio 2015
Thank you for your answer!
Re: Visual Studio 2015
I tried to build with latest version, ending with the same result. RCF complained that there is no serialize function defined for my objects, but that was not true, at least for older compilers.
Then I went into the code, and realized that he is complaining because I actually use shared pointers from boost, so I wrote another 3 functions,just as wrappers for first 3:
And it built without errors.
I understand the problem, but I do not know why it worked before.
Code: Select all
void serialize(SF::Archive &ar, CRepositoryFile &file);
void serialize(SF::Archive &ar, CNetRepositoryItem &item);
void serialize(SF::Archive &ar, CNetCatalogueItem &item);
Code: Select all
void serialize(SF::Archive &ar, boost::shared_ptr<CRepositoryFile> &file);
void serialize(SF::Archive &ar, boost::shared_ptr<CNetRepositoryItem> &item);
void serialize(SF::Archive &ar, boost::shared_ptr<CNetCatalogueItem> &item);
I understand the problem, but I do not know why it worked before.
Re: Visual Studio 2015
OK, I see. If you are serializing shared_ptr<> objects, all you need to do is put this:
, at the top of your source code.
Code: Select all
#include <SF/shared_ptr.hpp>