lua-users home
lua-l archive

Re: luajit 2.0 jit bug with and/or expression?

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


2012年4月10日 Felix Wu <fsw534@gmail.com>:
> The following function ran fine with JIT off (-joff) for both LuaJIT
> 2.0 beta 8 and 9, but got erroneous results with JIT on. Is this a
> known bug?
Hi,
don't know if this is a known bug or not but I was surprised that such
a simple example can produce an error of this kind.
I've made some tests and the bug disappear if you use a more
conventional if/then/else construct:
 if n < 2 then
 return 1
 else
 return fib(n-1) + fib(n-2)
 end
Francesco

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