Skip to content

Commit

Permalink
Added tests for non local rets
Browse files Browse the repository at this point in the history
  • Loading branch information
fjolnir committed Nov 7, 2012
1 parent b4cb82e commit a011e43
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
16 changes: 16 additions & 0 deletions Tests/lock_nonlocalret.tq
@@ -0,0 +1,16 @@
obj = @123
a = {
lock obj {
"took lock" print
{
^^123
}()
}
^321
}

async a()
wait
lock obj {
"released lock!" print
}
16 changes: 16 additions & 0 deletions Tests/nonlocalret.tq
@@ -0,0 +1,16 @@
a = {
b = {
[1,2,3,4] each: { i |
^^^123 if i > 2
i print
}
}
^b
}
b = a()
b print
{
foo = { ^^123 } \ Force the block to generate a landing pad
"crash please" print
b() print \ This should crash!
}() print

0 comments on commit a011e43

Please sign in to comment.