rip-lang 2.9.1 → 2.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/docs/dist/rip.browser.js +2 -33
- package/docs/dist/rip.browser.min.js +87 -87
- package/docs/dist/rip.browser.min.js.br +0 -0
- package/package.json +1 -1
- package/src/grammar/grammar.rip +1 -1
- package/src/grammar/solar.rip +1 -1
- package/src/lexer.js +0 -59
package/docs/dist/rip.browser.js
CHANGED
|
@@ -1712,7 +1712,6 @@ Rewriter = function() {
|
|
|
1712
1712
|
this.closeOpenCalls();
|
|
1713
1713
|
this.closeOpenIndexes();
|
|
1714
1714
|
this.normalizeLines();
|
|
1715
|
-
this.convertLegacyExistential();
|
|
1716
1715
|
this.convertPostfixSpreadRest();
|
|
1717
1716
|
this.tagPostfixConditionals();
|
|
1718
1717
|
this.addImplicitBracesAndParens();
|
|
@@ -2501,36 +2500,6 @@ Rewriter = function() {
|
|
|
2501
2500
|
return 1;
|
|
2502
2501
|
});
|
|
2503
2502
|
}
|
|
2504
|
-
convertLegacyExistential() {
|
|
2505
|
-
return this.scanTokens(function(token, i, tokens) {
|
|
2506
|
-
var colonFound, j, nestLevel, ref, tag;
|
|
2507
|
-
if (token[0] !== "SPACE?") {
|
|
2508
|
-
return 1;
|
|
2509
|
-
}
|
|
2510
|
-
colonFound = false;
|
|
2511
|
-
nestLevel = 0;
|
|
2512
|
-
for (j = i + 1;j < tokens.length; j++) {
|
|
2513
|
-
tag = tokens[j][0];
|
|
2514
|
-
if (ref = tag, indexOf.call(EXPRESSION_START, ref) >= 0) {
|
|
2515
|
-
nestLevel++;
|
|
2516
|
-
} else if (ref = tag, indexOf.call(EXPRESSION_END, ref) >= 0) {
|
|
2517
|
-
nestLevel--;
|
|
2518
|
-
}
|
|
2519
|
-
if (tag === ":" && nestLevel === 0) {
|
|
2520
|
-
colonFound = true;
|
|
2521
|
-
break;
|
|
2522
|
-
}
|
|
2523
|
-
if (nestLevel === 0 && (tag === "TERMINATOR" || tag === "INDENT" || tag === "OUTDENT")) {
|
|
2524
|
-
break;
|
|
2525
|
-
}
|
|
2526
|
-
}
|
|
2527
|
-
if (!colonFound) {
|
|
2528
|
-
token[0] = "??";
|
|
2529
|
-
token[1] = "??";
|
|
2530
|
-
}
|
|
2531
|
-
return 1;
|
|
2532
|
-
});
|
|
2533
|
-
}
|
|
2534
2503
|
convertPostfixSpreadRest() {
|
|
2535
2504
|
return this.scanTokens(function(token, i, tokens) {
|
|
2536
2505
|
var definiteSpreadNext, inIndexContext, lastIndexEnd, lastIndexStart, next, nextTag, prev, prevTag, ref, validPostfixTokens;
|
|
@@ -7639,8 +7608,8 @@ function compileToJS(source, options = {}) {
|
|
|
7639
7608
|
return new Compiler(options).compileToJS(source);
|
|
7640
7609
|
}
|
|
7641
7610
|
// src/browser.js
|
|
7642
|
-
var VERSION = "2.9.
|
|
7643
|
-
var BUILD_DATE = "2026-02-07@
|
|
7611
|
+
var VERSION = "2.9.2";
|
|
7612
|
+
var BUILD_DATE = "2026-02-07@04:33:48GMT";
|
|
7644
7613
|
var dedent = (s) => {
|
|
7645
7614
|
const m = s.match(/^[ \t]*(?=\S)/gm);
|
|
7646
7615
|
const i = Math.min(...(m || []).map((x) => x.length));
|