JVM_IR simplify null check on trivially initialized vals only

This commit is contained in:
Dmitry Petrov
2021-10-01 11:17:16 +03:00
committed by TeamCityServer
parent ae1288948a
commit aea2db97c5
17 changed files with 73 additions and 10 deletions
@@ -0,0 +1,18 @@
abstract class Base() {
init {
foo()
}
abstract fun foo()
}
class Derived(val x: String) : Base() {
override fun foo() {
x?.length
}
}
fun box(): String {
Derived("")
return "OK"
}