mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 15:53:19 +00:00
16 lines
249 B
Kotlin
Vendored
16 lines
249 B
Kotlin
Vendored
// FILE: JClass.java
|
|
|
|
public class JClass {
|
|
public static int field;
|
|
}
|
|
|
|
// FILE: main.kt
|
|
fun box(): String {
|
|
return if (call(10, JClass::field) == 5) "OK" else "fail"
|
|
}
|
|
|
|
inline fun call(p: Int, s: () -> Int): Int {
|
|
return s()
|
|
}
|
|
|
|
// 0 NEW |