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

18 lines
342 B
Kotlin
Vendored

// IGNORE_BACKEND_FIR: JVM_IR
// TARGET_BACKEND: JVM
// WITH_REFLECT
@Retention(AnnotationRetention.RUNTIME)
annotation class Simple(val value: String)
interface A<T>
@Simple("OK")
public val <T> A<T>.p: String
get() = TODO()
fun box(): String {
val o = object : A<Int> {}
return (o::p.annotations.single() as Simple).value
}