|
----- Original Message ----- From: Shmuel Zeigerman Date: 8/14/2009 4:12 AM
Recently I was manipulating wide character strings in a Lua library. Windows API assumes these strings to end with L'\0' which is represented as 2 successive zero bytes. The problem is, lua_tolstring guarantees only 1 zero byte at the end (according to the manual):You might try LuaPlus (http://luaplus.org/) which has real wide character string support. Be sure to grab the Subversion build from svn://svn.luaplus.org/LuaPlus/work51. If you would like to merge it into your Lua, look for #ifdef'ed blocks of LUA_WIDESTRING and LUA_WIDESTRING_FILE.Please correct me if I'm wrong, or if better options exist.
Josh