lua-users home
lua-l archive

Re: Porting Lua to Windows Mobile Professional 6.5.3

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Am 02.06.2011 17:40, schrieb Marc Balmer:
Am 02.06.2011 17:13, schrieb Luiz Henrique de Figueiredo:
Well to stay on-topic, this is quite embarrasing:
r = luaL_loadstring(L, "return 42\n");
returns 0 (no error), while
r = luaL_loadstring(L, "return 42");
returns LUA_ERRSYNTAX. Ich have no clue yet, why.
What is the error message left on the stack?
syntax error: [string "return 42"]:1: malformed number near '42ÿ'
(the leading "syntax error: " is from my program)
The syntax error also goes away when I add a space at the end of the string:
	r = luaL_loadstring(L, "return 42 ");

AltStyle によって変換されたページ (->オリジナル) /