[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: About the Lua core
- From: Stefan Ginsberg <stefan.ginsberg@...>
- Date: Sat, 15 May 2021 08:29:31 +0200
Lua 5.4 lists a change in "Incompatibilities in the API" for 'lua_version' that "The Lua core should work correctly with libraries using their own static copies of the same core, so there is no need to check whether they are using the same address space.".
This is also documented in some commits to the codebase.
What is the intention behind this and what does it actually enable? Under what circumstance would one need to share a state (L) between different instances of the same Lua library? Would such separation of instances not mean a separation of the states to begin with?
Also are there other benefits to having Lua states without global memory in them (such as luaO_nilobject) which was what enabled this feature?