[JS IR BE] Add JsExport annotations

This commit is contained in:
Svyatoslav Kuzmich
2019-06-27 15:12:14 +03:00
parent 685597d20a
commit 69962cbf8c
22 changed files with 91 additions and 31 deletions
@@ -27,10 +27,13 @@ fun box(): String {
if (!hasProp(b, "foo")) return "B hasn't foo"
if (!hasProp(b, "boo")) return "B hasn't boo"
val PREFIX = "_"
if (eval("$PREFIX.A") == null) return "$PREFIX.A not found"
if (eval("$PREFIX.B") == null) return "$PREFIX.B not found"
if (eval("$PREFIX.A === $PREFIX.B") as Boolean) return "A and B refer to the same object"
// Legacy scheme exports interfaces
if (testUtils.isLegacyBackend()) {
val PREFIX = "_"
if (eval("$PREFIX.A") == null) return "$PREFIX.A not found"
if (eval("$PREFIX.B") == null) return "$PREFIX.B not found"
if (eval("$PREFIX.A === $PREFIX.B") as Boolean) return "A and B refer to the same object"
}
return "OK"
}