Codegen test for smart cast to Nothing?
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
fun String?.foo() = this ?: "OK"
|
||||
|
||||
fun foo(i: Int?): String {
|
||||
if (i == null) return i.foo()
|
||||
return "$i"
|
||||
}
|
||||
|
||||
fun box() = foo(null)
|
||||
Reference in New Issue
Block a user