Support functional expression in non-local returns

This commit is contained in:
Michael Bogdanov
2015-04-27 13:59:15 +03:00
parent 3a6e5ac78c
commit e0aa64b8d2
18 changed files with 210 additions and 81 deletions
@@ -0,0 +1,14 @@
fun f(a: Int) {
run(fun () {
<lineMarker>f</lineMarker>(a - 1)
})
}
fun ff(a: Int) {
run1 {
ff(a - 1)
}
}
inline fun <T> run1(noinline f: () -> T): T { }