[FIR-TEST] Add new testdata generated after changes in previous commit

This commit is contained in:
Dmitriy Novozhilov
2019-12-11 16:16:22 +03:00
parent e9c02a1cca
commit 2536fa0cd5
4578 changed files with 104067 additions and 1 deletions
@@ -0,0 +1,15 @@
// Test for a potential byte code mistake for a postfix operation on a smart casted variable
public fun box() : Int {
var i : Int?
i = 10
val ii: Int = i
// k also should be Int
val k : Int = i++
// KT-7561: both i and i++ should be Int, otherwise VerifyError can arise here
// VerifyError reason: byte code tries to store (i++) result which is Int (smart cast)
// into a j which is Int?
val j = i++
// and m also
val m = ++i
return j + k + m + i + ii
}