lua-users home
lua-l archive

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

Hello Lua Hackers,

2011年1月26日 07:30:09 UTC+9 Sean Bolton <>:
Hmm, we're not there yet.  Your patch 5.1.4 yields the correct results
for these two cases:

Thank you to point out my mistake.  I forgot that 'nil' is equivalence 
to 'false' in the logical operation.
assert((((1 or false) and true) or false) == true)
assert((((1 or 2) and true) or false) == true)
assert(((nil and true) or false and true) == false)
assert((((nil and true) or false) and true) == false)

I fixed the patch to clear these cases.  Is it enough test case for this problem?

Ryota Hirose

Attachment: lcode.c.diff
Description: Binary data