typedef std::list<int*> _SgSaveListType;
class
#if defined(WIN32)
_aa_DLLPORT
#endif
aa
{
CCriticalSection m_cs;
_SgSaveListType _sgprList;
int a;
}在调用aa类时,vc6提示
warning C4251: 'm_cs' : class 'CCriticalSection' needs to have dll-interface to be used by clients of class 'CMProcessDataThread'
C:\Program Files\Microsoft Visual Studio\VC98\MFC\INCLUDE\Afxmt.h(145) : see declaration of 'CCriticalSection'..\include\MProcessDataThread.h(17) : warning C4251: '_sgprList' : class 'std::list<class CSgSave *,class std::allocator<class CSgSave *> >' needs to have dll-interface to be used by clients of class 'aa'
请问如何修改?
class
#if defined(WIN32)
_aa_DLLPORT
#endif
aa
{
CCriticalSection m_cs;
_SgSaveListType _sgprList;
int a;
}在调用aa类时,vc6提示
warning C4251: 'm_cs' : class 'CCriticalSection' needs to have dll-interface to be used by clients of class 'CMProcessDataThread'
C:\Program Files\Microsoft Visual Studio\VC98\MFC\INCLUDE\Afxmt.h(145) : see declaration of 'CCriticalSection'..\include\MProcessDataThread.h(17) : warning C4251: '_sgprList' : class 'std::list<class CSgSave *,class std::allocator<class CSgSave *> >' needs to have dll-interface to be used by clients of class 'aa'
请问如何修改?
#if !defined(aa_DLL)
#define _aa_DLLPORT _declspec(dllimport)#else
#define _aa_DLLPORT _declspec(dllexport)#endif请问如何封装?在哪加?
#pragma warning(disable:4786);
消除调用STL出现的警告
不是看见了警告warning C4251
^^^^^^^^^^^^^^
#pragma warning(disable:4251)这样就看不见了。