[JS IR] - Remove file lowering declarations from lowering phases
- rename fileToPurenessInitializers onto fileToInitializerPureness - remove redundant check on top-level property [JS IR] Rename initialis* to initializ* for consistency [JS IR] Move propertyLazyInitialization property to context from configuration [JS IR] Add test on lazy initialization properties order [JS IR] Add multi module for lazy initialization of properties [JS IR] Move tests onto js.translator [JS IR] Rename fileToInitializerPureness according to context name ^KT-43222 fixed
This commit is contained in:
+2
-2
@@ -18,8 +18,8 @@ where advanced options include:
|
||||
-Xir-produce-klib-dir Generate unpacked KLIB into parent directory of output JS file.
|
||||
In combination with -meta-info generates both IR and pre-IR versions of library.
|
||||
-Xir-produce-klib-file Generate packed klib into file specified by -output. Disables pre-IR backend
|
||||
-Xir-property-lazy-initialisation
|
||||
Perform lazy initialisation for properties
|
||||
-Xir-property-lazy-initialization
|
||||
Perform lazy initialization for properties
|
||||
-Xmetadata-only Generate *.meta.js and *.kjsm files only
|
||||
-Xtyped-arrays Translate primitive arrays to JS typed arrays
|
||||
-Xwasm Use experimental WebAssembly compiler backend
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
// IGNORE_BACKEND: JS, NATIVE
|
||||
// DONT_TARGET_EXACT_BACKEND: WASM
|
||||
// PROPERTY_LAZY_INITIALISATION
|
||||
|
||||
// FILE: A.kt
|
||||
|
||||
val o = "O"
|
||||
|
||||
// FILE: B.kt
|
||||
val ok = o + k
|
||||
|
||||
// FILE: C.kt
|
||||
|
||||
val k = "K"
|
||||
|
||||
// FILE: main.kt
|
||||
|
||||
fun box(): String = ok
|
||||
@@ -1,32 +0,0 @@
|
||||
// TARGET_BACKEND: JS_IR
|
||||
// PROPERTY_LAZY_INITIALISATION
|
||||
|
||||
// FILE: A.kt
|
||||
|
||||
val a = "A"
|
||||
|
||||
// FILE: B.kt
|
||||
val b = "B".apply {}
|
||||
|
||||
val c = b
|
||||
|
||||
// FILE: C.kt
|
||||
val d = "D".apply {}
|
||||
|
||||
val e = d
|
||||
|
||||
// FILE: main.kt
|
||||
|
||||
fun box(): String {
|
||||
d
|
||||
e
|
||||
return if (
|
||||
js("a") === "A" &&
|
||||
js("typeof b") == "undefined" &&
|
||||
js("typeof c") == "undefined" &&
|
||||
js("d") === "D" &&
|
||||
js("e") === "D"
|
||||
)
|
||||
"OK"
|
||||
else "a = ${js("a")}; typeof b = ${js("typeof b")}; typeof c = ${js("typeof c")}; d = ${js("d")}; e = ${js("e")}"
|
||||
}
|
||||
Reference in New Issue
Block a user