Files
kotlin/compiler/testData/codegen/box/closures/enclosingLocalVariable.kt
Alexander Udalov 41a416da60 Move blackBoxFile() testData to box/ directory
Delete all test methods (and empty test classes), since they'll be
auto-generated
2013-01-28 18:20:17 +04:00

9 lines
196 B
Kotlin

fun box() : String {
val cl = 39
return if (sum(200, { val m = { val r = { cl }; r() }; m() }) == 239) "OK" else "FAIL"
}
fun sum(arg:Int, f : () -> Int) : Int {
return arg + f()
}