Update tests/conformance/bitwise.lua

Use byteswap(-1) to validate bit32 semantics for signed integers
This commit is contained in:
Arseny Kapoulkine 2023-10-20 18:06:26 -07:00 committed by GitHub
parent 0cc649ce08
commit c255dbc3c3
Signed by: DevComp
GPG key ID: 4AEE18F83AFDEB23

View file

@ -137,7 +137,7 @@ assert(bit32.countrz(0x7fffffff) == 0)
-- testing byteswap
assert(bit32.byteswap(0x10203040) == 0x40302010)
assert(bit32.byteswap(0) == 0)
assert(bit32.byteswap(0xffffffff) == 0xffffffff)
assert(bit32.byteswap(-1) == 0xffffffff)
--[[
This test verifies a fix in luauF_replace() where if the 4th