[JS] Support evaluation of const intrinsics for K2

#KT-56023 Fixed
#KT-51582 Fixed
This commit is contained in:
Ivan Kylchik
2023-02-08 14:40:58 +01:00
committed by Space Team
parent e981b1f958
commit 7cf9dda8dc
36 changed files with 413 additions and 40 deletions
@@ -0,0 +1,10 @@
// TARGET_BACKEND: JS_IR
// IGNORE_BACKEND_K1: JS_IR, JS_IR_ES6
const val toStringInConst = 1.0.toString()
fun box(): String {
if (toStringInConst != "1") return "Fail 1"
if (1.0.toString() != toStringInConst) return "Fail 2"
return "OK"
}