[FIR] Don't create smartcasts to error types

This commit is contained in:
Dmitriy Novozhilov
2020-01-21 17:49:30 +03:00
parent 384a094193
commit 9684ff7071
4 changed files with 17 additions and 6 deletions
@@ -38,7 +38,7 @@ fun test() {
1 + platformJ
platformNN + 1
platformN + 1
platformN <!INAPPLICABLE_CANDIDATE!>+<!> 1
platformJ + 1
1 plus platformNN
@@ -46,10 +46,10 @@ fun test() {
1 plus platformJ
platformNN plus 1
platformN plus 1
platformN <!INAPPLICABLE_CANDIDATE!>plus<!> 1
platformJ plus 1
platformNN += 1
platformN += 1
<!UNRESOLVED_REFERENCE!>platformN += 1<!>
platformJ += 1
}
@@ -12,7 +12,7 @@ operator fun Long?.inc() = this?.let { it + 1 }
fun bar(arg: Long?): Long {
var i = arg
if (i++ == 5L) {
return i<!INAPPLICABLE_CANDIDATE!>--<!> + i
return i<!INAPPLICABLE_CANDIDATE!>--<!> <!INAPPLICABLE_CANDIDATE!>+<!> i
}
if (i++ == 7L) {
return i++ <!INAPPLICABLE_CANDIDATE!>+<!> i