JS: create new common directory for all generated tests, migrate several tests there

This commit is contained in:
Alexey Andreev
2016-08-26 16:44:48 +03:00
parent 34a57f863b
commit 2bf0199959
321 changed files with 2123 additions and 2001 deletions
@@ -0,0 +1,23 @@
package foo
// CHECK_CONTAINS_NO_CALLS: multiplyInline
// CHECK_NOT_CALLED: runNoinline
internal inline fun multiply(a: Int, b: Int) = a * b
internal inline fun run(a: Int, b: Int, func: (Int, Int) -> Int) = func(a, b)
internal fun multiplyInline(a: Int, b: Int) = run(a, b, ::multiply)
internal inline fun runNoinline(a: Int, b: Int, noinline func: (Int, Int) -> Int) = func(a, b)
internal fun multiplyNoinline(a: Int, b: Int) = runNoinline(a, b, ::multiply)
fun box(): String {
assertEquals(6, multiplyInline(2, 3))
assertEquals(6, multiplyNoinline(2, 3))
return "OK"
}