[JS IR BE] Support 'is Number' and 'is Comparable<>'

This commit is contained in:
Svyatoslav Kuzmich
2018-10-10 21:54:02 +03:00
parent 783f27c554
commit 5a057f8ca6
8 changed files with 47 additions and 7 deletions
+7 -2
View File
@@ -1,6 +1,11 @@
// IGNORE_BACKEND: JS_IR
// EXPECTED_REACHABLE_NODES: 1523
fun imul32(a: Int, b: Int): Int = js("Kotlin").imulEmulated(a, b)
//@library
//@JsName("imulEmulated")
//internal fun imul(Int, Int): Int
@Suppress("INVISIBLE_MEMBER")
fun imul32(a: Int, b: Int): Int = imul(a, b)
fun imul64(a: Int, b: Int): Int = (a.toLong() * b.toLong()).toInt()
-1
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND: JS_IR
// EXPECTED_REACHABLE_NODES: 1286
package foo