以下C++库已在VS2008中成功编译
http://sourceforge.net/projects/xmlrpcc4win/files/xmlrpcc4win/XmlRpcC4Win1.0.8.zip/download
当我在VS2010中打开它时,它会通过转换向导过程而没有任何错误。
现在,当我尝试在VS2010中编译它时,我得到一些奇怪的STL错误,例如:
1>TimXmlRpc.cpp(1018): error C2039: 'back_insert_iterator' : is not a member of 'std'
1>TimXmlRpc.cpp(1018): error C2065: 'back_insert_iterator' : undeclared identifier
1>TimXmlRpc.cpp(1018): error C2275: 'XmlRpcValue::BinaryData' : illegal use of this type as an expression
1>TimXmlRpc.cpp(1018): error C2065: 'ins' : undeclared identifier
1>TimXmlRpc.cpp(1018): error C2039: 'back_inserter' : is not a member of 'std'
1>TimXmlRpc.cpp(1018): error C3861: 'back_inserter': identifier not found
1>TimXmlRpc.cpp(1019): error C2065: 'ins' : undeclared identifier
1>TimXmlRpc.cpp(1031): error C2039: 'back_insert_iterator' : is not a member of 'std'
1>TimXmlRpc.cpp(1031): error C2065: 'back_insert_iterator' : undeclared identifier
1>TimXmlRpc.cpp(1031): error C2275: 'std::vector<_Ty>' : illegal use of this type as an expression
1> with
1> [
1> _Ty=char
1> ]
1>TimXmlRpc.cpp(1031): error C2065: 'ins' : undeclared identifier
1>TimXmlRpc.cpp(1031): error C2039: 'back_inserter' : is not a member of 'std'
1>TimXmlRpc.cpp(1031): error C3861: 'back_inserter': identifier not found
1>TimXmlRpc.cpp(1032): error C2065: 'ins' : undeclared identifier
我不确定其中一些内容该如何处理。例如,
back_insert_iterator
实际上是 std
的成员,但 VS 似乎认为它不是。我该如何解决这些错误?它们似乎没有太多意义,所以我不确定从哪里开始。也许是我的项目设置中有问题?
例如,这里是第1018行,导致了 std 错误:
std::back_insert_iterator<BinaryData> ins = std::back_inserter(*(u.asBinary));
如果有人能给我一些指导,我会非常感慕。我对C++还不够熟悉,所以很难理解这个问题。