lean2/tests/lua/th2.lua

11 lines
149 B
Lua
Raw Normal View History

S = State()
T = thread(S, [[
while true do
check_interrupted()
end
]])
sleep(100)
T:interrupt()
assert(not pcall(function() T:wait() end))