[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Possible bug in MS_ASMTRICK? (Lua 5.2)
- From: Henk Boom <henk@...>
- Date: Mon, 22 Apr 2013 18:25:40 -0400
On 22 April 2013 04:01, KHMan <keinhong@gmail.com> wrote:
> I have a feeling that this has already been addressed in LuaJIT...
LuaJIT defines the semantics in the same way:
http://bitop.luajit.org/semantics.html
"Non-integral numbers may be rounded or truncated in an
implementation-defined way. This means the result could differ between
different BitOp versions, different Lua VMs, on different platforms or
even between interpreted vs. compiled code (as in LuaJIT).
Avoid passing fractional numbers to bitwise functions. Use
math.floor() or math.ceil()to get defined behavior."
henk