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

Add note for LuaJIT 5.2 style containers in the documentation #1448

Merged
merged 1 commit into from
Jul 18, 2023

Conversation

tatjam
Copy link
Contributor

@tatjam tatjam commented Jan 31, 2023

If you use the LUAJIT_ENABLE_LUA52COMPAT compilation flag with LuaJIT, C++ containers can be used just fine with ipairs or pairs as these properly check the metatable keys __ipairs and __pairs used by sol to implement this behavior.

I've not tested this behavior in-depth, but it should work fine with all containers.

If you use the LUAJIT_ENABLE_LUA52COMPAT compilation flag with LuaJIT, C++ container can be used just fine with `ipairs` or `pairs` as these properly check the metatable keys `__ipairs` and `__pairs` used by sol to implement this behaviour.
@ThePhD
Copy link
Owner

ThePhD commented Jul 18, 2023

This is great to know; thank you!

@ThePhD ThePhD self-assigned this Jul 18, 2023
@ThePhD ThePhD merged commit ba7aff0 into ThePhD:develop Jul 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants