mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-09 00:21:47 +00:00
Includes changes to decompiled text Old syntax is used in builtins and project code for now
24 lines
411 B
Kotlin
24 lines
411 B
Kotlin
import kotlin.jvm.*
|
|
import kotlin.platform.*
|
|
|
|
class C {
|
|
default object {
|
|
private platformStatic native fun foo()
|
|
}
|
|
|
|
fun bar() {
|
|
foo()
|
|
}
|
|
}
|
|
|
|
fun box(): String {
|
|
try {
|
|
C().bar()
|
|
return "Link error expected"
|
|
}
|
|
catch (e: java.lang.UnsatisfiedLinkError) {
|
|
if (e.getMessage() != "C.foo()V") return "Fail 1: " + e.getMessage()
|
|
}
|
|
|
|
return "OK"
|
|
} |