You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Newer versions of Lua have the functions table.pack, table.unpack and table.move.
table.pack and table.unpack fix an error with unpack(tbl) and {...} which makes them not be able to work with nil arguments. table.move makes copying elements from tables easier and more performant.
It would be great if these functions were backported. LuaJIT and many other Lua implementations already backport them and often times for compatibility Lua scripts add them manually if they don't exist.
Also if possible the functions coroutine.isyieldable and rawlen should be added. rawlen simply bypasses __len methamethod to get the raw lenght. coroutine.isyieldable tells if a couroutine can be yielded which is very helpfull to preventing errors.
The text was updated successfully, but these errors were encountered:
Newer versions of Lua have the functions
table.pack
,table.unpack
andtable.move
.table.pack
andtable.unpack
fix an error withunpack(tbl)
and{...}
which makes them not be able to work with nil arguments.table.move
makes copying elements from tables easier and more performant.It would be great if these functions were backported. LuaJIT and many other Lua implementations already backport them and often times for compatibility Lua scripts add them manually if they don't exist.
Also if possible the functions
coroutine.isyieldable
andrawlen
should be added.rawlen
simply bypasses__len
methamethod to get the raw lenght.coroutine.isyieldable
tells if a couroutine can be yielded which is very helpfull to preventing errors.The text was updated successfully, but these errors were encountered: