What is wstring – Discussion on wstring
Posted on March 23rd, 2008
What is wstring – Discussion on wstring
-- Sponsored Links --
-- Sponsored Links --
Can somebody tell how much std::wstring is supported across different compilers on different platforms? AFAIK std::string is supported by almost all C++ compilers and almost all platforms, is that also the case with wstring?

std::wstring is not necesarrily unicode. On windows it will likely be the unicode-subset also used by Java, but there are now guarantees.
You can not use std::wstring as a generic unicode string in Windows as the representation is encoded using the same principle as for utf-8. Thus, s[i] might not necesarrily return the i’th character of s. If you are aware of this (or only process characters in the basic plane), you are safe.
Common Questions About wstring
- wstring to CString conversion : cstring, wstring
- CString to wstring : wstring, cstring
- BSTR to wstring : wstring, bstr, convert
- char ptr to wstring – Urgent! : wstring, char
- How do I convert wstring variable to LCPWSTR? : convert, wstring …
- How do I initilize a “vector <wstring> vtws” variable? : vector
- wide char array to wstring : wstring, char, assign
- How do I get the Variant result to wstring variable? : messagebox …
- CopyFile : wchar_t, wstring
- Loading a File into an array or vector of wstring’s : vector, wstrings
- Convert from wstring to string? : wstring, string, convert
- What’s the safe and best way to assing the VARIANT to wstring?
- std::wstring wont work with overloaded std::operator<< : error …
- How to convert from wstring to string? : convert, wstring, string
- How to convert from wstring to string? : convert, wstring, string
- Writing wstring to text file : wstring, wchar_t
- wstring(char *Text) constructor ?? or how to handle ? : wstring
Books That talk about wstring
The string and wstring types are therefore much easier to use and offer greater safety (see the at member function), while still offering ease-of-use with …
The exact implementation of wchar_t is implementation defined, but it is often UTF-32. The class wstring, defined in <string>, is a sequence of …
There are three main template types: • string and wstring – string and wide-character string types; both bounded string/wstring and unbounded string/wstring …
Similarly, any time I refer to the relationship between string and char or char*, the same is true of the relationship between wstring and wchar_t or
Wstring Related Searches on Google
|
||||
|
basic_string big5 bjam bstr bstr to wstring c++ wstring c_str consulting engineers convert string wstring convert wstring |
convert wstring to char convert wstring to string converting wstring corba cout wstring cstring cstring to wstring cygwin gcc idl |
int to wstring iostream istringstream lpctstr mingw msdn orb ostringstream ostrstream shift jis |
sstream std std wstring stl wstring stlport string wstring stringstream strstream tce tcsectorreader |
ucs unicode utf 8 visual c++ visual studio widechartomultibyte wstring wstring char wstring to string |
Filed under Programming |
Comments are closed.