@danielx/civet 0.5.60 → 0.5.62
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/dist/browser.js +463 -179
- package/dist/main.js +463 -179
- package/dist/main.mjs +463 -179
- package/package.json +1 -1
package/dist/browser.js
CHANGED
|
@@ -451,6 +451,7 @@ ${input.slice(result.pos)}
|
|
|
451
451
|
ArgumentPart,
|
|
452
452
|
BinaryOpExpression,
|
|
453
453
|
BinaryOpRHS,
|
|
454
|
+
RHS,
|
|
454
455
|
ParenthesizedAssignment,
|
|
455
456
|
UnaryExpression,
|
|
456
457
|
UnaryPostfix,
|
|
@@ -563,10 +564,14 @@ ${input.slice(result.pos)}
|
|
|
563
564
|
Block,
|
|
564
565
|
ThenClause,
|
|
565
566
|
BracedOrEmptyBlock,
|
|
567
|
+
NoPostfixBracedOrEmptyBlock,
|
|
566
568
|
EmptyBlock,
|
|
567
569
|
EmptyBareBlock,
|
|
568
570
|
BracedBlock,
|
|
571
|
+
NoPostfixBracedBlock,
|
|
572
|
+
NonSingleBracedBlock,
|
|
569
573
|
SingleLineStatements,
|
|
574
|
+
PostfixedSingleLineStatements,
|
|
570
575
|
BracedContent,
|
|
571
576
|
NestedBlockStatements,
|
|
572
577
|
NestedBlockStatement,
|
|
@@ -622,6 +627,8 @@ ${input.slice(result.pos)}
|
|
|
622
627
|
UnaryOp,
|
|
623
628
|
ModuleItem,
|
|
624
629
|
StatementListItem,
|
|
630
|
+
PostfixedStatement,
|
|
631
|
+
PostfixedExpression,
|
|
625
632
|
PostfixStatement,
|
|
626
633
|
Statement,
|
|
627
634
|
EmptyStatement,
|
|
@@ -668,7 +675,7 @@ ${input.slice(result.pos)}
|
|
|
668
675
|
TryExpression,
|
|
669
676
|
CatchClause,
|
|
670
677
|
CatchBind,
|
|
671
|
-
|
|
678
|
+
FinallyClause,
|
|
672
679
|
CatchParameter,
|
|
673
680
|
Condition,
|
|
674
681
|
ExpressionWithIndentedApplicationSuppressed,
|
|
@@ -801,6 +808,7 @@ ${input.slice(result.pos)}
|
|
|
801
808
|
Equals,
|
|
802
809
|
Export,
|
|
803
810
|
Extends,
|
|
811
|
+
Finally,
|
|
804
812
|
For,
|
|
805
813
|
From,
|
|
806
814
|
Function,
|
|
@@ -935,6 +943,7 @@ ${input.slice(result.pos)}
|
|
|
935
943
|
InlineInterfacePropertyDelimiter,
|
|
936
944
|
TypeBinaryOp,
|
|
937
945
|
FunctionType,
|
|
946
|
+
TypeArrowFunction,
|
|
938
947
|
TypeArguments,
|
|
939
948
|
TypeArgument,
|
|
940
949
|
TypeArgumentDelimiter,
|
|
@@ -1078,41 +1087,41 @@ ${input.slice(result.pos)}
|
|
|
1078
1087
|
var $L80 = $L("|");
|
|
1079
1088
|
var $L81 = $L(";");
|
|
1080
1089
|
var $L82 = $L("own");
|
|
1081
|
-
var $L83 = $L("
|
|
1082
|
-
var $L84 = $L("
|
|
1083
|
-
var $L85 = $L("
|
|
1084
|
-
var $L86 = $L("
|
|
1085
|
-
var $L87 = $L("
|
|
1086
|
-
var $L88 = $L("
|
|
1087
|
-
var $L89 = $L("
|
|
1088
|
-
var $L90 = $L("
|
|
1089
|
-
var $L91 = $L("
|
|
1090
|
-
var $L92 = $L("
|
|
1091
|
-
var $L93 = $L("
|
|
1092
|
-
var $L94 = $L("
|
|
1093
|
-
var $L95 = $L("
|
|
1094
|
-
var $L96 = $L("
|
|
1095
|
-
var $L97 = $L("
|
|
1096
|
-
var $L98 = $L("
|
|
1097
|
-
var $L99 = $L("
|
|
1098
|
-
var $L100 = $L("
|
|
1099
|
-
var $L101 = $L("
|
|
1100
|
-
var $L102 = $L("
|
|
1101
|
-
var $L103 = $L("
|
|
1102
|
-
var $L104 = $L("
|
|
1103
|
-
var $L105 = $L("
|
|
1104
|
-
var $L106 = $L("
|
|
1105
|
-
var $L107 = $L("
|
|
1106
|
-
var $L108 = $L("
|
|
1107
|
-
var $L109 = $L("
|
|
1108
|
-
var $L110 = $L("
|
|
1109
|
-
var $L111 = $L("
|
|
1110
|
-
var $L112 = $L("
|
|
1111
|
-
var $L113 = $L("
|
|
1112
|
-
var $L114 = $L(
|
|
1113
|
-
var $L115 = $L("
|
|
1114
|
-
var $L116 = $L("
|
|
1115
|
-
var $L117 = $L("
|
|
1090
|
+
var $L83 = $L("break");
|
|
1091
|
+
var $L84 = $L("continue");
|
|
1092
|
+
var $L85 = $L("debugger");
|
|
1093
|
+
var $L86 = $L("assert");
|
|
1094
|
+
var $L87 = $L(":=");
|
|
1095
|
+
var $L88 = $L(".=");
|
|
1096
|
+
var $L89 = $L("/*");
|
|
1097
|
+
var $L90 = $L("*/");
|
|
1098
|
+
var $L91 = $L("\\");
|
|
1099
|
+
var $L92 = $L("[");
|
|
1100
|
+
var $L93 = $L("`");
|
|
1101
|
+
var $L94 = $L("abstract");
|
|
1102
|
+
var $L95 = $L("as");
|
|
1103
|
+
var $L96 = $L("@");
|
|
1104
|
+
var $L97 = $L("@@");
|
|
1105
|
+
var $L98 = $L("async");
|
|
1106
|
+
var $L99 = $L("await");
|
|
1107
|
+
var $L100 = $L("by");
|
|
1108
|
+
var $L101 = $L("case");
|
|
1109
|
+
var $L102 = $L("catch");
|
|
1110
|
+
var $L103 = $L("class");
|
|
1111
|
+
var $L104 = $L("#{");
|
|
1112
|
+
var $L105 = $L(",");
|
|
1113
|
+
var $L106 = $L("declare");
|
|
1114
|
+
var $L107 = $L("default");
|
|
1115
|
+
var $L108 = $L("delete");
|
|
1116
|
+
var $L109 = $L("do");
|
|
1117
|
+
var $L110 = $L("..");
|
|
1118
|
+
var $L111 = $L("...");
|
|
1119
|
+
var $L112 = $L("::");
|
|
1120
|
+
var $L113 = $L('"');
|
|
1121
|
+
var $L114 = $L("else");
|
|
1122
|
+
var $L115 = $L("export");
|
|
1123
|
+
var $L116 = $L("extends");
|
|
1124
|
+
var $L117 = $L("finally");
|
|
1116
1125
|
var $L118 = $L("for");
|
|
1117
1126
|
var $L119 = $L("from");
|
|
1118
1127
|
var $L120 = $L("function");
|
|
@@ -1168,7 +1177,7 @@ ${input.slice(result.pos)}
|
|
|
1168
1177
|
var $L170 = $L("infer");
|
|
1169
1178
|
var $L171 = $L("[]");
|
|
1170
1179
|
var $L172 = $L("civet");
|
|
1171
|
-
var $R0 = $R(new RegExp("(as|for|of|satisfies|then|when|implements)(?!\\p{ID_Continue}|[\\u200C\\u200D$])", "suy"));
|
|
1180
|
+
var $R0 = $R(new RegExp("(as|for|while|until|of|satisfies|then|when|implements)(?!\\p{ID_Continue}|[\\u200C\\u200D$])", "suy"));
|
|
1172
1181
|
var $R1 = $R(new RegExp("[0-9]", "suy"));
|
|
1173
1182
|
var $R2 = $R(new RegExp("[&]", "suy"));
|
|
1174
1183
|
var $R3 = $R(new RegExp("[!~+-]+", "suy"));
|
|
@@ -1549,7 +1558,7 @@ ${input.slice(result.pos)}
|
|
|
1549
1558
|
return result;
|
|
1550
1559
|
}
|
|
1551
1560
|
}
|
|
1552
|
-
var ForbiddenImplicitCalls$0 = $R$0($EXPECT($R0, fail, "ForbiddenImplicitCalls /(as|for|of|satisfies|then|when|implements)(?!\\p{ID_Continue}|[\\u200C\\u200D$])/"));
|
|
1561
|
+
var ForbiddenImplicitCalls$0 = $R$0($EXPECT($R0, fail, "ForbiddenImplicitCalls /(as|for|while|until|of|satisfies|then|when|implements)(?!\\p{ID_Continue}|[\\u200C\\u200D$])/"));
|
|
1553
1562
|
var ForbiddenImplicitCalls$1 = $EXPECT($L0, fail, 'ForbiddenImplicitCalls "/ "');
|
|
1554
1563
|
var ForbiddenImplicitCalls$2 = AtAt;
|
|
1555
1564
|
var ForbiddenImplicitCalls$3 = $S(Identifier, $EXPECT($L1, fail, 'ForbiddenImplicitCalls "="'), Whitespace);
|
|
@@ -1868,7 +1877,12 @@ ${input.slice(result.pos)}
|
|
|
1868
1877
|
return result;
|
|
1869
1878
|
}
|
|
1870
1879
|
}
|
|
1871
|
-
var BinaryOpRHS$0 = $S(
|
|
1880
|
+
var BinaryOpRHS$0 = $TS($S(BinaryOp, RHS), function($skip, $loc, $0, $1, $2) {
|
|
1881
|
+
var op = $1;
|
|
1882
|
+
var rhs = $2;
|
|
1883
|
+
return [[], op, [], rhs];
|
|
1884
|
+
});
|
|
1885
|
+
var BinaryOpRHS$1 = $S(__, BinaryOp, $C(_, $S(EOS, __)), RHS);
|
|
1872
1886
|
function BinaryOpRHS(state) {
|
|
1873
1887
|
let eventData;
|
|
1874
1888
|
if (state.events) {
|
|
@@ -1880,17 +1894,42 @@ ${input.slice(result.pos)}
|
|
|
1880
1894
|
}
|
|
1881
1895
|
}
|
|
1882
1896
|
if (state.tokenize) {
|
|
1883
|
-
const result = $TOKEN("BinaryOpRHS", state, BinaryOpRHS$0(state));
|
|
1897
|
+
const result = $TOKEN("BinaryOpRHS", state, BinaryOpRHS$0(state) || BinaryOpRHS$1(state));
|
|
1884
1898
|
if (state.events)
|
|
1885
1899
|
state.events.exit?.("BinaryOpRHS", state, result, eventData);
|
|
1886
1900
|
return result;
|
|
1887
1901
|
} else {
|
|
1888
|
-
const result = BinaryOpRHS$0(state);
|
|
1902
|
+
const result = BinaryOpRHS$0(state) || BinaryOpRHS$1(state);
|
|
1889
1903
|
if (state.events)
|
|
1890
1904
|
state.events.exit?.("BinaryOpRHS", state, result, eventData);
|
|
1891
1905
|
return result;
|
|
1892
1906
|
}
|
|
1893
1907
|
}
|
|
1908
|
+
var RHS$0 = ParenthesizedAssignment;
|
|
1909
|
+
var RHS$1 = UnaryExpression;
|
|
1910
|
+
var RHS$2 = ExpressionizedStatement;
|
|
1911
|
+
function RHS(state) {
|
|
1912
|
+
let eventData;
|
|
1913
|
+
if (state.events) {
|
|
1914
|
+
const result = state.events.enter?.("RHS", state);
|
|
1915
|
+
if (result) {
|
|
1916
|
+
if (result.cache)
|
|
1917
|
+
return result.cache;
|
|
1918
|
+
eventData = result.data;
|
|
1919
|
+
}
|
|
1920
|
+
}
|
|
1921
|
+
if (state.tokenize) {
|
|
1922
|
+
const result = $TOKEN("RHS", state, RHS$0(state) || RHS$1(state) || RHS$2(state));
|
|
1923
|
+
if (state.events)
|
|
1924
|
+
state.events.exit?.("RHS", state, result, eventData);
|
|
1925
|
+
return result;
|
|
1926
|
+
} else {
|
|
1927
|
+
const result = RHS$0(state) || RHS$1(state) || RHS$2(state);
|
|
1928
|
+
if (state.events)
|
|
1929
|
+
state.events.exit?.("RHS", state, result, eventData);
|
|
1930
|
+
return result;
|
|
1931
|
+
}
|
|
1932
|
+
}
|
|
1894
1933
|
var ParenthesizedAssignment$0 = $S(InsertOpenParen, ActualAssignment, InsertCloseParen);
|
|
1895
1934
|
function ParenthesizedAssignment(state) {
|
|
1896
1935
|
let eventData;
|
|
@@ -2314,10 +2353,11 @@ ${input.slice(result.pos)}
|
|
|
2314
2353
|
return result;
|
|
2315
2354
|
}
|
|
2316
2355
|
}
|
|
2317
|
-
var FatArrowBody$0 =
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2356
|
+
var FatArrowBody$0 = $T($S($N(EOS), PostfixedExpression, $N(SemicolonDelimiter)), function(value) {
|
|
2357
|
+
var exp = value[1];
|
|
2358
|
+
return exp;
|
|
2359
|
+
});
|
|
2360
|
+
var FatArrowBody$1 = BracedOrEmptyBlock;
|
|
2321
2361
|
function FatArrowBody(state) {
|
|
2322
2362
|
let eventData;
|
|
2323
2363
|
if (state.events) {
|
|
@@ -2329,12 +2369,12 @@ ${input.slice(result.pos)}
|
|
|
2329
2369
|
}
|
|
2330
2370
|
}
|
|
2331
2371
|
if (state.tokenize) {
|
|
2332
|
-
const result = $TOKEN("FatArrowBody", state, FatArrowBody$0(state) || FatArrowBody$1(state)
|
|
2372
|
+
const result = $TOKEN("FatArrowBody", state, FatArrowBody$0(state) || FatArrowBody$1(state));
|
|
2333
2373
|
if (state.events)
|
|
2334
2374
|
state.events.exit?.("FatArrowBody", state, result, eventData);
|
|
2335
2375
|
return result;
|
|
2336
2376
|
} else {
|
|
2337
|
-
const result = FatArrowBody$0(state) || FatArrowBody$1(state)
|
|
2377
|
+
const result = FatArrowBody$0(state) || FatArrowBody$1(state);
|
|
2338
2378
|
if (state.events)
|
|
2339
2379
|
state.events.exit?.("FatArrowBody", state, result, eventData);
|
|
2340
2380
|
return result;
|
|
@@ -2575,11 +2615,11 @@ ${input.slice(result.pos)}
|
|
|
2575
2615
|
return result;
|
|
2576
2616
|
}
|
|
2577
2617
|
}
|
|
2578
|
-
var ParenthesizedExpression$0 = $TS($S(OpenParen,
|
|
2618
|
+
var ParenthesizedExpression$0 = $TS($S(OpenParen, PostfixedExpression, __, CloseParen), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
2579
2619
|
var exp = $2;
|
|
2580
|
-
|
|
2581
|
-
|
|
2582
|
-
|
|
2620
|
+
switch (exp.type) {
|
|
2621
|
+
case "IterationExpression":
|
|
2622
|
+
return $2;
|
|
2583
2623
|
}
|
|
2584
2624
|
return {
|
|
2585
2625
|
type: "ParenthesizedExpression",
|
|
@@ -3241,7 +3281,12 @@ ${input.slice(result.pos)}
|
|
|
3241
3281
|
}
|
|
3242
3282
|
}
|
|
3243
3283
|
var CallExpressionRest$0 = MemberExpressionRest;
|
|
3244
|
-
var CallExpressionRest$1 = TemplateLiteral
|
|
3284
|
+
var CallExpressionRest$1 = $TV($C(TemplateLiteral, StringLiteral), function($skip, $loc, $0, $1) {
|
|
3285
|
+
if ($1.type === "StringLiteral") {
|
|
3286
|
+
return "`" + $1.token.slice(1, -1).replace(/(`|\$\{)/g, "\\$1") + "`";
|
|
3287
|
+
}
|
|
3288
|
+
return $1;
|
|
3289
|
+
});
|
|
3245
3290
|
var CallExpressionRest$2 = $TS($S($E($C(OptionalShorthand, NonNullAssertion)), ArgumentsWithTrailingMemberExpressions), function($skip, $loc, $0, $1, $2) {
|
|
3246
3291
|
if (!$1)
|
|
3247
3292
|
return $2;
|
|
@@ -3389,7 +3434,7 @@ ${input.slice(result.pos)}
|
|
|
3389
3434
|
return result;
|
|
3390
3435
|
}
|
|
3391
3436
|
}
|
|
3392
|
-
var MemberBracketContent$0 = $TS($S(OpenBracket, $C(SliceParameters,
|
|
3437
|
+
var MemberBracketContent$0 = $TS($S(OpenBracket, $C(SliceParameters, PostfixedExpression), __, CloseBracket), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
3393
3438
|
var open = $1;
|
|
3394
3439
|
var exp = $2;
|
|
3395
3440
|
var ws = $3;
|
|
@@ -3578,7 +3623,7 @@ ${input.slice(result.pos)}
|
|
|
3578
3623
|
return result;
|
|
3579
3624
|
}
|
|
3580
3625
|
}
|
|
3581
|
-
var SuperProperty$0 = $S($EXPECT($L16, fail, 'SuperProperty "super["'),
|
|
3626
|
+
var SuperProperty$0 = $S($EXPECT($L16, fail, 'SuperProperty "super["'), PostfixedExpression, __, CloseBracket);
|
|
3582
3627
|
var SuperProperty$1 = $S($EXPECT($L12, fail, 'SuperProperty "super"'), $N($C(QuestionMark, NonNullAssertion)), PropertyAccess);
|
|
3583
3628
|
function SuperProperty(state) {
|
|
3584
3629
|
let eventData;
|
|
@@ -4999,7 +5044,11 @@ ${input.slice(result.pos)}
|
|
|
4999
5044
|
return result;
|
|
5000
5045
|
}
|
|
5001
5046
|
}
|
|
5002
|
-
var FunctionDeclaration$0 = FunctionExpression
|
|
5047
|
+
var FunctionDeclaration$0 = $TS($S(FunctionExpression), function($skip, $loc, $0, $1) {
|
|
5048
|
+
if ($1.id)
|
|
5049
|
+
return $1;
|
|
5050
|
+
return module.makeLeftHandSideExpression($1);
|
|
5051
|
+
});
|
|
5003
5052
|
function FunctionDeclaration(state) {
|
|
5004
5053
|
let eventData;
|
|
5005
5054
|
if (state.events) {
|
|
@@ -5513,6 +5562,30 @@ ${input.slice(result.pos)}
|
|
|
5513
5562
|
return result;
|
|
5514
5563
|
}
|
|
5515
5564
|
}
|
|
5565
|
+
var NoPostfixBracedOrEmptyBlock$0 = NoPostfixBracedBlock;
|
|
5566
|
+
var NoPostfixBracedOrEmptyBlock$1 = EmptyBlock;
|
|
5567
|
+
function NoPostfixBracedOrEmptyBlock(state) {
|
|
5568
|
+
let eventData;
|
|
5569
|
+
if (state.events) {
|
|
5570
|
+
const result = state.events.enter?.("NoPostfixBracedOrEmptyBlock", state);
|
|
5571
|
+
if (result) {
|
|
5572
|
+
if (result.cache)
|
|
5573
|
+
return result.cache;
|
|
5574
|
+
eventData = result.data;
|
|
5575
|
+
}
|
|
5576
|
+
}
|
|
5577
|
+
if (state.tokenize) {
|
|
5578
|
+
const result = $TOKEN("NoPostfixBracedOrEmptyBlock", state, NoPostfixBracedOrEmptyBlock$0(state) || NoPostfixBracedOrEmptyBlock$1(state));
|
|
5579
|
+
if (state.events)
|
|
5580
|
+
state.events.exit?.("NoPostfixBracedOrEmptyBlock", state, result, eventData);
|
|
5581
|
+
return result;
|
|
5582
|
+
} else {
|
|
5583
|
+
const result = NoPostfixBracedOrEmptyBlock$0(state) || NoPostfixBracedOrEmptyBlock$1(state);
|
|
5584
|
+
if (state.events)
|
|
5585
|
+
state.events.exit?.("NoPostfixBracedOrEmptyBlock", state, result, eventData);
|
|
5586
|
+
return result;
|
|
5587
|
+
}
|
|
5588
|
+
}
|
|
5516
5589
|
var EmptyBlock$0 = $TS($S(InsertOpenBrace, InsertCloseBrace), function($skip, $loc, $0, $1, $2) {
|
|
5517
5590
|
const expressions = [];
|
|
5518
5591
|
return {
|
|
@@ -5576,26 +5649,44 @@ ${input.slice(result.pos)}
|
|
|
5576
5649
|
return result;
|
|
5577
5650
|
}
|
|
5578
5651
|
}
|
|
5579
|
-
var BracedBlock$0 =
|
|
5580
|
-
|
|
5581
|
-
|
|
5582
|
-
type: "BlockStatement",
|
|
5583
|
-
expressions: block.expressions,
|
|
5584
|
-
children: [$1, $2, ...block.children, $4, $5],
|
|
5585
|
-
bare: false
|
|
5586
|
-
};
|
|
5587
|
-
return block;
|
|
5588
|
-
});
|
|
5589
|
-
var BracedBlock$1 = ImplicitNestedBlock;
|
|
5590
|
-
var BracedBlock$2 = $TS($S(InsertOpenBrace, $Y(EOS), ObjectLiteral, InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
5652
|
+
var BracedBlock$0 = NonSingleBracedBlock;
|
|
5653
|
+
var BracedBlock$1 = $TS($S(InsertOpenBrace, $N(EOS), PostfixedSingleLineStatements, InsertSpace, InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
5654
|
+
var o = $1;
|
|
5591
5655
|
var s = $3;
|
|
5656
|
+
var ws = $4;
|
|
5657
|
+
var c = $5;
|
|
5658
|
+
if (!s.children.length)
|
|
5659
|
+
return $skip;
|
|
5592
5660
|
return {
|
|
5593
5661
|
type: "BlockStatement",
|
|
5594
|
-
expressions:
|
|
5595
|
-
children: [
|
|
5662
|
+
expressions: s.expressions,
|
|
5663
|
+
children: [o, s.children, ws, c]
|
|
5596
5664
|
};
|
|
5597
5665
|
});
|
|
5598
|
-
|
|
5666
|
+
function BracedBlock(state) {
|
|
5667
|
+
let eventData;
|
|
5668
|
+
if (state.events) {
|
|
5669
|
+
const result = state.events.enter?.("BracedBlock", state);
|
|
5670
|
+
if (result) {
|
|
5671
|
+
if (result.cache)
|
|
5672
|
+
return result.cache;
|
|
5673
|
+
eventData = result.data;
|
|
5674
|
+
}
|
|
5675
|
+
}
|
|
5676
|
+
if (state.tokenize) {
|
|
5677
|
+
const result = $TOKEN("BracedBlock", state, BracedBlock$0(state) || BracedBlock$1(state));
|
|
5678
|
+
if (state.events)
|
|
5679
|
+
state.events.exit?.("BracedBlock", state, result, eventData);
|
|
5680
|
+
return result;
|
|
5681
|
+
} else {
|
|
5682
|
+
const result = BracedBlock$0(state) || BracedBlock$1(state);
|
|
5683
|
+
if (state.events)
|
|
5684
|
+
state.events.exit?.("BracedBlock", state, result, eventData);
|
|
5685
|
+
return result;
|
|
5686
|
+
}
|
|
5687
|
+
}
|
|
5688
|
+
var NoPostfixBracedBlock$0 = NonSingleBracedBlock;
|
|
5689
|
+
var NoPostfixBracedBlock$1 = $TS($S(InsertOpenBrace, $N(EOS), SingleLineStatements, InsertSpace, InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
5599
5690
|
var o = $1;
|
|
5600
5691
|
var s = $3;
|
|
5601
5692
|
var ws = $4;
|
|
@@ -5608,10 +5699,10 @@ ${input.slice(result.pos)}
|
|
|
5608
5699
|
children: [o, s.children, ws, c]
|
|
5609
5700
|
};
|
|
5610
5701
|
});
|
|
5611
|
-
function
|
|
5702
|
+
function NoPostfixBracedBlock(state) {
|
|
5612
5703
|
let eventData;
|
|
5613
5704
|
if (state.events) {
|
|
5614
|
-
const result = state.events.enter?.("
|
|
5705
|
+
const result = state.events.enter?.("NoPostfixBracedBlock", state);
|
|
5615
5706
|
if (result) {
|
|
5616
5707
|
if (result.cache)
|
|
5617
5708
|
return result.cache;
|
|
@@ -5619,14 +5710,55 @@ ${input.slice(result.pos)}
|
|
|
5619
5710
|
}
|
|
5620
5711
|
}
|
|
5621
5712
|
if (state.tokenize) {
|
|
5622
|
-
const result = $TOKEN("
|
|
5713
|
+
const result = $TOKEN("NoPostfixBracedBlock", state, NoPostfixBracedBlock$0(state) || NoPostfixBracedBlock$1(state));
|
|
5623
5714
|
if (state.events)
|
|
5624
|
-
state.events.exit?.("
|
|
5715
|
+
state.events.exit?.("NoPostfixBracedBlock", state, result, eventData);
|
|
5625
5716
|
return result;
|
|
5626
5717
|
} else {
|
|
5627
|
-
const result =
|
|
5718
|
+
const result = NoPostfixBracedBlock$0(state) || NoPostfixBracedBlock$1(state);
|
|
5628
5719
|
if (state.events)
|
|
5629
|
-
state.events.exit?.("
|
|
5720
|
+
state.events.exit?.("NoPostfixBracedBlock", state, result, eventData);
|
|
5721
|
+
return result;
|
|
5722
|
+
}
|
|
5723
|
+
}
|
|
5724
|
+
var NonSingleBracedBlock$0 = $TS($S($Q(TrailingComment), OpenBrace, BracedContent, __, CloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
5725
|
+
var block = $3;
|
|
5726
|
+
return {
|
|
5727
|
+
type: "BlockStatement",
|
|
5728
|
+
expressions: block.expressions,
|
|
5729
|
+
children: [$1, $2, ...block.children, $4, $5],
|
|
5730
|
+
bare: false
|
|
5731
|
+
};
|
|
5732
|
+
return block;
|
|
5733
|
+
});
|
|
5734
|
+
var NonSingleBracedBlock$1 = ImplicitNestedBlock;
|
|
5735
|
+
var NonSingleBracedBlock$2 = $TS($S(InsertOpenBrace, $Y(EOS), ObjectLiteral, InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
5736
|
+
var s = $3;
|
|
5737
|
+
return {
|
|
5738
|
+
type: "BlockStatement",
|
|
5739
|
+
expressions: [s],
|
|
5740
|
+
children: [$1, s, $3]
|
|
5741
|
+
};
|
|
5742
|
+
});
|
|
5743
|
+
function NonSingleBracedBlock(state) {
|
|
5744
|
+
let eventData;
|
|
5745
|
+
if (state.events) {
|
|
5746
|
+
const result = state.events.enter?.("NonSingleBracedBlock", state);
|
|
5747
|
+
if (result) {
|
|
5748
|
+
if (result.cache)
|
|
5749
|
+
return result.cache;
|
|
5750
|
+
eventData = result.data;
|
|
5751
|
+
}
|
|
5752
|
+
}
|
|
5753
|
+
if (state.tokenize) {
|
|
5754
|
+
const result = $TOKEN("NonSingleBracedBlock", state, NonSingleBracedBlock$0(state) || NonSingleBracedBlock$1(state) || NonSingleBracedBlock$2(state));
|
|
5755
|
+
if (state.events)
|
|
5756
|
+
state.events.exit?.("NonSingleBracedBlock", state, result, eventData);
|
|
5757
|
+
return result;
|
|
5758
|
+
} else {
|
|
5759
|
+
const result = NonSingleBracedBlock$0(state) || NonSingleBracedBlock$1(state) || NonSingleBracedBlock$2(state);
|
|
5760
|
+
if (state.events)
|
|
5761
|
+
state.events.exit?.("NonSingleBracedBlock", state, result, eventData);
|
|
5630
5762
|
return result;
|
|
5631
5763
|
}
|
|
5632
5764
|
}
|
|
@@ -5665,6 +5797,41 @@ ${input.slice(result.pos)}
|
|
|
5665
5797
|
return result;
|
|
5666
5798
|
}
|
|
5667
5799
|
}
|
|
5800
|
+
var PostfixedSingleLineStatements$0 = $TS($S($Q($S($S($E(_), $N(EOS)), PostfixedStatement, SemicolonDelimiter)), $E($S($S($E(_), $N(EOS)), PostfixedStatement, $E(SemicolonDelimiter)))), function($skip, $loc, $0, $1, $2) {
|
|
5801
|
+
var stmts = $1;
|
|
5802
|
+
var last = $2;
|
|
5803
|
+
const children = [...stmts];
|
|
5804
|
+
if (last)
|
|
5805
|
+
children.push(last);
|
|
5806
|
+
return {
|
|
5807
|
+
type: "BlockStatement",
|
|
5808
|
+
expressions: children,
|
|
5809
|
+
children,
|
|
5810
|
+
bare: true
|
|
5811
|
+
};
|
|
5812
|
+
});
|
|
5813
|
+
function PostfixedSingleLineStatements(state) {
|
|
5814
|
+
let eventData;
|
|
5815
|
+
if (state.events) {
|
|
5816
|
+
const result = state.events.enter?.("PostfixedSingleLineStatements", state);
|
|
5817
|
+
if (result) {
|
|
5818
|
+
if (result.cache)
|
|
5819
|
+
return result.cache;
|
|
5820
|
+
eventData = result.data;
|
|
5821
|
+
}
|
|
5822
|
+
}
|
|
5823
|
+
if (state.tokenize) {
|
|
5824
|
+
const result = $TOKEN("PostfixedSingleLineStatements", state, PostfixedSingleLineStatements$0(state));
|
|
5825
|
+
if (state.events)
|
|
5826
|
+
state.events.exit?.("PostfixedSingleLineStatements", state, result, eventData);
|
|
5827
|
+
return result;
|
|
5828
|
+
} else {
|
|
5829
|
+
const result = PostfixedSingleLineStatements$0(state);
|
|
5830
|
+
if (state.events)
|
|
5831
|
+
state.events.exit?.("PostfixedSingleLineStatements", state, result, eventData);
|
|
5832
|
+
return result;
|
|
5833
|
+
}
|
|
5834
|
+
}
|
|
5668
5835
|
var BracedContent$0 = NestedBlockStatements;
|
|
5669
5836
|
var BracedContent$1 = $TS($S($Q(TrailingComment), Statement), function($skip, $loc, $0, $1, $2) {
|
|
5670
5837
|
const expressions = [["", $2]];
|
|
@@ -6965,7 +7132,7 @@ ${input.slice(result.pos)}
|
|
|
6965
7132
|
return result;
|
|
6966
7133
|
}
|
|
6967
7134
|
}
|
|
6968
|
-
var ComputedPropertyName$0 = $TS($S(OpenBracket,
|
|
7135
|
+
var ComputedPropertyName$0 = $TS($S(OpenBracket, PostfixedExpression, __, CloseBracket), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
6969
7136
|
var expression = $2;
|
|
6970
7137
|
return {
|
|
6971
7138
|
type: "ComputedPropertyName",
|
|
@@ -7509,7 +7676,12 @@ ${input.slice(result.pos)}
|
|
|
7509
7676
|
return "??";
|
|
7510
7677
|
});
|
|
7511
7678
|
var BinaryOpSymbol$28 = $TS($S($EXPECT($L75, fail, 'BinaryOpSymbol "instanceof"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
7512
|
-
return
|
|
7679
|
+
return {
|
|
7680
|
+
$loc,
|
|
7681
|
+
token: $1,
|
|
7682
|
+
relational: true,
|
|
7683
|
+
special: true
|
|
7684
|
+
};
|
|
7513
7685
|
});
|
|
7514
7686
|
var BinaryOpSymbol$29 = $TS($S($EXPECT($L50, fail, 'BinaryOpSymbol "not"'), NonIdContinue, __, $EXPECT($L75, fail, 'BinaryOpSymbol "instanceof"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
7515
7687
|
return {
|
|
@@ -7667,13 +7839,7 @@ ${input.slice(result.pos)}
|
|
|
7667
7839
|
}
|
|
7668
7840
|
}
|
|
7669
7841
|
var StatementListItem$0 = Declaration;
|
|
7670
|
-
var StatementListItem$1 =
|
|
7671
|
-
var statement = $1;
|
|
7672
|
-
var post = $2;
|
|
7673
|
-
if (post)
|
|
7674
|
-
return module.addPostfixStatement(statement, ...post);
|
|
7675
|
-
return statement;
|
|
7676
|
-
});
|
|
7842
|
+
var StatementListItem$1 = PostfixedStatement;
|
|
7677
7843
|
function StatementListItem(state) {
|
|
7678
7844
|
let eventData;
|
|
7679
7845
|
if (state.events) {
|
|
@@ -7696,6 +7862,64 @@ ${input.slice(result.pos)}
|
|
|
7696
7862
|
return result;
|
|
7697
7863
|
}
|
|
7698
7864
|
}
|
|
7865
|
+
var PostfixedStatement$0 = $TS($S(Statement, $E($S($Q(TrailingComment), PostfixStatement))), function($skip, $loc, $0, $1, $2) {
|
|
7866
|
+
var statement = $1;
|
|
7867
|
+
var post = $2;
|
|
7868
|
+
if (post)
|
|
7869
|
+
return module.addPostfixStatement(statement, ...post);
|
|
7870
|
+
return statement;
|
|
7871
|
+
});
|
|
7872
|
+
function PostfixedStatement(state) {
|
|
7873
|
+
let eventData;
|
|
7874
|
+
if (state.events) {
|
|
7875
|
+
const result = state.events.enter?.("PostfixedStatement", state);
|
|
7876
|
+
if (result) {
|
|
7877
|
+
if (result.cache)
|
|
7878
|
+
return result.cache;
|
|
7879
|
+
eventData = result.data;
|
|
7880
|
+
}
|
|
7881
|
+
}
|
|
7882
|
+
if (state.tokenize) {
|
|
7883
|
+
const result = $TOKEN("PostfixedStatement", state, PostfixedStatement$0(state));
|
|
7884
|
+
if (state.events)
|
|
7885
|
+
state.events.exit?.("PostfixedStatement", state, result, eventData);
|
|
7886
|
+
return result;
|
|
7887
|
+
} else {
|
|
7888
|
+
const result = PostfixedStatement$0(state);
|
|
7889
|
+
if (state.events)
|
|
7890
|
+
state.events.exit?.("PostfixedStatement", state, result, eventData);
|
|
7891
|
+
return result;
|
|
7892
|
+
}
|
|
7893
|
+
}
|
|
7894
|
+
var PostfixedExpression$0 = $TS($S(ExtendedExpression, $E($S($Q(TrailingComment), PostfixStatement))), function($skip, $loc, $0, $1, $2) {
|
|
7895
|
+
var expression = $1;
|
|
7896
|
+
var post = $2;
|
|
7897
|
+
if (post)
|
|
7898
|
+
return module.attachPostfixStatementAsExpression(expression, post);
|
|
7899
|
+
return expression;
|
|
7900
|
+
});
|
|
7901
|
+
function PostfixedExpression(state) {
|
|
7902
|
+
let eventData;
|
|
7903
|
+
if (state.events) {
|
|
7904
|
+
const result = state.events.enter?.("PostfixedExpression", state);
|
|
7905
|
+
if (result) {
|
|
7906
|
+
if (result.cache)
|
|
7907
|
+
return result.cache;
|
|
7908
|
+
eventData = result.data;
|
|
7909
|
+
}
|
|
7910
|
+
}
|
|
7911
|
+
if (state.tokenize) {
|
|
7912
|
+
const result = $TOKEN("PostfixedExpression", state, PostfixedExpression$0(state));
|
|
7913
|
+
if (state.events)
|
|
7914
|
+
state.events.exit?.("PostfixedExpression", state, result, eventData);
|
|
7915
|
+
return result;
|
|
7916
|
+
} else {
|
|
7917
|
+
const result = PostfixedExpression$0(state);
|
|
7918
|
+
if (state.events)
|
|
7919
|
+
state.events.exit?.("PostfixedExpression", state, result, eventData);
|
|
7920
|
+
return result;
|
|
7921
|
+
}
|
|
7922
|
+
}
|
|
7699
7923
|
var PostfixStatement$0 = ForClause;
|
|
7700
7924
|
var PostfixStatement$1 = IfClause;
|
|
7701
7925
|
var PostfixStatement$2 = LoopClause;
|
|
@@ -7731,12 +7955,8 @@ ${input.slice(result.pos)}
|
|
|
7731
7955
|
var Statement$5 = TryStatement;
|
|
7732
7956
|
var Statement$6 = EmptyStatement;
|
|
7733
7957
|
var Statement$7 = $TS($S(ExpressionStatement), function($skip, $loc, $0, $1) {
|
|
7734
|
-
if ($1.type === "ObjectExpression") {
|
|
7735
|
-
return
|
|
7736
|
-
type: "ParenthesizedExpression",
|
|
7737
|
-
children: ["(", $1, ")"],
|
|
7738
|
-
expression: $1
|
|
7739
|
-
};
|
|
7958
|
+
if ($1.type === "ObjectExpression" || $1.type === "FunctionExpression" && !$1.id) {
|
|
7959
|
+
return module.makeLeftHandSideExpression($1);
|
|
7740
7960
|
}
|
|
7741
7961
|
return $1;
|
|
7742
7962
|
});
|
|
@@ -7824,6 +8044,8 @@ ${input.slice(result.pos)}
|
|
|
7824
8044
|
children.push(e);
|
|
7825
8045
|
return {
|
|
7826
8046
|
type: "IfStatement",
|
|
8047
|
+
then: block,
|
|
8048
|
+
else: e,
|
|
7827
8049
|
children
|
|
7828
8050
|
};
|
|
7829
8051
|
});
|
|
@@ -7901,7 +8123,7 @@ ${input.slice(result.pos)}
|
|
|
7901
8123
|
var UnlessClause$0 = $TS($S(Unless, Condition), function($skip, $loc, $0, $1, $2) {
|
|
7902
8124
|
var kind = $1;
|
|
7903
8125
|
var condition = $2;
|
|
7904
|
-
kind
|
|
8126
|
+
kind = { ...kind, token: "if" };
|
|
7905
8127
|
return {
|
|
7906
8128
|
type: "IfStatement",
|
|
7907
8129
|
children: [kind, ["(!", condition, ")"]]
|
|
@@ -8130,16 +8352,7 @@ ${input.slice(result.pos)}
|
|
|
8130
8352
|
return result;
|
|
8131
8353
|
}
|
|
8132
8354
|
}
|
|
8133
|
-
var NestedBlockExpression$0 = $
|
|
8134
|
-
var ws = $1;
|
|
8135
|
-
var exp = $2;
|
|
8136
|
-
var post = $3;
|
|
8137
|
-
var d = $4;
|
|
8138
|
-
if (post) {
|
|
8139
|
-
return [ws, module.attachPostfixStatementAsExpression(exp, post), d];
|
|
8140
|
-
}
|
|
8141
|
-
return [ws, exp, d];
|
|
8142
|
-
});
|
|
8355
|
+
var NestedBlockExpression$0 = $S(Nested, PostfixedExpression, ExpressionDelimiter);
|
|
8143
8356
|
function NestedBlockExpression(state) {
|
|
8144
8357
|
let eventData;
|
|
8145
8358
|
if (state.events) {
|
|
@@ -8275,7 +8488,7 @@ ${input.slice(result.pos)}
|
|
|
8275
8488
|
return result;
|
|
8276
8489
|
}
|
|
8277
8490
|
}
|
|
8278
|
-
var DoWhileStatement$0 = $T($S(Do,
|
|
8491
|
+
var DoWhileStatement$0 = $T($S(Do, NoPostfixBracedBlock, __, WhileClause), function(value) {
|
|
8279
8492
|
var block = value[1];
|
|
8280
8493
|
return { "type": "IterationStatement", "children": value, "block": block };
|
|
8281
8494
|
});
|
|
@@ -8443,9 +8656,11 @@ ${input.slice(result.pos)}
|
|
|
8443
8656
|
var ForStatementControl$1 = $TS($S(CoffeeForLoopsEnabled, CoffeeForStatementParameters, $E(WhenCondition)), function($skip, $loc, $0, $1, $2, $3) {
|
|
8444
8657
|
if ($3) {
|
|
8445
8658
|
const indent = module.currentIndent.token + " ";
|
|
8659
|
+
const block = "continue\n";
|
|
8446
8660
|
$2.blockPrefix.push([indent, {
|
|
8447
8661
|
type: "IfStatement",
|
|
8448
|
-
|
|
8662
|
+
then: block,
|
|
8663
|
+
children: ["if (!(", module.insertTrimmingSpace($3, ""), ")) ", block]
|
|
8449
8664
|
}]);
|
|
8450
8665
|
}
|
|
8451
8666
|
return $2;
|
|
@@ -9229,7 +9444,7 @@ ${input.slice(result.pos)}
|
|
|
9229
9444
|
return result;
|
|
9230
9445
|
}
|
|
9231
9446
|
}
|
|
9232
|
-
var TryStatement$0 = $TS($S(Try,
|
|
9447
|
+
var TryStatement$0 = $TS($S(Try, NoPostfixBracedOrEmptyBlock, $E(CatchClause), $E(FinallyClause)), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
9233
9448
|
var t = $1;
|
|
9234
9449
|
var b = $2;
|
|
9235
9450
|
var c = $3;
|
|
@@ -9297,7 +9512,7 @@ ${input.slice(result.pos)}
|
|
|
9297
9512
|
return result;
|
|
9298
9513
|
}
|
|
9299
9514
|
}
|
|
9300
|
-
var CatchClause$0 = $S(
|
|
9515
|
+
var CatchClause$0 = $S($C(Samedent, _), Catch, $E(CatchBind), $C(ThenClause, BracedOrEmptyBlock));
|
|
9301
9516
|
function CatchClause(state) {
|
|
9302
9517
|
let eventData;
|
|
9303
9518
|
if (state.events) {
|
|
@@ -9320,8 +9535,8 @@ ${input.slice(result.pos)}
|
|
|
9320
9535
|
return result;
|
|
9321
9536
|
}
|
|
9322
9537
|
}
|
|
9323
|
-
var CatchBind$0 = $S(
|
|
9324
|
-
var CatchBind$1 = $S(
|
|
9538
|
+
var CatchBind$0 = $S($E(_), OpenParen, __, CatchParameter, __, CloseParen);
|
|
9539
|
+
var CatchBind$1 = $S(_, InsertOpenParen, CatchParameter, InsertCloseParen);
|
|
9325
9540
|
function CatchBind(state) {
|
|
9326
9541
|
let eventData;
|
|
9327
9542
|
if (state.events) {
|
|
@@ -9344,11 +9559,11 @@ ${input.slice(result.pos)}
|
|
|
9344
9559
|
return result;
|
|
9345
9560
|
}
|
|
9346
9561
|
}
|
|
9347
|
-
var
|
|
9348
|
-
function
|
|
9562
|
+
var FinallyClause$0 = $S($C(Samedent, _), Finally, $C(ThenClause, BracedOrEmptyBlock));
|
|
9563
|
+
function FinallyClause(state) {
|
|
9349
9564
|
let eventData;
|
|
9350
9565
|
if (state.events) {
|
|
9351
|
-
const result = state.events.enter?.("
|
|
9566
|
+
const result = state.events.enter?.("FinallyClause", state);
|
|
9352
9567
|
if (result) {
|
|
9353
9568
|
if (result.cache)
|
|
9354
9569
|
return result.cache;
|
|
@@ -9356,14 +9571,14 @@ ${input.slice(result.pos)}
|
|
|
9356
9571
|
}
|
|
9357
9572
|
}
|
|
9358
9573
|
if (state.tokenize) {
|
|
9359
|
-
const result = $TOKEN("
|
|
9574
|
+
const result = $TOKEN("FinallyClause", state, FinallyClause$0(state));
|
|
9360
9575
|
if (state.events)
|
|
9361
|
-
state.events.exit?.("
|
|
9576
|
+
state.events.exit?.("FinallyClause", state, result, eventData);
|
|
9362
9577
|
return result;
|
|
9363
9578
|
} else {
|
|
9364
|
-
const result =
|
|
9579
|
+
const result = FinallyClause$0(state);
|
|
9365
9580
|
if (state.events)
|
|
9366
|
-
state.events.exit?.("
|
|
9581
|
+
state.events.exit?.("FinallyClause", state, result, eventData);
|
|
9367
9582
|
return result;
|
|
9368
9583
|
}
|
|
9369
9584
|
}
|
|
@@ -9584,13 +9799,13 @@ ${input.slice(result.pos)}
|
|
|
9584
9799
|
return result;
|
|
9585
9800
|
}
|
|
9586
9801
|
}
|
|
9587
|
-
var KeywordStatement$0 = $T($S($EXPECT($
|
|
9802
|
+
var KeywordStatement$0 = $T($S($EXPECT($L83, fail, 'KeywordStatement "break"'), NonIdContinue), function(value) {
|
|
9588
9803
|
return { "type": "BreakStatement", "children": value };
|
|
9589
9804
|
});
|
|
9590
|
-
var KeywordStatement$1 = $T($S($EXPECT($
|
|
9805
|
+
var KeywordStatement$1 = $T($S($EXPECT($L84, fail, 'KeywordStatement "continue"'), NonIdContinue), function(value) {
|
|
9591
9806
|
return { "type": "ContinueStatement", "children": value };
|
|
9592
9807
|
});
|
|
9593
|
-
var KeywordStatement$2 = $T($S($EXPECT($
|
|
9808
|
+
var KeywordStatement$2 = $T($S($EXPECT($L85, fail, 'KeywordStatement "debugger"'), NonIdContinue), function(value) {
|
|
9594
9809
|
return { "type": "DebuggerStatement", "children": value };
|
|
9595
9810
|
});
|
|
9596
9811
|
var KeywordStatement$3 = $T($S(Return, $E(MaybeNestedExpression)), function(value) {
|
|
@@ -9621,7 +9836,7 @@ ${input.slice(result.pos)}
|
|
|
9621
9836
|
return result;
|
|
9622
9837
|
}
|
|
9623
9838
|
}
|
|
9624
|
-
var DebuggerExpression$0 = $TS($S($EXPECT($
|
|
9839
|
+
var DebuggerExpression$0 = $TS($S($EXPECT($L85, fail, 'DebuggerExpression "debugger"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
9625
9840
|
return {
|
|
9626
9841
|
type: "DebuggerExpression",
|
|
9627
9842
|
children: ["(()=>{", $1, "})()"]
|
|
@@ -9898,7 +10113,7 @@ ${input.slice(result.pos)}
|
|
|
9898
10113
|
return result;
|
|
9899
10114
|
}
|
|
9900
10115
|
}
|
|
9901
|
-
var ImportAssertion$0 = $S($E(_), $EXPECT($
|
|
10116
|
+
var ImportAssertion$0 = $S($E(_), $EXPECT($L86, fail, 'ImportAssertion "assert"'), NonIdContinue, $E(_), ObjectLiteral);
|
|
9902
10117
|
function ImportAssertion(state) {
|
|
9903
10118
|
let eventData;
|
|
9904
10119
|
if (state.events) {
|
|
@@ -10502,7 +10717,7 @@ ${input.slice(result.pos)}
|
|
|
10502
10717
|
return result;
|
|
10503
10718
|
}
|
|
10504
10719
|
}
|
|
10505
|
-
var ConstAssignment$0 = $TV($EXPECT($
|
|
10720
|
+
var ConstAssignment$0 = $TV($EXPECT($L87, fail, 'ConstAssignment ":="'), function($skip, $loc, $0, $1) {
|
|
10506
10721
|
return { $loc, token: "=" };
|
|
10507
10722
|
});
|
|
10508
10723
|
function ConstAssignment(state) {
|
|
@@ -10527,7 +10742,7 @@ ${input.slice(result.pos)}
|
|
|
10527
10742
|
return result;
|
|
10528
10743
|
}
|
|
10529
10744
|
}
|
|
10530
|
-
var LetAssignment$0 = $TV($EXPECT($
|
|
10745
|
+
var LetAssignment$0 = $TV($EXPECT($L88, fail, 'LetAssignment ".="'), function($skip, $loc, $0, $1) {
|
|
10531
10746
|
return { $loc, token: "=" };
|
|
10532
10747
|
});
|
|
10533
10748
|
function LetAssignment(state) {
|
|
@@ -10725,7 +10940,7 @@ ${input.slice(result.pos)}
|
|
|
10725
10940
|
}
|
|
10726
10941
|
}
|
|
10727
10942
|
var NumericLiteral$0 = $TS($S(NumericLiteralKind), function($skip, $loc, $0, $1) {
|
|
10728
|
-
return { $loc, token: $1 };
|
|
10943
|
+
return { type: "NumericLiteral", $loc, token: $1 };
|
|
10729
10944
|
});
|
|
10730
10945
|
function NumericLiteral(state) {
|
|
10731
10946
|
let eventData;
|
|
@@ -10996,6 +11211,7 @@ ${input.slice(result.pos)}
|
|
|
10996
11211
|
var StringLiteral$0 = $TS($S(DoubleQuote, DoubleStringCharacters, DoubleQuote), function($skip, $loc, $0, $1, $2, $3) {
|
|
10997
11212
|
var str = $2;
|
|
10998
11213
|
return {
|
|
11214
|
+
type: "StringLiteral",
|
|
10999
11215
|
token: `"${module.modifyString(str.token)}"`,
|
|
11000
11216
|
$loc
|
|
11001
11217
|
};
|
|
@@ -11003,6 +11219,7 @@ ${input.slice(result.pos)}
|
|
|
11003
11219
|
var StringLiteral$1 = $TS($S(SingleQuote, SingleStringCharacters, SingleQuote), function($skip, $loc, $0, $1, $2, $3) {
|
|
11004
11220
|
var str = $2;
|
|
11005
11221
|
return {
|
|
11222
|
+
type: "StringLiteral",
|
|
11006
11223
|
token: `'${module.modifyString(str.token)}'`,
|
|
11007
11224
|
$loc
|
|
11008
11225
|
};
|
|
@@ -11129,7 +11346,7 @@ ${input.slice(result.pos)}
|
|
|
11129
11346
|
return result;
|
|
11130
11347
|
}
|
|
11131
11348
|
}
|
|
11132
|
-
var CoffeeStringSubstitution$0 = $S(CoffeeSubstitutionStart,
|
|
11349
|
+
var CoffeeStringSubstitution$0 = $S(CoffeeSubstitutionStart, PostfixedExpression, __, CloseBrace);
|
|
11133
11350
|
function CoffeeStringSubstitution(state) {
|
|
11134
11351
|
let eventData;
|
|
11135
11352
|
if (state.events) {
|
|
@@ -11569,7 +11786,7 @@ ${input.slice(result.pos)}
|
|
|
11569
11786
|
return result;
|
|
11570
11787
|
}
|
|
11571
11788
|
}
|
|
11572
|
-
var TemplateSubstitution$0 = $S(SubstitutionStart,
|
|
11789
|
+
var TemplateSubstitution$0 = $S(SubstitutionStart, PostfixedExpression, __, CloseBrace);
|
|
11573
11790
|
function TemplateSubstitution(state) {
|
|
11574
11791
|
let eventData;
|
|
11575
11792
|
if (state.events) {
|
|
@@ -11766,7 +11983,7 @@ ${input.slice(result.pos)}
|
|
|
11766
11983
|
return result;
|
|
11767
11984
|
}
|
|
11768
11985
|
}
|
|
11769
|
-
var JSMultiLineComment$0 = $TV($TEXT($S($EXPECT($
|
|
11986
|
+
var JSMultiLineComment$0 = $TV($TEXT($S($EXPECT($L89, fail, 'JSMultiLineComment "/*"'), $Q($S($N($EXPECT($L90, fail, 'JSMultiLineComment "*/"')), $EXPECT($R40, fail, "JSMultiLineComment /./"))), $EXPECT($L90, fail, 'JSMultiLineComment "*/"'))), function($skip, $loc, $0, $1) {
|
|
11770
11987
|
return { $loc, token: $1 };
|
|
11771
11988
|
});
|
|
11772
11989
|
function JSMultiLineComment(state) {
|
|
@@ -11865,7 +12082,7 @@ ${input.slice(result.pos)}
|
|
|
11865
12082
|
return result;
|
|
11866
12083
|
}
|
|
11867
12084
|
}
|
|
11868
|
-
var InlineComment$0 = $TV($TEXT($S($EXPECT($
|
|
12085
|
+
var InlineComment$0 = $TV($TEXT($S($EXPECT($L89, fail, 'InlineComment "/*"'), $TEXT($Q($S($N($EXPECT($L90, fail, 'InlineComment "*/"')), $EXPECT($R44, fail, "InlineComment /[^\\r\\n]/")))), $EXPECT($L90, fail, 'InlineComment "*/"'))), function($skip, $loc, $0, $1) {
|
|
11869
12086
|
return { $loc, token: $1 };
|
|
11870
12087
|
});
|
|
11871
12088
|
function InlineComment(state) {
|
|
@@ -11964,7 +12181,7 @@ ${input.slice(result.pos)}
|
|
|
11964
12181
|
var NonNewlineWhitespace$0 = $TR($EXPECT($R45, fail, "NonNewlineWhitespace /[ \\t]+/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
|
|
11965
12182
|
return { $loc, token: $0 };
|
|
11966
12183
|
});
|
|
11967
|
-
var NonNewlineWhitespace$1 = $T($S(CoffeeLineContinuationEnabled, $EXPECT($
|
|
12184
|
+
var NonNewlineWhitespace$1 = $T($S(CoffeeLineContinuationEnabled, $EXPECT($L91, fail, 'NonNewlineWhitespace "\\\\\\\\"'), EOL), function(value) {
|
|
11968
12185
|
return "";
|
|
11969
12186
|
});
|
|
11970
12187
|
function NonNewlineWhitespace(state) {
|
|
@@ -12116,7 +12333,7 @@ ${input.slice(result.pos)}
|
|
|
12116
12333
|
}
|
|
12117
12334
|
}
|
|
12118
12335
|
var StatementDelimiter$0 = SemicolonDelimiter;
|
|
12119
|
-
var StatementDelimiter$1 = $S($Y($S(Samedent, $C($EXPECT($L2, fail, 'StatementDelimiter "("'), $EXPECT($
|
|
12336
|
+
var StatementDelimiter$1 = $S($Y($S(Samedent, $C($EXPECT($L2, fail, 'StatementDelimiter "("'), $EXPECT($L92, fail, 'StatementDelimiter "["'), $EXPECT($L93, fail, 'StatementDelimiter "`"'), $EXPECT($L56, fail, 'StatementDelimiter "+"'), $EXPECT($L15, fail, 'StatementDelimiter "-"'), $EXPECT($L52, fail, 'StatementDelimiter "*"'), $EXPECT($L53, fail, 'StatementDelimiter "/"'), ObjectLiteral, Arrow, $S(Function, $E($S($E(_), Star)), $E(_), $EXPECT($L2, fail, 'StatementDelimiter "("'))))), InsertSemicolon);
|
|
12120
12337
|
var StatementDelimiter$2 = $Y(EOS);
|
|
12121
12338
|
function StatementDelimiter(state) {
|
|
12122
12339
|
let eventData;
|
|
@@ -12216,7 +12433,7 @@ ${input.slice(result.pos)}
|
|
|
12216
12433
|
return result;
|
|
12217
12434
|
}
|
|
12218
12435
|
}
|
|
12219
|
-
var Abstract$0 = $TV($TEXT($S($EXPECT($
|
|
12436
|
+
var Abstract$0 = $TV($TEXT($S($EXPECT($L94, fail, 'Abstract "abstract"'), NonIdContinue, $E($EXPECT($L8, fail, 'Abstract " "')))), function($skip, $loc, $0, $1) {
|
|
12220
12437
|
return { $loc, token: $1, ts: true };
|
|
12221
12438
|
});
|
|
12222
12439
|
function Abstract(state) {
|
|
@@ -12266,7 +12483,7 @@ ${input.slice(result.pos)}
|
|
|
12266
12483
|
return result;
|
|
12267
12484
|
}
|
|
12268
12485
|
}
|
|
12269
|
-
var As$0 = $TS($S($EXPECT($
|
|
12486
|
+
var As$0 = $TS($S($EXPECT($L95, fail, 'As "as"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12270
12487
|
return { $loc, token: $1 };
|
|
12271
12488
|
});
|
|
12272
12489
|
function As(state) {
|
|
@@ -12291,7 +12508,7 @@ ${input.slice(result.pos)}
|
|
|
12291
12508
|
return result;
|
|
12292
12509
|
}
|
|
12293
12510
|
}
|
|
12294
|
-
var At$0 = $TV($EXPECT($
|
|
12511
|
+
var At$0 = $TV($EXPECT($L96, fail, 'At "@"'), function($skip, $loc, $0, $1) {
|
|
12295
12512
|
return { $loc, token: $1 };
|
|
12296
12513
|
});
|
|
12297
12514
|
function At(state) {
|
|
@@ -12316,7 +12533,7 @@ ${input.slice(result.pos)}
|
|
|
12316
12533
|
return result;
|
|
12317
12534
|
}
|
|
12318
12535
|
}
|
|
12319
|
-
var AtAt$0 = $TV($EXPECT($
|
|
12536
|
+
var AtAt$0 = $TV($EXPECT($L97, fail, 'AtAt "@@"'), function($skip, $loc, $0, $1) {
|
|
12320
12537
|
return { $loc, token: "@" };
|
|
12321
12538
|
});
|
|
12322
12539
|
function AtAt(state) {
|
|
@@ -12341,7 +12558,7 @@ ${input.slice(result.pos)}
|
|
|
12341
12558
|
return result;
|
|
12342
12559
|
}
|
|
12343
12560
|
}
|
|
12344
|
-
var Async$0 = $TS($S($EXPECT($
|
|
12561
|
+
var Async$0 = $TS($S($EXPECT($L98, fail, 'Async "async"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12345
12562
|
return { $loc, token: $1, type: "Async" };
|
|
12346
12563
|
});
|
|
12347
12564
|
function Async(state) {
|
|
@@ -12366,7 +12583,7 @@ ${input.slice(result.pos)}
|
|
|
12366
12583
|
return result;
|
|
12367
12584
|
}
|
|
12368
12585
|
}
|
|
12369
|
-
var Await$0 = $TS($S($EXPECT($
|
|
12586
|
+
var Await$0 = $TS($S($EXPECT($L99, fail, 'Await "await"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12370
12587
|
return { $loc, token: $1 };
|
|
12371
12588
|
});
|
|
12372
12589
|
function Await(state) {
|
|
@@ -12391,7 +12608,7 @@ ${input.slice(result.pos)}
|
|
|
12391
12608
|
return result;
|
|
12392
12609
|
}
|
|
12393
12610
|
}
|
|
12394
|
-
var Backtick$0 = $TV($EXPECT($
|
|
12611
|
+
var Backtick$0 = $TV($EXPECT($L93, fail, 'Backtick "`"'), function($skip, $loc, $0, $1) {
|
|
12395
12612
|
return { $loc, token: $1 };
|
|
12396
12613
|
});
|
|
12397
12614
|
function Backtick(state) {
|
|
@@ -12416,7 +12633,7 @@ ${input.slice(result.pos)}
|
|
|
12416
12633
|
return result;
|
|
12417
12634
|
}
|
|
12418
12635
|
}
|
|
12419
|
-
var By$0 = $TS($S($EXPECT($
|
|
12636
|
+
var By$0 = $TS($S($EXPECT($L100, fail, 'By "by"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12420
12637
|
return { $loc, token: $1 };
|
|
12421
12638
|
});
|
|
12422
12639
|
function By(state) {
|
|
@@ -12441,7 +12658,7 @@ ${input.slice(result.pos)}
|
|
|
12441
12658
|
return result;
|
|
12442
12659
|
}
|
|
12443
12660
|
}
|
|
12444
|
-
var Case$0 = $TS($S($EXPECT($
|
|
12661
|
+
var Case$0 = $TS($S($EXPECT($L101, fail, 'Case "case"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12445
12662
|
return { $loc, token: $1 };
|
|
12446
12663
|
});
|
|
12447
12664
|
function Case(state) {
|
|
@@ -12466,7 +12683,7 @@ ${input.slice(result.pos)}
|
|
|
12466
12683
|
return result;
|
|
12467
12684
|
}
|
|
12468
12685
|
}
|
|
12469
|
-
var Catch$0 = $TS($S($EXPECT($
|
|
12686
|
+
var Catch$0 = $TS($S($EXPECT($L102, fail, 'Catch "catch"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12470
12687
|
return { $loc, token: $1 };
|
|
12471
12688
|
});
|
|
12472
12689
|
function Catch(state) {
|
|
@@ -12491,7 +12708,7 @@ ${input.slice(result.pos)}
|
|
|
12491
12708
|
return result;
|
|
12492
12709
|
}
|
|
12493
12710
|
}
|
|
12494
|
-
var Class$0 = $TS($S($EXPECT($
|
|
12711
|
+
var Class$0 = $TS($S($EXPECT($L103, fail, 'Class "class"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12495
12712
|
return { $loc, token: $1 };
|
|
12496
12713
|
});
|
|
12497
12714
|
function Class(state) {
|
|
@@ -12591,7 +12808,7 @@ ${input.slice(result.pos)}
|
|
|
12591
12808
|
return result;
|
|
12592
12809
|
}
|
|
12593
12810
|
}
|
|
12594
|
-
var CoffeeSubstitutionStart$0 = $TV($EXPECT($
|
|
12811
|
+
var CoffeeSubstitutionStart$0 = $TV($EXPECT($L104, fail, 'CoffeeSubstitutionStart "#{"'), function($skip, $loc, $0, $1) {
|
|
12595
12812
|
return { $loc, token: "${" };
|
|
12596
12813
|
});
|
|
12597
12814
|
function CoffeeSubstitutionStart(state) {
|
|
@@ -12641,7 +12858,7 @@ ${input.slice(result.pos)}
|
|
|
12641
12858
|
return result;
|
|
12642
12859
|
}
|
|
12643
12860
|
}
|
|
12644
|
-
var Comma$0 = $TV($EXPECT($
|
|
12861
|
+
var Comma$0 = $TV($EXPECT($L105, fail, 'Comma ","'), function($skip, $loc, $0, $1) {
|
|
12645
12862
|
return { $loc, token: $1 };
|
|
12646
12863
|
});
|
|
12647
12864
|
function Comma(state) {
|
|
@@ -12666,7 +12883,7 @@ ${input.slice(result.pos)}
|
|
|
12666
12883
|
return result;
|
|
12667
12884
|
}
|
|
12668
12885
|
}
|
|
12669
|
-
var ConstructorShorthand$0 = $TV($EXPECT($
|
|
12886
|
+
var ConstructorShorthand$0 = $TV($EXPECT($L96, fail, 'ConstructorShorthand "@"'), function($skip, $loc, $0, $1) {
|
|
12670
12887
|
return { $loc, token: "constructor" };
|
|
12671
12888
|
});
|
|
12672
12889
|
function ConstructorShorthand(state) {
|
|
@@ -12691,7 +12908,7 @@ ${input.slice(result.pos)}
|
|
|
12691
12908
|
return result;
|
|
12692
12909
|
}
|
|
12693
12910
|
}
|
|
12694
|
-
var Declare$0 = $TS($S($EXPECT($
|
|
12911
|
+
var Declare$0 = $TS($S($EXPECT($L106, fail, 'Declare "declare"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12695
12912
|
return { $loc, token: $1 };
|
|
12696
12913
|
});
|
|
12697
12914
|
function Declare(state) {
|
|
@@ -12716,7 +12933,7 @@ ${input.slice(result.pos)}
|
|
|
12716
12933
|
return result;
|
|
12717
12934
|
}
|
|
12718
12935
|
}
|
|
12719
|
-
var Default$0 = $TS($S($EXPECT($
|
|
12936
|
+
var Default$0 = $TS($S($EXPECT($L107, fail, 'Default "default"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12720
12937
|
return { $loc, token: $1 };
|
|
12721
12938
|
});
|
|
12722
12939
|
function Default(state) {
|
|
@@ -12741,7 +12958,7 @@ ${input.slice(result.pos)}
|
|
|
12741
12958
|
return result;
|
|
12742
12959
|
}
|
|
12743
12960
|
}
|
|
12744
|
-
var Delete$0 = $TS($S($EXPECT($
|
|
12961
|
+
var Delete$0 = $TS($S($EXPECT($L108, fail, 'Delete "delete"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12745
12962
|
return { $loc, token: $1 };
|
|
12746
12963
|
});
|
|
12747
12964
|
function Delete(state) {
|
|
@@ -12766,7 +12983,7 @@ ${input.slice(result.pos)}
|
|
|
12766
12983
|
return result;
|
|
12767
12984
|
}
|
|
12768
12985
|
}
|
|
12769
|
-
var Do$0 = $TS($S($EXPECT($
|
|
12986
|
+
var Do$0 = $TS($S($EXPECT($L109, fail, 'Do "do"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12770
12987
|
return { $loc, token: $1 };
|
|
12771
12988
|
});
|
|
12772
12989
|
function Do(state) {
|
|
@@ -12816,7 +13033,7 @@ ${input.slice(result.pos)}
|
|
|
12816
13033
|
return result;
|
|
12817
13034
|
}
|
|
12818
13035
|
}
|
|
12819
|
-
var DotDot$0 = $TV($EXPECT($
|
|
13036
|
+
var DotDot$0 = $TV($EXPECT($L110, fail, 'DotDot ".."'), function($skip, $loc, $0, $1) {
|
|
12820
13037
|
return { $loc, token: $1 };
|
|
12821
13038
|
});
|
|
12822
13039
|
function DotDot(state) {
|
|
@@ -12841,7 +13058,7 @@ ${input.slice(result.pos)}
|
|
|
12841
13058
|
return result;
|
|
12842
13059
|
}
|
|
12843
13060
|
}
|
|
12844
|
-
var DotDotDot$0 = $TV($EXPECT($
|
|
13061
|
+
var DotDotDot$0 = $TV($EXPECT($L111, fail, 'DotDotDot "..."'), function($skip, $loc, $0, $1) {
|
|
12845
13062
|
return { $loc, token: $1 };
|
|
12846
13063
|
});
|
|
12847
13064
|
function DotDotDot(state) {
|
|
@@ -12866,7 +13083,7 @@ ${input.slice(result.pos)}
|
|
|
12866
13083
|
return result;
|
|
12867
13084
|
}
|
|
12868
13085
|
}
|
|
12869
|
-
var DoubleColon$0 = $TV($EXPECT($
|
|
13086
|
+
var DoubleColon$0 = $TV($EXPECT($L112, fail, 'DoubleColon "::"'), function($skip, $loc, $0, $1) {
|
|
12870
13087
|
return { $loc, token: $1 };
|
|
12871
13088
|
});
|
|
12872
13089
|
function DoubleColon(state) {
|
|
@@ -12891,7 +13108,7 @@ ${input.slice(result.pos)}
|
|
|
12891
13108
|
return result;
|
|
12892
13109
|
}
|
|
12893
13110
|
}
|
|
12894
|
-
var DoubleQuote$0 = $TV($EXPECT($
|
|
13111
|
+
var DoubleQuote$0 = $TV($EXPECT($L113, fail, 'DoubleQuote "\\\\\\""'), function($skip, $loc, $0, $1) {
|
|
12895
13112
|
return { $loc, token: $1 };
|
|
12896
13113
|
});
|
|
12897
13114
|
function DoubleQuote(state) {
|
|
@@ -12916,7 +13133,7 @@ ${input.slice(result.pos)}
|
|
|
12916
13133
|
return result;
|
|
12917
13134
|
}
|
|
12918
13135
|
}
|
|
12919
|
-
var Else$0 = $TS($S($EXPECT($
|
|
13136
|
+
var Else$0 = $TS($S($EXPECT($L114, fail, 'Else "else"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12920
13137
|
return { $loc, token: $1 };
|
|
12921
13138
|
});
|
|
12922
13139
|
function Else(state) {
|
|
@@ -12966,7 +13183,7 @@ ${input.slice(result.pos)}
|
|
|
12966
13183
|
return result;
|
|
12967
13184
|
}
|
|
12968
13185
|
}
|
|
12969
|
-
var Export$0 = $TS($S($EXPECT($
|
|
13186
|
+
var Export$0 = $TS($S($EXPECT($L115, fail, 'Export "export"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12970
13187
|
return { $loc, token: $1 };
|
|
12971
13188
|
});
|
|
12972
13189
|
function Export(state) {
|
|
@@ -12991,7 +13208,7 @@ ${input.slice(result.pos)}
|
|
|
12991
13208
|
return result;
|
|
12992
13209
|
}
|
|
12993
13210
|
}
|
|
12994
|
-
var Extends$0 = $TS($S($EXPECT($
|
|
13211
|
+
var Extends$0 = $TS($S($EXPECT($L116, fail, 'Extends "extends"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
12995
13212
|
return { $loc, token: $1 };
|
|
12996
13213
|
});
|
|
12997
13214
|
function Extends(state) {
|
|
@@ -13016,6 +13233,31 @@ ${input.slice(result.pos)}
|
|
|
13016
13233
|
return result;
|
|
13017
13234
|
}
|
|
13018
13235
|
}
|
|
13236
|
+
var Finally$0 = $TS($S($EXPECT($L117, fail, 'Finally "finally"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
13237
|
+
return { $loc, token: $1 };
|
|
13238
|
+
});
|
|
13239
|
+
function Finally(state) {
|
|
13240
|
+
let eventData;
|
|
13241
|
+
if (state.events) {
|
|
13242
|
+
const result = state.events.enter?.("Finally", state);
|
|
13243
|
+
if (result) {
|
|
13244
|
+
if (result.cache)
|
|
13245
|
+
return result.cache;
|
|
13246
|
+
eventData = result.data;
|
|
13247
|
+
}
|
|
13248
|
+
}
|
|
13249
|
+
if (state.tokenize) {
|
|
13250
|
+
const result = $TOKEN("Finally", state, Finally$0(state));
|
|
13251
|
+
if (state.events)
|
|
13252
|
+
state.events.exit?.("Finally", state, result, eventData);
|
|
13253
|
+
return result;
|
|
13254
|
+
} else {
|
|
13255
|
+
const result = Finally$0(state);
|
|
13256
|
+
if (state.events)
|
|
13257
|
+
state.events.exit?.("Finally", state, result, eventData);
|
|
13258
|
+
return result;
|
|
13259
|
+
}
|
|
13260
|
+
}
|
|
13019
13261
|
var For$0 = $TS($S($EXPECT($L118, fail, 'For "for"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
13020
13262
|
return { $loc, token: $1 };
|
|
13021
13263
|
});
|
|
@@ -13366,7 +13608,7 @@ ${input.slice(result.pos)}
|
|
|
13366
13608
|
return result;
|
|
13367
13609
|
}
|
|
13368
13610
|
}
|
|
13369
|
-
var OpenBracket$0 = $TV($EXPECT($
|
|
13611
|
+
var OpenBracket$0 = $TV($EXPECT($L92, fail, 'OpenBracket "["'), function($skip, $loc, $0, $1) {
|
|
13370
13612
|
return { $loc, token: $1 };
|
|
13371
13613
|
});
|
|
13372
13614
|
function OpenBracket(state) {
|
|
@@ -13719,7 +13961,7 @@ ${input.slice(result.pos)}
|
|
|
13719
13961
|
var Static$0 = $TS($S($EXPECT($L139, fail, 'Static "static"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
13720
13962
|
return { $loc, token: $1 };
|
|
13721
13963
|
});
|
|
13722
|
-
var Static$1 = $TS($S($EXPECT($
|
|
13964
|
+
var Static$1 = $TS($S($EXPECT($L96, fail, 'Static "@"'), $N($C($EXPECT($L2, fail, 'Static "("'), $EXPECT($L96, fail, 'Static "@"')))), function($skip, $loc, $0, $1, $2) {
|
|
13723
13965
|
return { $loc, token: "static " };
|
|
13724
13966
|
});
|
|
13725
13967
|
function Static(state) {
|
|
@@ -14859,7 +15101,7 @@ ${input.slice(result.pos)}
|
|
|
14859
15101
|
return ["{", $1, "}"];
|
|
14860
15102
|
});
|
|
14861
15103
|
var JSXShorthandString$2 = StringLiteral;
|
|
14862
|
-
var JSXShorthandString$3 = $S(OpenBrace,
|
|
15104
|
+
var JSXShorthandString$3 = $S(OpenBrace, PostfixedExpression, $E(Whitespace), CloseBrace);
|
|
14863
15105
|
function JSXShorthandString(state) {
|
|
14864
15106
|
let eventData;
|
|
14865
15107
|
if (state.events) {
|
|
@@ -14929,7 +15171,7 @@ ${input.slice(result.pos)}
|
|
|
14929
15171
|
return result;
|
|
14930
15172
|
}
|
|
14931
15173
|
}
|
|
14932
|
-
var JSXAttributeValue$0 = $S(OpenBrace,
|
|
15174
|
+
var JSXAttributeValue$0 = $S(OpenBrace, PostfixedExpression, $E(Whitespace), CloseBrace);
|
|
14933
15175
|
var JSXAttributeValue$1 = JSXElement;
|
|
14934
15176
|
var JSXAttributeValue$2 = JSXFragment;
|
|
14935
15177
|
var JSXAttributeValue$3 = $TS($S(InsertInlineOpenBrace, InlineJSXAttributeValue, InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3) {
|
|
@@ -15120,7 +15362,7 @@ ${input.slice(result.pos)}
|
|
|
15120
15362
|
}
|
|
15121
15363
|
}
|
|
15122
15364
|
var InlineJSXCallExpression$0 = $S($EXPECT($L12, fail, 'InlineJSXCallExpression "super"'), ExplicitArguments);
|
|
15123
|
-
var InlineJSXCallExpression$1 = $S($EXPECT($L13, fail, 'InlineJSXCallExpression "import"'), OpenParen,
|
|
15365
|
+
var InlineJSXCallExpression$1 = $S($EXPECT($L13, fail, 'InlineJSXCallExpression "import"'), OpenParen, PostfixedExpression, __, CloseParen);
|
|
15124
15366
|
var InlineJSXCallExpression$2 = $TS($S(InlineJSXMemberExpression, $Q(InlineJSXCallExpressionRest)), function($skip, $loc, $0, $1, $2) {
|
|
15125
15367
|
if ($2.length)
|
|
15126
15368
|
return $0;
|
|
@@ -15542,7 +15784,7 @@ ${input.slice(result.pos)}
|
|
|
15542
15784
|
return result;
|
|
15543
15785
|
}
|
|
15544
15786
|
}
|
|
15545
|
-
var JSXChildExpression$0 = $S($E(Whitespace), $E($S(DotDotDot, $E(Whitespace))),
|
|
15787
|
+
var JSXChildExpression$0 = $S($E(Whitespace), $E($S(DotDotDot, $E(Whitespace))), PostfixedExpression);
|
|
15546
15788
|
function JSXChildExpression(state) {
|
|
15547
15789
|
let eventData;
|
|
15548
15790
|
if (state.events) {
|
|
@@ -16487,7 +16729,7 @@ ${input.slice(result.pos)}
|
|
|
16487
16729
|
return result;
|
|
16488
16730
|
}
|
|
16489
16731
|
}
|
|
16490
|
-
var TypeConditional$0 = $TS($S(TypeBinary, $E($S(__, $EXPECT($
|
|
16732
|
+
var TypeConditional$0 = $TS($S(TypeBinary, $E($S(__, $EXPECT($L116, fail, 'TypeConditional "extends"'), NonIdContinue, Type, $E($S(__, QuestionMark, Type, __, Colon, Type))))), function($skip, $loc, $0, $1, $2) {
|
|
16491
16733
|
if ($2)
|
|
16492
16734
|
return $0;
|
|
16493
16735
|
return $1;
|
|
@@ -16646,7 +16888,7 @@ ${input.slice(result.pos)}
|
|
|
16646
16888
|
return result;
|
|
16647
16889
|
}
|
|
16648
16890
|
}
|
|
16649
|
-
var FunctionType$0 = $TS($S(Parameters, __,
|
|
16891
|
+
var FunctionType$0 = $TS($S(Parameters, __, TypeArrowFunction, $E(Type)), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
16650
16892
|
var type = $4;
|
|
16651
16893
|
if (type) {
|
|
16652
16894
|
return $0;
|
|
@@ -16675,6 +16917,34 @@ ${input.slice(result.pos)}
|
|
|
16675
16917
|
return result;
|
|
16676
16918
|
}
|
|
16677
16919
|
}
|
|
16920
|
+
var TypeArrowFunction$0 = $TV($EXPECT($L7, fail, 'TypeArrowFunction "=>"'), function($skip, $loc, $0, $1) {
|
|
16921
|
+
return { $loc, token: "=>" };
|
|
16922
|
+
});
|
|
16923
|
+
var TypeArrowFunction$1 = $TV($EXPECT($L20, fail, 'TypeArrowFunction "->"'), function($skip, $loc, $0, $1) {
|
|
16924
|
+
return { $loc, token: "=>" };
|
|
16925
|
+
});
|
|
16926
|
+
function TypeArrowFunction(state) {
|
|
16927
|
+
let eventData;
|
|
16928
|
+
if (state.events) {
|
|
16929
|
+
const result = state.events.enter?.("TypeArrowFunction", state);
|
|
16930
|
+
if (result) {
|
|
16931
|
+
if (result.cache)
|
|
16932
|
+
return result.cache;
|
|
16933
|
+
eventData = result.data;
|
|
16934
|
+
}
|
|
16935
|
+
}
|
|
16936
|
+
if (state.tokenize) {
|
|
16937
|
+
const result = $TOKEN("TypeArrowFunction", state, TypeArrowFunction$0(state) || TypeArrowFunction$1(state));
|
|
16938
|
+
if (state.events)
|
|
16939
|
+
state.events.exit?.("TypeArrowFunction", state, result, eventData);
|
|
16940
|
+
return result;
|
|
16941
|
+
} else {
|
|
16942
|
+
const result = TypeArrowFunction$0(state) || TypeArrowFunction$1(state);
|
|
16943
|
+
if (state.events)
|
|
16944
|
+
state.events.exit?.("TypeArrowFunction", state, result, eventData);
|
|
16945
|
+
return result;
|
|
16946
|
+
}
|
|
16947
|
+
}
|
|
16678
16948
|
var TypeArguments$0 = $TS($S($EXPECT($L128, fail, 'TypeArguments "<"'), $P(TypeArgument), __, $EXPECT($L29, fail, 'TypeArguments ">"')), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
16679
16949
|
return { ts: true, children: $0 };
|
|
16680
16950
|
});
|
|
@@ -16800,7 +17070,7 @@ ${input.slice(result.pos)}
|
|
|
16800
17070
|
return result;
|
|
16801
17071
|
}
|
|
16802
17072
|
}
|
|
16803
|
-
var TypeConstraint$0 = $S(__, $EXPECT($
|
|
17073
|
+
var TypeConstraint$0 = $S(__, $EXPECT($L116, fail, 'TypeConstraint "extends"'), NonIdContinue, Type);
|
|
16804
17074
|
function TypeConstraint(state) {
|
|
16805
17075
|
let eventData;
|
|
16806
17076
|
if (state.events) {
|
|
@@ -18331,10 +18601,11 @@ ${input.slice(result.pos)}
|
|
|
18331
18601
|
children.push(block);
|
|
18332
18602
|
if (!module.isWhitespaceOrEmpty(ws))
|
|
18333
18603
|
children.push(ws);
|
|
18334
|
-
|
|
18335
|
-
|
|
18336
|
-
block
|
|
18337
|
-
}
|
|
18604
|
+
post = { ...post, children, block };
|
|
18605
|
+
if (post.type === "IfStatement") {
|
|
18606
|
+
post.then = block;
|
|
18607
|
+
}
|
|
18608
|
+
return post;
|
|
18338
18609
|
};
|
|
18339
18610
|
function expressionizeIteration(exp) {
|
|
18340
18611
|
const resultsRef = {
|
|
@@ -18407,9 +18678,9 @@ ${input.slice(result.pos)}
|
|
|
18407
18678
|
insertPush(exp.expressions[exp.expressions.length - 1], ref);
|
|
18408
18679
|
return;
|
|
18409
18680
|
case "IfStatement":
|
|
18410
|
-
insertPush(exp.
|
|
18411
|
-
if (exp.
|
|
18412
|
-
insertPush(exp.
|
|
18681
|
+
insertPush(exp.then, ref);
|
|
18682
|
+
if (exp.else)
|
|
18683
|
+
insertPush(exp.else[2], ref);
|
|
18413
18684
|
else
|
|
18414
18685
|
exp.children.push([" else {\n", indent, ref, ".push(undefined)\n", indent, "}"]);
|
|
18415
18686
|
return;
|
|
@@ -18465,7 +18736,9 @@ ${input.slice(result.pos)}
|
|
|
18465
18736
|
}
|
|
18466
18737
|
if (!Array.isArray(node))
|
|
18467
18738
|
return;
|
|
18468
|
-
const [, exp] = node;
|
|
18739
|
+
const [, exp, semi] = node;
|
|
18740
|
+
if (semi?.type === "SemicolonDelimiter")
|
|
18741
|
+
return;
|
|
18469
18742
|
let indent = node[0];
|
|
18470
18743
|
if (Array.isArray(indent))
|
|
18471
18744
|
indent = indent[indent.length - 1];
|
|
@@ -18488,9 +18761,9 @@ ${input.slice(result.pos)}
|
|
|
18488
18761
|
insertReturn(exp.expressions[exp.expressions.length - 1]);
|
|
18489
18762
|
return;
|
|
18490
18763
|
case "IfStatement":
|
|
18491
|
-
insertReturn(exp.
|
|
18492
|
-
if (exp.
|
|
18493
|
-
insertReturn(exp.
|
|
18764
|
+
insertReturn(exp.then);
|
|
18765
|
+
if (exp.else)
|
|
18766
|
+
insertReturn(exp.else[2]);
|
|
18494
18767
|
else
|
|
18495
18768
|
exp.children.push(["\n", indent, wrapWithReturn()]);
|
|
18496
18769
|
return;
|
|
@@ -18551,6 +18824,14 @@ ${input.slice(result.pos)}
|
|
|
18551
18824
|
const op = expandedOps[i];
|
|
18552
18825
|
if (op.special) {
|
|
18553
18826
|
let [a, wsOp, op2, wsB, b] = expandedOps.slice(i - 2, i + 3);
|
|
18827
|
+
if (op2.token === "instanceof" && b.type === "Literal" && b.children?.[0]?.type === "StringLiteral") {
|
|
18828
|
+
a = ["typeof ", module.makeLeftHandSideExpression(a)];
|
|
18829
|
+
if (op2.negated) {
|
|
18830
|
+
op2 = { ...op2, token: "!==", negated: false };
|
|
18831
|
+
} else {
|
|
18832
|
+
op2 = { ...op2, token: "===" };
|
|
18833
|
+
}
|
|
18834
|
+
}
|
|
18554
18835
|
if (op2.asConst) {
|
|
18555
18836
|
a = module.makeAsConst(a);
|
|
18556
18837
|
b = module.makeAsConst(b);
|
|
@@ -18591,7 +18872,7 @@ ${input.slice(result.pos)}
|
|
|
18591
18872
|
return expandedOps;
|
|
18592
18873
|
};
|
|
18593
18874
|
module.expandChainedComparisons = function([first, binops]) {
|
|
18594
|
-
const relationalOps = ["==", "===", "!=", "!==", "<", "<=", ">", ">=", "in"
|
|
18875
|
+
const relationalOps = ["==", "===", "!=", "!==", "<", "<=", ">", ">=", "in"];
|
|
18595
18876
|
const lowerPrecedenceOps = ["??", "&&", "||", "&", "|", "^"];
|
|
18596
18877
|
let results = [];
|
|
18597
18878
|
let i = 0;
|
|
@@ -19152,7 +19433,7 @@ ${input.slice(result.pos)}
|
|
|
19152
19433
|
break;
|
|
19153
19434
|
case "Literal":
|
|
19154
19435
|
case "StringLiteral":
|
|
19155
|
-
case
|
|
19436
|
+
case "NumericLiteral":
|
|
19156
19437
|
conditions.push([name, " in ", ref]);
|
|
19157
19438
|
subRef = [ref, "[", name, "]"];
|
|
19158
19439
|
break;
|
|
@@ -19215,7 +19496,8 @@ ${input.slice(result.pos)}
|
|
|
19215
19496
|
switch (name.type) {
|
|
19216
19497
|
case "ComputedPropertyName":
|
|
19217
19498
|
case "Literal":
|
|
19218
|
-
case
|
|
19499
|
+
case "StringLiteral":
|
|
19500
|
+
case "NumericLiteral":
|
|
19219
19501
|
return {
|
|
19220
19502
|
...p,
|
|
19221
19503
|
children: [ws, name, ": ", match, sep]
|
|
@@ -19338,7 +19620,9 @@ ${input.slice(result.pos)}
|
|
|
19338
19620
|
const e = i < l - 1 ? ["\nelse "] : [];
|
|
19339
19621
|
prev.push({
|
|
19340
19622
|
type: "IfStatement",
|
|
19341
|
-
children: ["if", condition, block, ...e, next]
|
|
19623
|
+
children: ["if", condition, block, ...e, next],
|
|
19624
|
+
then: block,
|
|
19625
|
+
else: e
|
|
19342
19626
|
});
|
|
19343
19627
|
prev = next;
|
|
19344
19628
|
});
|
|
@@ -20254,7 +20538,7 @@ ${input.slice(result.pos)}
|
|
|
20254
20538
|
var uncacheable;
|
|
20255
20539
|
({ parse } = import_parser.default);
|
|
20256
20540
|
({ SourceMap: SourceMap2, base64Encode: base64Encode2 } = util_exports);
|
|
20257
|
-
uncacheable = /* @__PURE__ */ new Set(["ActualAssignment", "ApplicationStart", "Arguments", "ArgumentsWithTrailingMemberExpressions", "ArrowFunction", "ArrowFunctionTail", "AssignmentExpression", "AssignmentExpressionTail", "BinaryOpExpression", "BinaryOpRHS", "BracedBlock", "BracedObjectLiteralContent", "BracedOrEmptyBlock", "CallExpression", "CallExpressionRest", "CoffeeCommentEnabled", "CommaDelimiter", "ConditionalExpression", "Declaration", "Debugger", "ElseClause", "Expression", "ExpressionStatement", "ExpressionWithIndentedApplicationSuppressed", "ExtendedExpression", "FatArrowBody", "FunctionDeclaration", "FunctionExpression", "HoistableDeclaration", "ImplicitArguments", "ImplicitInlineObjectPropertyDelimiter", "ImplicitNestedBlock", "IndentedApplicationAllowed", "IndentedFurther", "IndentedJSXChildExpression", "InlineObjectLiteral", "InsertIndent", "JSXChild", "JSXChildren", "JSXElement", "JSXFragment", "JSXImplicitFragment", "JSXMixedChildren", "JSXNested", "JSXNestedChildren", "JSXOptionalClosingElement", "JSXOptionalClosingFragment", "JSXTag", "LeftHandSideExpression", "MemberExpression", "MemberExpressionRest", "Nested", "NestedBindingElement", "NestedBindingElements", "NestedBlockExpression", "NestedBlockExpression", "NestedBlockStatement", "NestedBlockStatements", "NestedElement", "NestedElementList", "NestedImplicitObjectLiteral", "NestedImplicitPropertyDefinition", "NestedImplicitPropertyDefinitions", "NestedInterfaceProperty", "NestedJSXChildExpression", "NestedObject", "NestedPropertyDefinitions", "NonSuppressedTrailingMemberExpressions", "ObjectLiteral", "PopIndent", "PrimaryExpression", "PushIndent", "PushJSXOpeningElement", "PushJSXOpeningFragment", "Samedent", "ShortCircuitExpression", "SingleLineAssignmentExpression", "SingleLineComment", "SingleLineStatements", "SnugNamedProperty", "Statement", "StatementListItem", "SuppressIndentedApplication", "SuppressTrailingMemberProperty", "ThinArrowFunction", "TrackIndented", "TrailingMemberExpressions", "TrailingMemberPropertyAllowed", "TypedJSXElement", "TypedJSXFragment", "UnaryExpression", "UpdateExpression"]);
|
|
20541
|
+
uncacheable = /* @__PURE__ */ new Set(["ActualAssignment", "ApplicationStart", "Arguments", "ArgumentsWithTrailingMemberExpressions", "ArrowFunction", "ArrowFunctionTail", "AssignmentExpression", "AssignmentExpressionTail", "BinaryOpExpression", "BinaryOpRHS", "BracedBlock", "BracedObjectLiteralContent", "BracedOrEmptyBlock", "CallExpression", "CallExpressionRest", "CoffeeCommentEnabled", "CommaDelimiter", "ConditionalExpression", "Declaration", "Debugger", "ElseClause", "Expression", "ExpressionStatement", "ExpressionWithIndentedApplicationSuppressed", "ExtendedExpression", "FatArrowBody", "FunctionDeclaration", "FunctionExpression", "HoistableDeclaration", "ImplicitArguments", "ImplicitInlineObjectPropertyDelimiter", "ImplicitNestedBlock", "IndentedApplicationAllowed", "IndentedFurther", "IndentedJSXChildExpression", "InlineObjectLiteral", "InsertIndent", "JSXChild", "JSXChildren", "JSXElement", "JSXFragment", "JSXImplicitFragment", "JSXMixedChildren", "JSXNested", "JSXNestedChildren", "JSXOptionalClosingElement", "JSXOptionalClosingFragment", "JSXTag", "LeftHandSideExpression", "MemberExpression", "MemberExpressionRest", "Nested", "NestedBindingElement", "NestedBindingElements", "NestedBlockExpression", "NestedBlockExpression", "NestedBlockStatement", "NestedBlockStatements", "NestedElement", "NestedElementList", "NestedImplicitObjectLiteral", "NestedImplicitPropertyDefinition", "NestedImplicitPropertyDefinitions", "NestedInterfaceProperty", "NestedJSXChildExpression", "NestedObject", "NestedPropertyDefinitions", "NonSingleBracedBlock", "NonSuppressedTrailingMemberExpressions", "ObjectLiteral", "PopIndent", "PostfixedExpression", "PostfixedStatement", "PrimaryExpression", "PushIndent", "PushJSXOpeningElement", "PushJSXOpeningFragment", "RHS", "Samedent", "ShortCircuitExpression", "SingleLineAssignmentExpression", "SingleLineComment", "SingleLineStatements", "SnugNamedProperty", "Statement", "StatementListItem", "SuffixedExpression", "SuffixedStatement", "SuppressIndentedApplication", "SuppressTrailingMemberProperty", "ThinArrowFunction", "TrackIndented", "TrailingMemberExpressions", "TrailingMemberPropertyAllowed", "TypedJSXElement", "TypedJSXFragment", "UnaryExpression", "UpdateExpression"]);
|
|
20258
20542
|
var compile = function(src, options) {
|
|
20259
20543
|
var ast, code, events, filename, ref, result, sm, srcMapJSON;
|
|
20260
20544
|
if (!options) {
|