This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Hi Artem,
Use: #if WCHAR_BITSIZE == 16 blah blah blah #elif WCHAR_BITSIZE == 32 blah blah blah #else #error Unsupported/unknown wchar_t bitsize. #endif
When you are compiling your code with 32-bit wchar_t: g++ -DWCHAR_BITSIZE=32 foo.cpp
When you are compiling your code with 16-bit wchar_t: g++ -DWCHAR_BITSIZE=16 foo.cpp
-- Best Regards, Artem B. Bityuckiy, St.-Petersburg, Russia.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |