Files
kotlin/compiler/testData/codegen/box/functions/localFunctions/localFunctionInConstructor.kt
Mikhael Bogdanov ad4eeb3f8a Properly capture local functions
Local functions in local classed wasn't captured properly
2013-03-27 15:57:27 +04:00

16 lines
216 B
Kotlin

class Test {
val property:Int
;{
fun local():Int {
return 10;
}
property = local();
}
}
fun box(): String {
return if (Test().property == 10) "OK" else "fail"
}