Files
kotlin-fork/compiler/testData/codegen/box/localClasses/recaptureVarCapturedInLocalClass2.kt
T
2018-06-28 12:26:41 +02:00

16 lines
278 B
Kotlin
Vendored

// IGNORE_BACKEND: JVM_IR
fun box(): String {
var x = ""
class CapturesX {
override fun toString() = x
}
fun outerFun1(): CapturesX {
fun localFun() = CapturesX()
return localFun()
}
x = "OK"
return outerFun1().toString()
}