Files
kotlin-fork/compiler/testData/codegen/box/reflection/properties/javaPropertyInheritedInKotlin.kt
T
2020-10-15 08:47:46 +03:00

20 lines
263 B
Kotlin
Vendored

// 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)
}