Drop LuaJIT 2.0.5 support
Primary CI target is luajit-openresty. Even 2.1.0-beta3 is ancient.
This commit is contained in:
2
.github/workflows/busted.yml
vendored
2
.github/workflows/busted.yml
vendored
@@ -7,7 +7,7 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
lua_version: ["luajit-2.1.0-beta3", "luajit-2.0.5", "luajit-openresty"]
|
lua_version: ["luajit-openresty", "luajit-2.1.0-beta3"]
|
||||||
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
|||||||
6
kiwi.lua
6
kiwi.lua
@@ -871,8 +871,7 @@ do
|
|||||||
function kiwi.error_mask(kinds, invert)
|
function kiwi.error_mask(kinds, invert)
|
||||||
local mask = 0
|
local mask = 0
|
||||||
for _, k in ipairs(kinds) do
|
for _, k in ipairs(kinds) do
|
||||||
-- must use tonumber only for LuaJIT 2.0 compatibility
|
mask = bor(mask, lshift(1, kiwi.ErrKind(k)))
|
||||||
mask = bor(mask, lshift(1, tonumber(kiwi.ErrKind(k)) --[[@as integer]]))
|
|
||||||
end
|
end
|
||||||
return invert and bit.bnot(mask) or mask
|
return invert and bit.bnot(mask) or mask
|
||||||
end
|
end
|
||||||
@@ -941,9 +940,8 @@ do
|
|||||||
end
|
end
|
||||||
local errdata = new_error(kind, message, solver, item)
|
local errdata = new_error(kind, message, solver, item)
|
||||||
local error_mask = solver and solver.error_mask_ or 0
|
local error_mask = solver and solver.error_mask_ or 0
|
||||||
-- tonumber only required for LuaJIT 2.0 compatibility
|
|
||||||
return item,
|
return item,
|
||||||
band(error_mask, lshift(1, tonumber(kind) --[[@as integer]])) == 0 and error(errdata)
|
band(error_mask, lshift(1, kind --[[@as integer]])) == 0 and error(errdata)
|
||||||
or errdata
|
or errdata
|
||||||
end
|
end
|
||||||
return item
|
return item
|
||||||
|
|||||||
Reference in New Issue
Block a user