Files
kotlin/compiler/testData/codegen/box/reflection/properties/javaPropertyInheritedInKotlin.kt
2019-11-19 11:00:09 +03:00

21 lines
293 B
Kotlin
Vendored

// IGNORE_BACKEND_FIR: JVM_IR
// TARGET_BACKEND: JVM
// FILE: J.java
public class J {
public String result = null;
}
// FILE: K.kt
class K : J()
fun box(): String {
val k = K()
val p = K::result
if (p.get(k) != null) return "Fail"
p.set(k, "OK")
return p.get(k)
}