Files
kotlin/compiler/testData/codegen/box/sam/castFromAny.kt
2019-11-19 11:00:09 +03:00

16 lines
222 B
Kotlin
Vendored

// IGNORE_BACKEND_FIR: JVM_IR
// TARGET_BACKEND: JVM
fun test(a: Any?) {
a as () -> Unit
Runnable(a).run()
}
fun box(): String {
var result = "Fail"
test {
result = "OK"
}
return result
}