Add ir interpreter tests

This commit is contained in:
Ivan Kylchik
2021-05-19 16:27:03 +03:00
committed by TeamCityServer
parent cc2d7340dc
commit e28ab45c51
115 changed files with 5104 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
import kotlin.collections.*
const val a = listOf(1, 2, 3).<!EVALUATED: `3`!>size<!>
const val b = emptyList<Int>().<!EVALUATED: `0`!>size<!>
const val c = listOf<Int>().<!EVALUATED: `1`!>hashCode()<!>
@CompileTimeCalculation
fun getSum(list: List<Int>): Int {
var sum: Int = 0
for (element in list) {
sum += element
}
return sum
}
const val sum = <!EVALUATED: `16`!>getSum(listOf(1, 3, 5, 7))<!>