Files
kotlin/compiler/testData/codegen/box/functions/localFunctions/localFunctionInConstructor.kt
2018-06-28 12:26:41 +02:00

17 lines
246 B
Kotlin
Vendored

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