1679da45ab
FIR simply ignores anything after the first comma if the when expression doesn't have a subject. Hence, the checker has to rely on PSI structure instead.
8 lines
245 B
Kotlin
Vendored
8 lines
245 B
Kotlin
Vendored
public fun test(o: String?): Boolean {
|
|
return when {
|
|
// Data flow info should propagate from o == null to o.length
|
|
o == null<!COMMA_IN_WHEN_CONDITION_WITHOUT_ARGUMENT!>,<!> o.length == 0 -> false
|
|
else -> true
|
|
}
|
|
}
|