FIR: Report UNSAFE_CALL instead of SMARTCAST_IMPOSSIBLE when smartcast
to null. Currently the error message shows the expression is impossible to smartcast to the nullable type, which is nonsensical since it's already that type.
This commit is contained in:
committed by
teamcityserver
parent
0627dbcb78
commit
504449f03e
@@ -232,3 +232,11 @@ FILE: nullability.kt
|
||||
}
|
||||
|
||||
}
|
||||
public final fun test_14(q: R|Q|): R|kotlin/Unit| {
|
||||
when () {
|
||||
==(R|<local>/q|.R|/Q.data|, Null(null)) -> {
|
||||
R|<local>/q|.R|/Q.data|.<Inapplicable(UNSAFE_CALL): /MyData.s>#
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user