STL string Compilation Warning in VC++ 6.0
warning C4251: 'testExeName' : class 'std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >' needs to have dll-interface to be used by clients of class 'COutput'
Here is my codes:
////////////////////////////////////////////////////////////////////////
#ifndef COUTPUTdotH
#define COUTPUTdotH
#ifdef UTL_EXPORTS // defined in project setting
#define UTL_API __declspec(dllexport)
#else
#define UTL_API __declspec(dllimport)
#endif
class UTL_API COutput
{
public:
COutput(const string& testName, const string& testHeader);
~COutput();
...
protected:
...
private:
COutput();
static string testExeName; // name of executible
...
};
#endif
/////////////////////////////////////////////////////////////////////////

