Migrate boxInline tests to new multi-file framework

This commit is contained in:
Alexander Udalov
2016-02-24 13:29:32 +03:00
committed by Alexander Udalov
parent fa1f7d988e
commit cc84aabdcf
586 changed files with 6946 additions and 5639 deletions
@@ -0,0 +1,41 @@
// FILE: 1.kt
package test
inline fun call(crossinline s: () -> String): String {
return {
s()
}()
}
// FILE: 2.kt
//NO_CHECK_LAMBDA_INLINING
import test.*
class A {
private fun method() = "O"
private val prop = "K"
fun test1(): String {
return call {
method() + prop
}
}
fun test2(): String {
return call {
call {
method() + prop
}
}
}
}
fun box(): String {
val a = A()
if (a.test1() != "OK") return "fail 1: ${a.test1()}"
return a.test2()
}