[FIR] Consider stability of receiver for DFA variables
^KT-57425 Fixed
This commit is contained in:
committed by
Space Team
parent
d579798169
commit
1936658e40
+14
@@ -0,0 +1,14 @@
|
||||
// FIR_IDENTICAL
|
||||
// ISSUE: KT-57425
|
||||
// WITH_STDLIB
|
||||
|
||||
data class Data(val x: Int?)
|
||||
|
||||
fun test(pair: Pair<String?, Data>) {
|
||||
if (pair.second.x != null) {
|
||||
<!SMARTCAST_IMPOSSIBLE!>pair.second.x<!>.inc() // should be an error
|
||||
}
|
||||
if (pair.first != null) {
|
||||
<!SMARTCAST_IMPOSSIBLE!>pair.first<!>.length // should be an error
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user