aboutsummaryrefslogtreecommitdiff
path: root/tests/t.lua
blob: 09ee15d051cf98b3ffdb5cb4265c3ebbdbc67a6c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
a = require "lullaby"

b = coroutine.create(function()
  os.execute("sleep 2")
  print("co")
end)

c = a.thread.async(function(res, req)
  coroutine.resume(b)
end)

os.execute("sleep 0.5")
print("owo")

c:await()