Files
kotlin-fork/compiler/testData/codegen/box/properties/kt3551.kt
T
Mikhael Bogdanov b0b6728c7e KT-3118 NoSuchFieldError on private property without backing field &&
KT-3551 Wrong synthetic accessor implementation
2013-04-30 15:28:02 +04:00

24 lines
501 B
Kotlin

class Identifier() {
private var myNullable : Boolean = false
set(l : Boolean) {
//do nothing
}
fun getValue() : Boolean {
return myNullable
}
class object {
fun init(isNullable : Boolean) : Identifier {
val id = Identifier()
id.myNullable = isNullable
return id
}
}
}
fun box() : String {
val id = Identifier.init(true)
return if (id.getValue() == false) return "OK" else "fail"
}