a2b8493f47
^KT-44705 ^KT-49349 Fixed
10 lines
295 B
Kotlin
Vendored
10 lines
295 B
Kotlin
Vendored
public fun foo(x: String?, y: String?): Int {
|
|
while (true) {
|
|
x ?: <!INVALID_IF_AS_EXPRESSION_WARNING!>if<!> (y == null) break
|
|
// y is nullable if x != null
|
|
y<!UNSAFE_CALL!>.<!>length
|
|
}
|
|
// y is null because of the break
|
|
return y<!UNSAFE_CALL!>.<!>length
|
|
}
|