mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 08:31:26 +00:00
22 lines
287 B
Kotlin
Vendored
22 lines
287 B
Kotlin
Vendored
// TARGET_BACKEND: JVM
|
|
// FILE: AT.java
|
|
|
|
public class AT<G> {
|
|
public String result = "fail";
|
|
public void foo(G ...y) {
|
|
result = "OK";
|
|
}
|
|
}
|
|
|
|
// FILE: main.kt
|
|
|
|
fun AT<*>.bar() {
|
|
foo()
|
|
}
|
|
|
|
fun box(): String {
|
|
val a = AT<String>()
|
|
a.bar()
|
|
return a.result
|
|
}
|