wchar_t is Now Treated as a Type
 
 
 

In VS2002, wchar_t was a typedef over unsigned short. If you wanted to treat wchar_t as an actual type, you had to turn on a compiler flag. You could also use __wchar_t instead.

With VS2005, the option to treat wchar_t as a type is now enabled by default, and we decided to work with that default. This makes it easier for people to start a new project without concern for how wchar_t is used.

If you try to link two modules that use different settings for the wchar_t type, you will get unresolved symbols on all functions that use wchar_t. For example, writing a 3ds Max 8 plug-in with VS2005 would require this flag to be turned off if any kind of CStr or WStr are used, otherwise your plug-in would try to pull-in wchar_t versions of the functions, whereas the 3ds Max SDK provides only unsigned short versions.