luna-core 2.12.0

Pure-Rust Lua runtime (interpreter only, zero third-party dependencies). The JIT-equipped variant lives in the `luna-jit` crate.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
-- v2.12 CORPUS-III: _ENV can be shadowed; free names resolve
-- through the innermost _ENV. Capture needed builtins as locals
-- first — inside the shadow, print/rawget themselves would
-- resolve via the new (empty-ish) _ENV.
local g_print = print
local g_rawget = rawget
do
  local _ENV = { name = "chunk_env" }
  g_print(name)
  x = 10
  g_print(x, g_rawget(_ENV, "x"))
end
print(name, x)