Files
kotlin-fork/compiler/testData/codegen/boxWithStdlib/reflection/mapping/syntheticFields.kt
T
2015-03-23 16:30:26 +03:00

15 lines
296 B
Kotlin
Vendored

import kotlin.reflect.jvm.kotlin
class A {
// There's a synthetic "$kotlinClass" field here
}
fun box(): String {
for (field in javaClass<A>().getDeclaredFields()) {
val prop = field.kotlin
if (prop != null) return "Fail, property found: $prop"
}
return "OK"
}