chore: remove usage of globalscope declaration.
This commit is contained in:
+1
-1
@@ -31,7 +31,7 @@ class JsCallTransformer(private val jsOrJsFuncCall: IrCall, private val context:
|
|||||||
0 -> JsEmpty
|
0 -> JsEmpty
|
||||||
1 -> newStatements.single().withSource(jsOrJsFuncCall, context)
|
1 -> newStatements.single().withSource(jsOrJsFuncCall, context)
|
||||||
// TODO: use transparent block (e.g. JsCompositeBlock)
|
// TODO: use transparent block (e.g. JsCompositeBlock)
|
||||||
else -> JsGlobalBlock().apply { statements += newStatements }
|
else -> JsCompositeBlock().apply { statements += newStatements }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1147,15 +1147,6 @@ public class JsToStringGenerationVisitor extends JsVisitor {
|
|||||||
newline();
|
newline();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void visitMultiLineComment(@NotNull JsMultiLineComment comment) {
|
|
||||||
p.print("/*");
|
|
||||||
p.print(comment.getText());
|
|
||||||
p.print("*/");
|
|
||||||
needSemi = false;
|
|
||||||
newline();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void visitDocComment(@NotNull JsDocComment comment) {
|
public void visitDocComment(@NotNull JsDocComment comment) {
|
||||||
boolean asSingleLine = comment.getTags().size() == 1;
|
boolean asSingleLine = comment.getTags().size() == 1;
|
||||||
|
|||||||
@@ -23,4 +23,4 @@ fun box() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// LINES(JS): 6 20 23 7 7 21 7 8 8 21 8 7 7 22 7 8 8 22 8
|
// LINES(JS): 6 20 23 7 7 21 7 8 8 21 8 7 7 22 7 8 8 22 8
|
||||||
// LINES(JS_IR): 7 7 8 8 7 7 8 8
|
// LINES(JS_IR): 7 7 8 8 * 7 7 8 8
|
||||||
|
|||||||
+1
-1
@@ -12,4 +12,4 @@ inline fun bar() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// LINES(JS): 1 7 2 2 10 10 11 11 4 4 10 10 11 11 6 6 9 9 9 9 9 12 10 10 11 11
|
// LINES(JS): 1 7 2 2 10 10 11 11 4 4 10 10 11 11 6 6 9 9 9 9 9 12 10 10 11 11
|
||||||
// LINES(JS_IR): 2 2 10 10 11 11 4 4 10 10 11 11 6 6 * 10 10 11 11
|
// LINES(JS_IR): 2 2 * 10 10 11 11 4 4 * 10 10 11 11 6 6 * 10 10 11 11
|
||||||
|
|||||||
@@ -17,4 +17,4 @@ inline fun foo(f: () -> Unit) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// LINES(JS): 1 11 2 2 14 14 4 4 16 16 6 6 14 14 8 8 16 16 10 10 13 13 13 13 13 17 14 14 15 15 16 16
|
// LINES(JS): 1 11 2 2 14 14 4 4 16 16 6 6 14 14 8 8 16 16 10 10 13 13 13 13 13 17 14 14 15 15 16 16
|
||||||
// LINES(JS_IR): 2 2 14 14 4 4 16 16 6 6 14 14 8 8 16 16 10 10 * 14 14 15 15 16 16
|
// LINES(JS_IR): 2 2 * 14 14 * 4 4 16 16 6 6 * 14 14 * 8 8 16 16 10 10 * 14 14 15 15 16 16
|
||||||
|
|||||||
Reference in New Issue
Block a user