FIR DFA: align return-implies checker closer to smartcasts
This commit is contained in:
+2
-2
@@ -31,9 +31,9 @@ fun testNullWhenNull(x: Int?) {
|
||||
|
||||
// NB. it is the same function as `nullWhenNull`, but annotations specifies other facet of the function behaviour
|
||||
fun notNullWhenNotNull (x: Int?): Int? {
|
||||
contract {
|
||||
<!WRONG_IMPLIES_CONDITION!>contract {
|
||||
returns(null) implies (x == null)
|
||||
}
|
||||
}<!>
|
||||
return x?.inc()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user