Files
kotlin/compiler/testData/codegen/box/defaultArguments/function/extentionFunctionWithOneDefArg.kt
2019-11-19 11:00:09 +03:00

10 lines
211 B
Kotlin
Vendored

// IGNORE_BACKEND_FIR: JVM_IR
fun Int.foo(a: Int = 1, b: String): Int {
return a
}
fun box(): String {
if (1.foo(b = "b") != 1) return "fail"
if (1.foo(2, "b") != 2) return "fail"
return "OK"
}