Remove unnecessary Lua version compatibility

Only Lua 5.1 and LuaJIT need support. The builtin Lua code uses
plain old "unpack" anyway.
This commit is contained in:
Jude Melton-Houghton 2021-09-29 17:13:39 -04:00
parent 3368c608b2
commit d072bcc8c3
2 changed files with 1 additions and 4 deletions

View File

@ -1,8 +1,7 @@
std = "min"
read_globals = {
"default", "digiline", "ItemStack", "mcl_sounds", "mesecon", "minetest",
"pipeworks", "table.copy", "table.unpack", "unpack", "VoxelArea",
"vector",
"pipeworks", "table.copy", "unpack", "VoxelArea", "vector",
}
globals = {"minetest.is_protected"}
ignore = {"21/_.*"}

View File

@ -48,8 +48,6 @@ local function use(dep, keys)
for i, key in ipairs(keys) do
values[i] = returned[key]
end
-- The location of unpack() may depend on the Lua version:
local unpack = unpack or table.unpack
return unpack(values, 1, #keys)
else
return returned