Update closure.lua

This commit is contained in:
Arseny Kapoulkine 2021-11-19 09:59:54 -08:00 committed by GitHub
parent 8267765245
commit 2cef22ecf2
Signed by: DevComp
GPG key ID: 4AEE18F83AFDEB23

View file

@ -419,11 +419,5 @@ co = coroutine.create(function ()
return loadstring("return a")()
end)
a = {a = 15}
-- debug.setfenv(co, a)
-- assert(debug.getfenv(co) == a)
-- assert(select(2, coroutine.resume(co)) == a)
-- assert(select(2, coroutine.resume(co)) == a.a)
return 'OK'