mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-03-10 15:51:01 +00:00
20 lines
463 B
Kotlin
Vendored
20 lines
463 B
Kotlin
Vendored
// IGNORE_BACKEND_FIR: JVM_IR
|
|
// TARGET_BACKEND: JVM
|
|
// WITH_RUNTIME
|
|
|
|
import kotlin.test.assertEquals
|
|
|
|
annotation class Name(val value: String)
|
|
|
|
annotation class Anno(
|
|
@get:Name("O") val o: String,
|
|
@get:Name("K") val k: String
|
|
)
|
|
|
|
fun box(): String {
|
|
val ms = Anno::class.java.declaredMethods
|
|
|
|
return (ms.single { it.name == "o" }.annotations.single() as Name).value +
|
|
(ms.single { it.name == "k" }.annotations.single() as Name).value
|
|
}
|