JVM IR: Fix types in generated function reference constructor
For references to suspend functions this fixes an IllegalStateException in the type mapper, which is what the "suspendFunctionMethodReference" test is about.
This commit is contained in:
committed by
Alexander Udalov
parent
f3db113a82
commit
20a5c44e41
@@ -0,0 +1,11 @@
|
||||
// IGNORE_BACKEND: JVM
|
||||
// IGNORE_BACKEND_FIR: JVM_IR
|
||||
|
||||
fun f(a: suspend () -> Unit): String {
|
||||
val f = a::invoke
|
||||
return "OK"
|
||||
}
|
||||
|
||||
fun box(): String {
|
||||
return f {}
|
||||
}
|
||||
Reference in New Issue
Block a user