Files
kotlin-fork/compiler/testData/codegen/box/callableReference/local/recursiveClosure.kt
T
2013-12-24 20:41:20 +04:00

8 lines
150 B
Kotlin

fun foo(until: Int): String {
fun bar(x: Int): String =
if (x == until) "OK" else bar(x + 1)
return (::bar)(0)
}
fun box() = foo(10)