Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature request]: Backport Lua table.pack, table.unpack, table.move and if possible rawlen and coroutine.isyieldable #5472

Open
ccuser44 opened this issue Feb 28, 2023 · 1 comment

Comments

@ccuser44
Copy link

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.

@ccuser44
Copy link
Author

Bump this is still an issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant