Skip to content

Commit

Permalink
js: emit non-breaking whitespace before function arrow in remaining p…
Browse files Browse the repository at this point in the history
…laces
  • Loading branch information
konsoletyper committed Sep 3, 2024
1 parent 9768a86 commit d0707e5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ private boolean writeJavaClassInit(FunctionCall node) {
if (classInitializerInfo == null || classInitializerInfo.isDynamicInitializer(className)) {
writer.appendClassInit(className);
} else {
writer.append("(()").ws().append("=>").ws().append("{})");
writer.append("(()").sameLineWs().append("=>").ws().append("{})");
}
return true;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ private void exportClasses() {

writer.startVariableDeclaration().appendFunction("$rt_jso_marker")
.appendGlobal("Symbol").append("('jsoClass')").endDeclaration();
writer.append("(()").ws().append("=>").ws().append("{").softNewLine().indent();
writer.append("(()").sameLineWs().append("=>").ws().append("{").softNewLine().indent();
writer.append("let c;").softNewLine();
var exportedNamesByClass = new HashMap<String, String>();
for (var className : classSource.getClassNames()) {
Expand Down

0 comments on commit d0707e5

Please sign in to comment.