无法解析的外部符号错误:无法解决它
问题描述:
我在编译代码时遇到无法解析的外部符号错误。我正在使用第三方库。因此在编译代码时使用第三方库名称空间。无法解析的外部符号错误:无法解决它
std_uss.obj : error LNK2019: unresolved external symbol "
__declspec(dllimport) void __cdecl os_std::os_throw_length_error(void)
" ([email protected][email protected]@YAXXZ
) referenced in function "private: char * __thiscall os_std::basic_string<char,class os_std::char_traits_char,class os_std::allocator<char> >::allocate(unsigned int)
" ([email protected][email protected][email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]
)
我发现os_throw_length_error功能在第三部分库文件中的一个,但没有发现任何类似的功能::分配中的代码。我没有使用标准的std命名空间,因为我希望编译器使用第三方命名空间。
如果我使用using namespace std
这是标准的,那么我的编译是成功的,但然后像字符串一些定义被引用到Visual Studio字符串而不是第三方字符串函数。
_什么是第三方库? – 2012-02-22 11:36:55
第三方库是递归软件的ospace – novice 2012-02-22 11:56:25