已在VS2008中成功编译以下C++库
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++来说,我还是个新手,所以我很难弄明白这一点。
https://stackoverflow.com/questions/2959234
复制相似问题