Files
kotlin-fork/compiler/testData/cfg-variables/bugs/referenceToPropertyInitializer.kt
T
2015-04-29 14:07:05 +02:00

22 lines
338 B
Kotlin

class TestFunctionLiteral {
val sum: (Int)->Int = { (x: Int) ->
sum(x - 1) + x
}
}
open class A(val a: A)
class TestObjectLiteral {
val obj: A = object: A(obj) {
init {
val x = obj
}
fun foo() {
val y = obj
}
}
}
class TestOther {
val x: Int = x + 1
}