Skip to content

Commit

Permalink
Update generated files
Browse files Browse the repository at this point in the history
  • Loading branch information
carlosmiei committed Aug 12, 2024
1 parent 25a630e commit 8f2f960
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 4 deletions.
12 changes: 10 additions & 2 deletions dist/transpiler.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -769,9 +769,17 @@ var BaseTranspiler = class {
if (text in this.StringLiteralReplacements) {
return this.StringLiteralReplacements[text];
}
text = text.replaceAll("'", "\\'");
text = text.replaceAll('"', '\\"');
text = text.replaceAll("\b", "\\b");
text = text.replaceAll("\f", "\\f");
text = text.replaceAll("\n", "\\n");
text = text.replaceAll("\r", "\\r");
text = text.replaceAll(" ", "\\t");
if (token === "'") {
text = text.replaceAll('\\"', '"');
text = text.replaceAll("'", "\\'");
} else if (token === '"') {
text = text.replaceAll('"', '\\"');
}
return token + text + token;
}
printNumericLiteral(node) {
Expand Down
12 changes: 10 additions & 2 deletions dist/transpiler.js
Original file line number Diff line number Diff line change
Expand Up @@ -775,9 +775,17 @@ var BaseTranspiler = class {
if (text in this.StringLiteralReplacements) {
return this.StringLiteralReplacements[text];
}
text = text.replaceAll("'", "\\'");
text = text.replaceAll('"', '\\"');
text = text.replaceAll("\b", "\\b");
text = text.replaceAll("\f", "\\f");
text = text.replaceAll("\n", "\\n");
text = text.replaceAll("\r", "\\r");
text = text.replaceAll(" ", "\\t");
if (token === "'") {
text = text.replaceAll('\\"', '"');
text = text.replaceAll("'", "\\'");
} else if (token === '"') {
text = text.replaceAll('"', '\\"');
}
return token + text + token;
}
printNumericLiteral(node) {
Expand Down

0 comments on commit 8f2f960

Please sign in to comment.