92cf521e11
Rely on the frontend weeding out cases that are not supported. In psi2ir, introduce all the parameters before processing default values. Change the DefaultArgumentStubGenerator to generate code that matches the behavior of the current backend.
15 lines
263 B
Kotlin
Vendored
15 lines
263 B
Kotlin
Vendored
fun f(
|
|
f1: () -> String = { f2() },
|
|
f2: () -> String = { "FAIL" }
|
|
): String = f1()
|
|
|
|
fun box(): String {
|
|
var result = "fail"
|
|
try {
|
|
f()
|
|
} catch (e : Exception) {
|
|
result = "OK"
|
|
}
|
|
return f(f2 = { "O" }) + f(f1 = { "K" })
|
|
}
|