Issue with STL

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Amarnaath Sivaraman (amarnaath.sivaraman_at_honeywell.com)
Date: 08/11/04


Date: Wed, 11 Aug 2004 10:21:33 +0530

Hello,

I am stuck while linking my application which uses STL map class.

It says,
error LNK2019: unresolved external symbol "public: __thiscall
std::_Lockit::~_Lockit(void)" (??1_Lockit@std@@QAE@XZ) referenced in
function "public: __thiscall std::_Tree<unsigned short,struct
std::pair<unsigned short const ,cla
ss CInstanceInfo>,struct std::map<unsigned short,class CInstanceInfo,struct
std::less<unsigned short>,class std::allocator<class CInstanceInfo>
>::_Kfn,struct std::less<unsigned short>,class std::allocator<class
CInstanceInfo> >::~_Tree<unsigned sho
rt,struct std::pair<unsigned short const ,class CInstanceInfo>,struct
std::map<unsigned short,class CInstanceInfo,struct std::less<unsigned
short>,class std::allocator<class CInstanceInfo> >::_Kfn,struct
std::less<unsigned short>,class std::allocato
r<class CInstanceInfo> >(void)"
(??1?$_Tree@GU?$pair@$$CBGVCInstanceInfo@@@std@@U_Kfn@?$map@GVCInstanceInfo@
@U?$less@G@std@@V?$allocator@VCInstanceInfo@@@3@@2@U?$less@G@2@V?$allocator@
VCInstanceInfo@@@2@@std@@QAE@XZ)

My application is an MFC regular DLL dynamically linking to MFC.

There is no problem when I build the same source code as a simple Win32 DLL.

I am using eVC++ 4.0 SP 3.

Any suggestions and solutions are welcomed.

Thanks
Amar



Relevant Pages

  • Issue with STL
    ... I am stuck while linking my application which uses STL map class. ... rt,struct std::pair<unsigned short const,class CInstanceInfo>,struct ... My application is an MFC regular DLL dynamically linking to MFC. ...
    (microsoft.public.windowsce.embedded.vc)
  • [NEWBIE] C++ linking problems (Undefined symbols)
    ... I am learning C++ and I have a very newbie question about some ... linking issues. ... LessThan::operatorconst ... using namespace std; ...
    (alt.comp.lang.learn.c-cpp)
  • Re: VC6.0 call DLL that built by Visual 2005
    ... Are you linking in the test.lib? ... are built by Visual Studio 2005. ... Display(unsigned short,unsigned short const *,unsigned short const ...
    (microsoft.public.vc.mfc)
  • Re: c equivalence of const_cast?
    ... >> linking it to a third language (I'm not knowledgeable in either c or ... > In C doesn't exsist a const keyword, normally, some compiler support ...
    (comp.lang.c)