Re: "or" shortcut does not work - but why?
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: "or" shortcut does not work - but why?
- From: Rici Lake <lua@...>
- Date: 2007年6月16日 10:42:58 -0500
On 16-Jun-07, at 10:26 AM, Luiz Henrique de Figueiredo wrote:
local Result = false; -- you could also use "nil" here
Result = Result or "anything else";
io.stdout:write("Result = '"..tostring(Result).."'");
yields "false" (or "nil", resp.) rather than "anything else"
Perhaps this is related to this bug, which apparently only surfaces in
Windows: http://www.lua.org/bugs.html#5.1.2-2
It would be useful to see the byte code which results from that
script, if luac has also been ported.