Minor: Fix some test cases

This commit is contained in:
Steven Schäfer
2019-09-24 14:16:13 +02:00
committed by Alexander Udalov
parent 6e9ee2a46c
commit 3659b517bb
3 changed files with 29 additions and 19 deletions
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
class A
fun foo(x: Any?) {}
@@ -11,13 +10,19 @@ fun box() {
z!!
foo(1 as java.lang.Integer)
val y: Any? = if (1 == 1) x else A()
y!!
}
// 0 IFNULL
// 0 checkNotNull
// 0 ATHROW
// JVM_TEMPLATES:
// 1 IFNONNULL
// 1 throwNpe
// 0 ATHROW
// 0 checkNotNull
// JVM_IR_TEMPLATES:
// 0 IFNONULL
// 0 throwNpe
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JVM_IR
class A
fun box() {
val x: A? = A()
@@ -9,12 +8,17 @@ fun box() {
else {
y = null
}
y!!
}
// 0 IFNULL
// 1 IFNONNULL
// 1 throwNpe
// 0 ATHROW
// 0 checkNotNull
// 1 throwNpe
// JVM_TEMPLATES:
// 1 IFNONNULL
// JVM_IR_TEMPLATES:
// 0 IFNONNULL