Files
kotlin-fork/compiler/testData/codegen/box/controlStructures/tryCatchInExpressions/kt17572_nested.kt
T
2021-09-08 19:56:38 +03:00

14 lines
347 B
Kotlin
Vendored

fun zap(s: String) = s
inline fun tryZap(string: String, fn: (String) -> String) =
fn(
try {
try {
zap(string)
}
catch (e: Exception) { "" }
} catch (e: Exception) { "" }
)
fun box(): String = tryZap("OK") { it }