mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-07 00:21:28 +00:00
21 lines
380 B
Kotlin
Vendored
21 lines
380 B
Kotlin
Vendored
// FILE: 1.kt
|
|
// LANGUAGE_VERSION: 1.2
|
|
// SKIP_INLINE_CHECK_IN: inlineFun$default
|
|
// IGNORE_BACKEND: JS, NATIVE
|
|
//WITH_RUNTIME
|
|
package test
|
|
|
|
object X {
|
|
@JvmStatic
|
|
inline fun inlineFun(capturedParam: String, lambda: () -> String = { capturedParam }): String {
|
|
return lambda()
|
|
}
|
|
}
|
|
|
|
// FILE: 2.kt
|
|
|
|
import test.*
|
|
|
|
fun box(): String {
|
|
return X.inlineFun("OK")
|
|
} |