[JS IR] Eager initialisation for all pure properties
^KT-43222 fixed
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
// TARGET_BACKEND: JS_IR
|
||||
|
||||
// FILE: A.kt
|
||||
|
||||
val a = "A"
|
||||
|
||||
// FILE: B.kt
|
||||
val b = "B".apply {}
|
||||
|
||||
val c = "C"
|
||||
|
||||
// FILE: main.kt
|
||||
|
||||
fun box(): String {
|
||||
return if (js("a") == "A" && js("typeof b") == "undefined" && js("typeof c") == "undefined")
|
||||
"OK"
|
||||
else "fail"
|
||||
}
|
||||
Reference in New Issue
Block a user