vc6-migration

error C2440: 'initializing' : cannot convert from 'std::_Vector_iterator<_Ty,_Alloc>' to 'type *'

I am getting the following error while migrating VC6 code to VS2008. This code works fine in VC6 but gives a compilation error in VC9. I know it is because of a compiler breaking change. What is the problem and how do I fix it? error C2440: 'initializing' : cannot convert from 'std::_Vector_iterator<_Ty,_Alloc>' to 'STRUCT_MUX...

Cannot convert from 'const wchar_t *' to '_TCHAR *'

_TCHAR* strGroupName = NULL; const _TCHAR* strTempName = NULL; //Assign some value to strTempName strGroupName = _tcschr(strTempName, 92) //C2440 I get an error at the above line while compiling this code in VS2008. In VC6 it compiles fine. Error C2440: '=' : cannot convert from 'const wchar_t *' to '_TCHAR *' What seems to b...

Error C2593: Operator = is ambiguous

typedef map<wstring , IWString> REVERSETAG_CACHE ; REVERSETAG_CACHE::iterator revrsetagcacheiter; . . . wstring strCurTag; strCurTag = revrsetagcacheiter->second; //Error C2593 Error C2593: Operator = is ambiguous Why does the above assignment give this error? It works in VC6. Does not compile in VC9. ...

Linker error 2005, 2001 in Visual Studio 2008

I have a atl com project that was compiling fine in VC6 which gives the following linker errors when compiled in VS2008. error LNK2005: "void * __cdecl operator new(unsigned int)" (??2@YAPAXI@Z) already defined in libcmt.lib(new.obj) File: uafxcw.lib There are three more similar errors for delete, new[] and delete[]. I che...