[NI] Update some testdata broken in NI

This commit is contained in:
Dmitriy Novozhilov
2019-12-19 11:29:36 +03:00
parent c311a66e5e
commit 7fed7a840b
17 changed files with 32 additions and 18 deletions
@@ -1,4 +1,5 @@
// !DIAGNOSTICS: -DEBUG_INFO_SMARTCAST
// !WITH_NEW_INFERENCE
fun bar(x: Int) = x + 1
fun foo() {
@@ -1,4 +1,5 @@
// !DIAGNOSTICS: -DEBUG_INFO_SMARTCAST
// !WITH_NEW_INFERENCE
fun bar(x: Int) = x + 1
fun foo() {
@@ -12,17 +13,17 @@ fun foo() {
if (1 > 2) bar(x)
}
if (<!SENSELESS_COMPARISON!>x == null<!>) {
bar(x)
<!NI;UNREACHABLE_CODE!>bar(<!>x<!NI;UNREACHABLE_CODE!>)<!>
}
if (<!SENSELESS_COMPARISON!>x == null<!>) bar(x) else bar(x)
if (<!SENSELESS_COMPARISON!>x == null<!>) <!NI;UNREACHABLE_CODE!>bar(<!>x<!NI;UNREACHABLE_CODE!>)<!> else bar(x)
bar(bar(x))
} else if (<!SENSELESS_COMPARISON!><!DEBUG_INFO_CONSTANT!>x<!> == null<!>) {
bar(<!DEBUG_INFO_CONSTANT, TYPE_MISMATCH!>x<!>)
if (<!SENSELESS_COMPARISON!><!DEBUG_INFO_CONSTANT!>x<!> != null<!>) {
bar(x)
if (<!SENSELESS_COMPARISON!>x == null<!>) bar(x)
if (<!SENSELESS_COMPARISON!>x == null<!>) bar(x) else bar(x)
bar(bar(x) + bar(x))
<!NI;UNREACHABLE_CODE!>bar(<!>x<!NI;UNREACHABLE_CODE!>)<!>
<!NI;UNREACHABLE_CODE!>if (<!SENSELESS_COMPARISON!>x == null<!>) bar(x)<!>
<!NI;UNREACHABLE_CODE!>if (<!SENSELESS_COMPARISON!>x == null<!>) bar(x) else bar(x)<!>
<!NI;UNREACHABLE_CODE!>bar(bar(x) + bar(x))<!>
} else if (<!SENSELESS_COMPARISON!><!DEBUG_INFO_CONSTANT!>x<!> == null<!>) {
bar(<!DEBUG_INFO_CONSTANT, TYPE_MISMATCH!>x<!>)
}
@@ -1,3 +1,4 @@
// !WITH_NEW_INFERENCE
fun bar(x: Int): Int = x + 1
fun foo() {
@@ -1,3 +1,4 @@
// !WITH_NEW_INFERENCE
fun bar(x: Int): Int = x + 1
fun foo() {
@@ -10,7 +11,7 @@ fun foo() {
bar(<!DEBUG_INFO_SMARTCAST!>x<!>)
for (q in a) {
bar(<!DEBUG_INFO_SMARTCAST!>x<!>)
if (<!SENSELESS_COMPARISON!>x == null<!>) bar(<!DEBUG_INFO_SMARTCAST!>x<!>)
if (<!SENSELESS_COMPARISON!>x == null<!>) <!NI;UNREACHABLE_CODE!>bar(<!><!DEBUG_INFO_SMARTCAST!>x<!><!NI;UNREACHABLE_CODE!>)<!>
}
}