Files
kotlin-fork/compiler/testData/codegen/box/functions/defaultargs7.kt
T
2018-06-09 19:15:38 +03:00

7 lines
173 B
Kotlin
Vendored

// IGNORE_BACKEND: JS_IR
class A(val expected: Int) {
fun foo(x: Int, y: Int = x + 20, z: Int = y * 2) = z == expected
}
fun box() = if (A(42).foo(1)) "OK" else "Fail"