Posted 08 February 2013 - 03:57 AM
When you open the lua shell and try
a=42
f = loadstring("b=a")
f()
it will still return nil for b
a=42
f = loadstring("b=a")
f()
it will still return nil for b
a=42
f=loadstring("b=a")
setfenv(f, getfenv())
f()