EDN Admin
Well-known member
Hy <span class="x_x_mceItemHidden Community,
we try to migrate from vs2008 to vs2010, sadly it seems not that easy.<br/>
For a couple of projects we get this linking error (and some more, but all relatet to the STL):
<pre class="prettyprint prettyprinted" style=" <span class="pln main<span class="pun .<span class="pln obj <span class="pun :<span class="pln error LNK2001<span class="pun :<span class="pln unresolved external symbol <span class="str "public: static unsigned int const std::basic_string<unsigned short,struct std::char_traits<unsigned short>,class std::allocator<unsigned short> >::npos"<span class="pln <span class="pun (?<span class="pln npos@<span class="pun ?<span class="pln $basic_string@GU<span class="pun ?<span class="pln $char_traits@G@std@@V<span class="pun ?<span class="pln $allocator@G@2@@std@@2IB<span class="pun )[/code]
I was able to isolate the problem in a example project.
http://www.kisssoft.ch/public/mystring.zip Beispiel Projekt
We think it has something to do with the inherit of std::wstring. If we call the fuction rfind() with the parameter L"." or an wchar_t we get the linker error.
Compiling with vc90 works fine.
<span class="x_x_mceItemHidden Does anybody know what could be the problem?
Greetings
<br/>
View the full article
we try to migrate from vs2008 to vs2010, sadly it seems not that easy.<br/>
For a couple of projects we get this linking error (and some more, but all relatet to the STL):
<pre class="prettyprint prettyprinted" style=" <span class="pln main<span class="pun .<span class="pln obj <span class="pun :<span class="pln error LNK2001<span class="pun :<span class="pln unresolved external symbol <span class="str "public: static unsigned int const std::basic_string<unsigned short,struct std::char_traits<unsigned short>,class std::allocator<unsigned short> >::npos"<span class="pln <span class="pun (?<span class="pln npos@<span class="pun ?<span class="pln $basic_string@GU<span class="pun ?<span class="pln $char_traits@G@std@@V<span class="pun ?<span class="pln $allocator@G@2@@std@@2IB<span class="pun )[/code]
I was able to isolate the problem in a example project.
http://www.kisssoft.ch/public/mystring.zip Beispiel Projekt
We think it has something to do with the inherit of std::wstring. If we call the fuction rfind() with the parameter L"." or an wchar_t we get the linker error.
Compiling with vc90 works fine.
<span class="x_x_mceItemHidden Does anybody know what could be the problem?
Greetings
<br/>
View the full article