[Tarantool-patches] [PATCH luajit 2/2] Fix tonumber("-0") in dual-number mode.
Sergey Kaplun
skaplun at tarantool.org
Thu Jan 27 12:50:12 MSK 2022
Hi, again!
On 26.01.22, Sergey Kaplun wrote:
> From: Mike Pall <mike>
>
> Reported by Sergey Kaplun.
>
Added the corresponding line to the commit:
| (cherry picked from commit 103c29e634d822e0affd7d3ae16a7d8a80c038d3)
Branch is force pushed.
> For DUALNUM build `tonumber("-0x0")` or `tonumber("-0")` returns 0
> instead -0 due to the STRSCAN_OPT_TOINT option of `lj_strscan_scan()`
> and cast value to integer with losing information about its sign.
>
> This patch adds special checks for these corner cases during strscan.
>
> Sergey Kaplun:
> * added the description and the test for the problem
>
> Part of tarantool/tarantool#6548
> ---
<snipped>
>
--
Best regards,
Sergey Kaplun
More information about the Tarantool-patches
mailing list