John Harrison wrote:
kathy wrote: I would like to use STL string in my C++ application. The target
machine could be windows 95/98/2000/XP. I know windows 95/98 using
ASCII and windows 2000/XP use UNICODE. In Microsoft MFC, there is
TCHAR. Is there tstring exsisted? If not, how to use use string for
UNICODE platform?
It's not hard to define tstring
typedef std::basic_string<TCHAR> tstring;
There you are, tstring defined.
Defined, but not necessarily implemented.
The std::basic_string template requires an explicit instantation of
std::char_traits with the same parameterized character type. So a
program would not be able to actually declare or use a tstring object,
unless (or until) std::char_traits<TCHAR> has been implemented,
Greg