Files
kotlin/compiler/testData/codegen/box/callableReference/varargAndDefaults/inlineDefault.kt
2019-12-24 15:54:45 +03:00

13 lines
315 B
Kotlin
Vendored

// !LANGUAGE: +NewInference +FunctionReferenceWithDefaultValueAsOtherType
// IGNORE_BACKEND_FIR: JVM_IR
// WITH_RUNTIME
// KJS_WITH_FULL_RUNTIME
inline fun foo(mkString: () -> String): String =
mkString()
fun bar (xs: CharArray = charArrayOf('O','K')) =
String(xs)
fun box(): String = foo(::bar)