JVM_IR KT-44993 preserve inner expression type when fusing if-null
This commit is contained in:
committed by
TeamCityServer
parent
922419efb8
commit
decfaa3ba5
@@ -0,0 +1,15 @@
|
||||
// TARGET_BACKEND: JVM
|
||||
// WITH_RUNTIME
|
||||
// FILE: kt44993.kt
|
||||
fun box(): String =
|
||||
f(KotlinBox(JavaBox()))
|
||||
|
||||
fun f(r: KotlinBox<JavaBox>): String =
|
||||
r?.data?.element!!
|
||||
|
||||
class KotlinBox<T>(@JvmField val data: T?)
|
||||
|
||||
// FILE: JavaBox.java
|
||||
public class JavaBox {
|
||||
public final String element = "OK";
|
||||
}
|
||||
Reference in New Issue
Block a user