@danielx/civet 0.6.19 → 0.6.21
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 +580 -658
- package/dist/main.js +580 -658
- package/dist/main.mjs +580 -658
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -343,11 +343,7 @@ var require_lib = __commonJS({
|
|
|
343
343
|
exp.children.splice(i, 1, ...wrapIIFE(exp.children, exp.async));
|
|
344
344
|
return;
|
|
345
345
|
}
|
|
346
|
-
const resultsRef =
|
|
347
|
-
type: "Ref",
|
|
348
|
-
base: "results",
|
|
349
|
-
id: "results"
|
|
350
|
-
};
|
|
346
|
+
const resultsRef = makeRef("results");
|
|
351
347
|
insertPush(exp.block, resultsRef);
|
|
352
348
|
exp.children.splice(
|
|
353
349
|
i,
|
|
@@ -425,10 +421,7 @@ var require_lib = __commonJS({
|
|
|
425
421
|
const parts = [];
|
|
426
422
|
let hoistDec, refAssignment;
|
|
427
423
|
if (prefix.length > 1) {
|
|
428
|
-
const ref =
|
|
429
|
-
type: "Ref",
|
|
430
|
-
base: "ref"
|
|
431
|
-
};
|
|
424
|
+
const ref = makeRef();
|
|
432
425
|
hoistDec = {
|
|
433
426
|
type: "Declaration",
|
|
434
427
|
children: ["let ", ref],
|
|
@@ -530,11 +523,7 @@ var require_lib = __commonJS({
|
|
|
530
523
|
}
|
|
531
524
|
return;
|
|
532
525
|
}
|
|
533
|
-
const resultsRef =
|
|
534
|
-
type: "Ref",
|
|
535
|
-
base: "results",
|
|
536
|
-
id: "results"
|
|
537
|
-
};
|
|
526
|
+
const resultsRef = makeRef("results");
|
|
538
527
|
const declaration = {
|
|
539
528
|
type: "Declaration",
|
|
540
529
|
children: ["const ", resultsRef, "=[];"]
|
|
@@ -1039,13 +1028,123 @@ var require_lib = __commonJS({
|
|
|
1039
1028
|
if (target.token)
|
|
1040
1029
|
return target.token.match(/^ ?/)[0];
|
|
1041
1030
|
}
|
|
1031
|
+
function processForInOf($0) {
|
|
1032
|
+
let [awaits, each, open, declaration, declaration2, ws, inOf, exp, step, close] = $0;
|
|
1033
|
+
if (exp.type === "RangeExpression" && inOf.token === "of" && !declaration2) {
|
|
1034
|
+
return forRange(open, declaration, exp, step, close);
|
|
1035
|
+
} else if (step) {
|
|
1036
|
+
throw new Error("for..of/in cannot use 'by' except with range literals");
|
|
1037
|
+
}
|
|
1038
|
+
let eachError;
|
|
1039
|
+
let hoistDec, blockPrefix = [];
|
|
1040
|
+
if (each) {
|
|
1041
|
+
if (inOf.token === "of") {
|
|
1042
|
+
const counterRef = makeRef("i");
|
|
1043
|
+
const lenRef = makeRef("len");
|
|
1044
|
+
const expRef = maybeRef(exp);
|
|
1045
|
+
const increment = "++";
|
|
1046
|
+
let indexAssignment, assignmentNames = [...declaration.names];
|
|
1047
|
+
if (declaration2) {
|
|
1048
|
+
const [, , ws22, decl22] = declaration2;
|
|
1049
|
+
blockPrefix.push(["", [
|
|
1050
|
+
insertTrimmingSpace(ws22, ""),
|
|
1051
|
+
decl22,
|
|
1052
|
+
" = ",
|
|
1053
|
+
counterRef
|
|
1054
|
+
], ";"]);
|
|
1055
|
+
assignmentNames.push(...decl22.names);
|
|
1056
|
+
}
|
|
1057
|
+
const expRefDec = expRef !== exp ? [insertTrimmingSpace(expRef, " "), " = ", insertTrimmingSpace(exp, ""), ", "] : [];
|
|
1058
|
+
blockPrefix.push(["", {
|
|
1059
|
+
type: "AssignmentExpression",
|
|
1060
|
+
children: [declaration, " = ", insertTrimmingSpace(expRef, ""), "[", counterRef, "]"],
|
|
1061
|
+
names: assignmentNames
|
|
1062
|
+
}, ";"]);
|
|
1063
|
+
declaration = {
|
|
1064
|
+
type: "Declaration",
|
|
1065
|
+
children: ["let ", ...expRefDec, counterRef, " = 0, ", lenRef, " = ", insertTrimmingSpace(expRef, ""), ".length"],
|
|
1066
|
+
names: []
|
|
1067
|
+
};
|
|
1068
|
+
const condition = [counterRef, " < ", lenRef, "; "];
|
|
1069
|
+
const children = [open, declaration, "; ", condition, counterRef, increment, close];
|
|
1070
|
+
return { declaration, children, blockPrefix };
|
|
1071
|
+
} else {
|
|
1072
|
+
eachError = {
|
|
1073
|
+
type: "Error",
|
|
1074
|
+
message: "'each' is only meaningful in for..of loops"
|
|
1075
|
+
};
|
|
1076
|
+
}
|
|
1077
|
+
}
|
|
1078
|
+
if (!declaration2) {
|
|
1079
|
+
return {
|
|
1080
|
+
declaration,
|
|
1081
|
+
children: [awaits, eachError, open, declaration, ws, inOf, exp, step, close]
|
|
1082
|
+
};
|
|
1083
|
+
}
|
|
1084
|
+
const [, , ws2, decl2] = declaration2;
|
|
1085
|
+
switch (inOf.token) {
|
|
1086
|
+
case "of": {
|
|
1087
|
+
const counterRef = makeRef("i");
|
|
1088
|
+
hoistDec = {
|
|
1089
|
+
type: "Declaration",
|
|
1090
|
+
children: ["let ", counterRef, " = 0"],
|
|
1091
|
+
names: []
|
|
1092
|
+
};
|
|
1093
|
+
blockPrefix.push(["", {
|
|
1094
|
+
type: "Declaration",
|
|
1095
|
+
children: [insertTrimmingSpace(ws2, ""), decl2, " = ", counterRef, "++"],
|
|
1096
|
+
names: decl2.names
|
|
1097
|
+
}, ";"]);
|
|
1098
|
+
break;
|
|
1099
|
+
}
|
|
1100
|
+
case "in": {
|
|
1101
|
+
const expRef = maybeRef(exp);
|
|
1102
|
+
if (expRef !== exp) {
|
|
1103
|
+
hoistDec = {
|
|
1104
|
+
type: "Declaration",
|
|
1105
|
+
children: ["let ", expRef],
|
|
1106
|
+
names: []
|
|
1107
|
+
};
|
|
1108
|
+
exp = {
|
|
1109
|
+
type: "AssignmentExpression",
|
|
1110
|
+
children: [" ", expRef, " =", exp]
|
|
1111
|
+
};
|
|
1112
|
+
}
|
|
1113
|
+
let { binding } = declaration;
|
|
1114
|
+
if (binding?.type !== "Identifier") {
|
|
1115
|
+
const keyRef = makeRef("key");
|
|
1116
|
+
blockPrefix.push(["", [
|
|
1117
|
+
declaration,
|
|
1118
|
+
" = ",
|
|
1119
|
+
keyRef
|
|
1120
|
+
], ";"]);
|
|
1121
|
+
declaration = {
|
|
1122
|
+
type: "ForDeclaration",
|
|
1123
|
+
binding: binding = keyRef,
|
|
1124
|
+
children: ["const ", keyRef],
|
|
1125
|
+
names: []
|
|
1126
|
+
};
|
|
1127
|
+
}
|
|
1128
|
+
blockPrefix.push(["", {
|
|
1129
|
+
type: "Declaration",
|
|
1130
|
+
children: [insertTrimmingSpace(ws2, ""), decl2, " = ", insertTrimmingSpace(expRef, ""), "[", insertTrimmingSpace(binding, ""), "]"],
|
|
1131
|
+
names: decl2.names
|
|
1132
|
+
}, ";"]);
|
|
1133
|
+
break;
|
|
1134
|
+
}
|
|
1135
|
+
default:
|
|
1136
|
+
throw new Error(`for item, index must use 'of' or 'in' instead of '${inOf.token}'`);
|
|
1137
|
+
}
|
|
1138
|
+
return {
|
|
1139
|
+
declaration,
|
|
1140
|
+
children: [awaits, eachError, open, declaration, ws, inOf, exp, step, close],
|
|
1141
|
+
blockPrefix,
|
|
1142
|
+
hoistDec
|
|
1143
|
+
};
|
|
1144
|
+
}
|
|
1042
1145
|
function forRange(open, forDeclaration, range, stepExp, close) {
|
|
1043
1146
|
const { start, end, inclusive } = range;
|
|
1044
|
-
const counterRef =
|
|
1045
|
-
type: "Ref",
|
|
1046
|
-
base: "i",
|
|
1047
|
-
id: "i"
|
|
1048
|
-
};
|
|
1147
|
+
const counterRef = makeRef("i");
|
|
1049
1148
|
let stepRef;
|
|
1050
1149
|
if (stepExp) {
|
|
1051
1150
|
stepExp = insertTrimmingSpace(stepExp, "");
|
|
@@ -1063,11 +1162,7 @@ var require_lib = __commonJS({
|
|
|
1063
1162
|
} else if (start.type === "Literal" && end.type === "Literal") {
|
|
1064
1163
|
asc = literalValue(start) <= literalValue(end);
|
|
1065
1164
|
} else {
|
|
1066
|
-
ascRef =
|
|
1067
|
-
type: "Ref",
|
|
1068
|
-
base: "asc",
|
|
1069
|
-
id: "asc"
|
|
1070
|
-
};
|
|
1165
|
+
ascRef = makeRef("asc");
|
|
1071
1166
|
ascDec = [", ", ascRef, " = ", startRef, " <= ", endRef];
|
|
1072
1167
|
}
|
|
1073
1168
|
let varAssign = [], varLetAssign = varAssign, varLet = varAssign, blockPrefix;
|
|
@@ -1207,15 +1302,6 @@ var require_lib = __commonJS({
|
|
|
1207
1302
|
};
|
|
1208
1303
|
}
|
|
1209
1304
|
}
|
|
1210
|
-
function maybeRef(exp, base = "ref") {
|
|
1211
|
-
if (!needsRef(exp))
|
|
1212
|
-
return exp;
|
|
1213
|
-
return {
|
|
1214
|
-
type: "Ref",
|
|
1215
|
-
base,
|
|
1216
|
-
id: base
|
|
1217
|
-
};
|
|
1218
|
-
}
|
|
1219
1305
|
function modifyString(str) {
|
|
1220
1306
|
return str.replace(/(^.?|[^\\]{2})(\\\\)*\n/g, "$1$2\\n");
|
|
1221
1307
|
}
|
|
@@ -1311,13 +1397,20 @@ var require_lib = __commonJS({
|
|
|
1311
1397
|
case "Identifier":
|
|
1312
1398
|
case "Literal":
|
|
1313
1399
|
return;
|
|
1314
|
-
default:
|
|
1315
|
-
return {
|
|
1316
|
-
type: "Ref",
|
|
1317
|
-
base,
|
|
1318
|
-
id: base
|
|
1319
|
-
};
|
|
1320
1400
|
}
|
|
1401
|
+
return makeRef(base);
|
|
1402
|
+
}
|
|
1403
|
+
function makeRef(base = "ref") {
|
|
1404
|
+
return {
|
|
1405
|
+
type: "Ref",
|
|
1406
|
+
base,
|
|
1407
|
+
id: base
|
|
1408
|
+
};
|
|
1409
|
+
}
|
|
1410
|
+
function maybeRef(exp, base = "ref") {
|
|
1411
|
+
if (!needsRef(exp))
|
|
1412
|
+
return exp;
|
|
1413
|
+
return makeRef(base);
|
|
1321
1414
|
}
|
|
1322
1415
|
function processCoffeeInterpolation(s, parts, e, $loc) {
|
|
1323
1416
|
if (parts.length === 0 || parts.length === 1 && parts[0].token != null) {
|
|
@@ -1810,11 +1903,7 @@ var require_lib = __commonJS({
|
|
|
1810
1903
|
if (shared.length === 1)
|
|
1811
1904
|
return;
|
|
1812
1905
|
const refs = shared.map((p) => {
|
|
1813
|
-
const ref =
|
|
1814
|
-
type: "Ref",
|
|
1815
|
-
base: key,
|
|
1816
|
-
id: key
|
|
1817
|
-
};
|
|
1906
|
+
const ref = makeRef(key);
|
|
1818
1907
|
aliasBinding(p, ref);
|
|
1819
1908
|
return ref;
|
|
1820
1909
|
});
|
|
@@ -1848,7 +1937,7 @@ var require_lib = __commonJS({
|
|
|
1848
1937
|
if (expression.type === "ParenthesizedExpression") {
|
|
1849
1938
|
expression = expression.expression;
|
|
1850
1939
|
}
|
|
1851
|
-
let hoistDec, refAssignment = [], ref =
|
|
1940
|
+
let hoistDec, refAssignment = [], ref = maybeRef(expression, "m");
|
|
1852
1941
|
if (ref !== expression) {
|
|
1853
1942
|
hoistDec = {
|
|
1854
1943
|
type: "Declaration",
|
|
@@ -1974,7 +2063,7 @@ var require_lib = __commonJS({
|
|
|
1974
2063
|
arg.children.push(access);
|
|
1975
2064
|
break outer;
|
|
1976
2065
|
}
|
|
1977
|
-
usingRef =
|
|
2066
|
+
usingRef = makeRef();
|
|
1978
2067
|
initRef = {
|
|
1979
2068
|
type: "AssignmentExpression",
|
|
1980
2069
|
children: [usingRef, " = ", arg, ","]
|
|
@@ -2064,10 +2153,11 @@ var require_lib = __commonJS({
|
|
|
2064
2153
|
});
|
|
2065
2154
|
}
|
|
2066
2155
|
function processProgram(root, config, m, ReservedWord) {
|
|
2156
|
+
assert.equal(m.forbidBracedApplication.length, 1, "forbidBracedApplication");
|
|
2067
2157
|
assert.equal(m.forbidClassImplicitCall.length, 1, "forbidClassImplicitCall");
|
|
2068
2158
|
assert.equal(m.forbidIndentedApplication.length, 1, "forbidIndentedApplication");
|
|
2159
|
+
assert.equal(m.forbidNewlineBinaryOp.length, 1, "forbidNewlineBinaryOp");
|
|
2069
2160
|
assert.equal(m.forbidTrailingMemberProperty.length, 1, "forbidTrailingMemberProperty");
|
|
2070
|
-
assert.equal(m.forbidMultiLineImplicitObjectLiteral.length, 1, "forbidMultiLineImplicitObjectLiteral");
|
|
2071
2161
|
assert.equal(m.JSXTagStack.length, 0, "JSXTagStack should be empty");
|
|
2072
2162
|
addParentPointers(root);
|
|
2073
2163
|
const { expressions: statements } = root;
|
|
@@ -2248,11 +2338,7 @@ var require_lib = __commonJS({
|
|
|
2248
2338
|
);
|
|
2249
2339
|
if (!values.length)
|
|
2250
2340
|
return false;
|
|
2251
|
-
const ref =
|
|
2252
|
-
type: "Ref",
|
|
2253
|
-
base: "ret",
|
|
2254
|
-
id: "ret"
|
|
2255
|
-
};
|
|
2341
|
+
const ref = makeRef("ret");
|
|
2256
2342
|
let declared;
|
|
2257
2343
|
values.forEach((value) => {
|
|
2258
2344
|
value.children = [ref];
|
|
@@ -2581,13 +2667,15 @@ var require_lib = __commonJS({
|
|
|
2581
2667
|
makeAsConst,
|
|
2582
2668
|
makeEmptyBlock,
|
|
2583
2669
|
makeLeftHandSideExpression,
|
|
2670
|
+
makeRef,
|
|
2584
2671
|
maybeRef,
|
|
2585
2672
|
modifyString,
|
|
2586
2673
|
needsRef,
|
|
2674
|
+
processAssignmentDeclaration,
|
|
2587
2675
|
processBinaryOpExpression,
|
|
2588
2676
|
processCallMemberExpression,
|
|
2589
2677
|
processCoffeeInterpolation,
|
|
2590
|
-
|
|
2678
|
+
processForInOf,
|
|
2591
2679
|
processParams,
|
|
2592
2680
|
processProgram,
|
|
2593
2681
|
processReturnValue,
|
|
@@ -3191,10 +3279,8 @@ ${input.slice(result.pos)}
|
|
|
3191
3279
|
InlineObjectLiteral,
|
|
3192
3280
|
ImplicitInlineObjectPropertyDelimiter,
|
|
3193
3281
|
ObjectPropertyDelimiter,
|
|
3194
|
-
PropertyDefinitionList,
|
|
3195
3282
|
PropertyDefinition,
|
|
3196
3283
|
NamedProperty,
|
|
3197
|
-
ImplicitNamedProperty,
|
|
3198
3284
|
SnugNamedProperty,
|
|
3199
3285
|
PropertyName,
|
|
3200
3286
|
ComputedPropertyName,
|
|
@@ -3300,10 +3386,6 @@ ${input.slice(result.pos)}
|
|
|
3300
3386
|
AllowTrailingMemberProperty,
|
|
3301
3387
|
RestoreTrailingMemberProperty,
|
|
3302
3388
|
TrailingMemberPropertyAllowed,
|
|
3303
|
-
ForbidMultiLineImplicitObjectLiteral,
|
|
3304
|
-
AllowMultiLineImplicitObjectLiteral,
|
|
3305
|
-
RestoreMultiLineImplicitObjectLiteral,
|
|
3306
|
-
MultiLineImplicitObjectLiteralAllowed,
|
|
3307
3389
|
AllowNewlineBinaryOp,
|
|
3308
3390
|
ForbidNewlineBinaryOp,
|
|
3309
3391
|
RestoreNewlineBinaryOp,
|
|
@@ -3434,6 +3516,7 @@ ${input.slice(result.pos)}
|
|
|
3434
3516
|
DotDotDot,
|
|
3435
3517
|
DoubleColon,
|
|
3436
3518
|
DoubleQuote,
|
|
3519
|
+
Each,
|
|
3437
3520
|
Else,
|
|
3438
3521
|
Equals,
|
|
3439
3522
|
Export,
|
|
@@ -3537,6 +3620,7 @@ ${input.slice(result.pos)}
|
|
|
3537
3620
|
NestedJSXChildExpression,
|
|
3538
3621
|
TypeDeclaration,
|
|
3539
3622
|
TypeDeclarationRest,
|
|
3623
|
+
OptionalEquals,
|
|
3540
3624
|
TypeLexicalDeclaration,
|
|
3541
3625
|
TypeDeclarationBinding,
|
|
3542
3626
|
InterfaceExtendsClause,
|
|
@@ -3625,6 +3709,7 @@ ${input.slice(result.pos)}
|
|
|
3625
3709
|
InsertOpenBracket,
|
|
3626
3710
|
InsertCloseBracket,
|
|
3627
3711
|
InsertComma,
|
|
3712
|
+
InsertSpaceEquals,
|
|
3628
3713
|
InsertConst,
|
|
3629
3714
|
InsertLet,
|
|
3630
3715
|
InsertReadonly,
|
|
@@ -3652,13 +3737,13 @@ ${input.slice(result.pos)}
|
|
|
3652
3737
|
Init,
|
|
3653
3738
|
Indent,
|
|
3654
3739
|
TrackIndented,
|
|
3655
|
-
Samedent,
|
|
3656
|
-
IndentedFurther,
|
|
3657
|
-
NotDedented,
|
|
3658
|
-
Dedented,
|
|
3659
3740
|
PushIndent,
|
|
3660
3741
|
PopIndent,
|
|
3661
|
-
Nested
|
|
3742
|
+
Nested,
|
|
3743
|
+
IndentedFurther,
|
|
3744
|
+
IndentedAtLeast,
|
|
3745
|
+
NotDedented,
|
|
3746
|
+
Dedented
|
|
3662
3747
|
});
|
|
3663
3748
|
var $L0 = $L("");
|
|
3664
3749
|
var $L1 = $L("{");
|
|
@@ -3798,75 +3883,76 @@ ${input.slice(result.pos)}
|
|
|
3798
3883
|
var $L135 = $L("\u2026");
|
|
3799
3884
|
var $L136 = $L("::");
|
|
3800
3885
|
var $L137 = $L('"');
|
|
3801
|
-
var $L138 = $L("
|
|
3802
|
-
var $L139 = $L("
|
|
3803
|
-
var $L140 = $L("
|
|
3804
|
-
var $L141 = $L("
|
|
3805
|
-
var $L142 = $L("
|
|
3806
|
-
var $L143 = $L("
|
|
3807
|
-
var $L144 = $L("
|
|
3808
|
-
var $L145 = $L("
|
|
3809
|
-
var $L146 = $L("
|
|
3810
|
-
var $L147 = $L("
|
|
3811
|
-
var $L148 = $L("
|
|
3812
|
-
var $L149 = $L("
|
|
3813
|
-
var $L150 = $L("
|
|
3814
|
-
var $L151 = $L("
|
|
3815
|
-
var $L152 = $L("
|
|
3816
|
-
var $L153 = $L("
|
|
3817
|
-
var $L154 = $L("
|
|
3818
|
-
var $L155 = $L("
|
|
3819
|
-
var $L156 = $L("
|
|
3820
|
-
var $L157 = $L("
|
|
3821
|
-
var $L158 = $L("
|
|
3822
|
-
var $L159 = $L("
|
|
3823
|
-
var $L160 = $L("
|
|
3824
|
-
var $L161 = $L("
|
|
3825
|
-
var $L162 = $L("
|
|
3826
|
-
var $L163 = $L("
|
|
3827
|
-
var $L164 = $L("
|
|
3828
|
-
var $L165 = $L("
|
|
3829
|
-
var $L166 = $L("
|
|
3830
|
-
var $L167 = $L("
|
|
3831
|
-
var $L168 = $L("
|
|
3832
|
-
var $L169 = $L("
|
|
3833
|
-
var $L170 = $L("
|
|
3834
|
-
var $L171 = $L("
|
|
3835
|
-
var $L172 = $L("
|
|
3836
|
-
var $L173 = $L("
|
|
3837
|
-
var $L174 = $L("
|
|
3838
|
-
var $L175 = $L("
|
|
3839
|
-
var $L176 = $L("
|
|
3840
|
-
var $L177 = $L(
|
|
3841
|
-
var $L178 = $L("'
|
|
3842
|
-
var $L179 = $L("
|
|
3843
|
-
var $L180 = $L("
|
|
3844
|
-
var $L181 = $L("
|
|
3845
|
-
var $L182 = $L("
|
|
3846
|
-
var $L183 = $L("
|
|
3847
|
-
var $L184 = $L("
|
|
3848
|
-
var $L185 = $L("
|
|
3849
|
-
var $L186 = $L("
|
|
3850
|
-
var $L187 = $L("
|
|
3851
|
-
var $L188 = $L("
|
|
3852
|
-
var $L189 = $L("
|
|
3853
|
-
var $L190 = $L("
|
|
3854
|
-
var $L191 = $L("
|
|
3855
|
-
var $L192 = $L("
|
|
3856
|
-
var $L193 = $L("
|
|
3857
|
-
var $L194 = $L("
|
|
3858
|
-
var $L195 = $L("
|
|
3859
|
-
var $L196 = $L("
|
|
3860
|
-
var $L197 = $L("
|
|
3861
|
-
var $L198 = $L("
|
|
3862
|
-
var $L199 = $L("
|
|
3863
|
-
var $L200 = $L("
|
|
3864
|
-
var $L201 = $L("
|
|
3865
|
-
var $L202 = $L("
|
|
3866
|
-
var $L203 = $L("
|
|
3867
|
-
var $L204 = $L("
|
|
3868
|
-
var $L205 = $L("
|
|
3869
|
-
var $L206 = $L("
|
|
3886
|
+
var $L138 = $L("each");
|
|
3887
|
+
var $L139 = $L("else");
|
|
3888
|
+
var $L140 = $L("export");
|
|
3889
|
+
var $L141 = $L("extends");
|
|
3890
|
+
var $L142 = $L("finally");
|
|
3891
|
+
var $L143 = $L("for");
|
|
3892
|
+
var $L144 = $L("from");
|
|
3893
|
+
var $L145 = $L("function");
|
|
3894
|
+
var $L146 = $L("get");
|
|
3895
|
+
var $L147 = $L("set");
|
|
3896
|
+
var $L148 = $L("if");
|
|
3897
|
+
var $L149 = $L("in");
|
|
3898
|
+
var $L150 = $L("let");
|
|
3899
|
+
var $L151 = $L("const");
|
|
3900
|
+
var $L152 = $L("is");
|
|
3901
|
+
var $L153 = $L("loop");
|
|
3902
|
+
var $L154 = $L("new");
|
|
3903
|
+
var $L155 = $L("not");
|
|
3904
|
+
var $L156 = $L("<");
|
|
3905
|
+
var $L157 = $L("operator");
|
|
3906
|
+
var $L158 = $L("public");
|
|
3907
|
+
var $L159 = $L("private");
|
|
3908
|
+
var $L160 = $L("protected");
|
|
3909
|
+
var $L161 = $L("||>");
|
|
3910
|
+
var $L162 = $L("|\u25B7");
|
|
3911
|
+
var $L163 = $L("|>=");
|
|
3912
|
+
var $L164 = $L("\u25B7=");
|
|
3913
|
+
var $L165 = $L("|>");
|
|
3914
|
+
var $L166 = $L("\u25B7");
|
|
3915
|
+
var $L167 = $L("readonly");
|
|
3916
|
+
var $L168 = $L("return");
|
|
3917
|
+
var $L169 = $L("satisfies");
|
|
3918
|
+
var $L170 = $L("'");
|
|
3919
|
+
var $L171 = $L("static");
|
|
3920
|
+
var $L172 = $L("${");
|
|
3921
|
+
var $L173 = $L("switch");
|
|
3922
|
+
var $L174 = $L("target");
|
|
3923
|
+
var $L175 = $L("then");
|
|
3924
|
+
var $L176 = $L("this");
|
|
3925
|
+
var $L177 = $L("throw");
|
|
3926
|
+
var $L178 = $L('"""');
|
|
3927
|
+
var $L179 = $L("'''");
|
|
3928
|
+
var $L180 = $L("///");
|
|
3929
|
+
var $L181 = $L("```");
|
|
3930
|
+
var $L182 = $L("try");
|
|
3931
|
+
var $L183 = $L("typeof");
|
|
3932
|
+
var $L184 = $L("unless");
|
|
3933
|
+
var $L185 = $L("until");
|
|
3934
|
+
var $L186 = $L("var");
|
|
3935
|
+
var $L187 = $L("void");
|
|
3936
|
+
var $L188 = $L("when");
|
|
3937
|
+
var $L189 = $L("while");
|
|
3938
|
+
var $L190 = $L("yield");
|
|
3939
|
+
var $L191 = $L("/>");
|
|
3940
|
+
var $L192 = $L("</");
|
|
3941
|
+
var $L193 = $L("<>");
|
|
3942
|
+
var $L194 = $L("</>");
|
|
3943
|
+
var $L195 = $L("<!--");
|
|
3944
|
+
var $L196 = $L("-->");
|
|
3945
|
+
var $L197 = $L("type");
|
|
3946
|
+
var $L198 = $L("enum");
|
|
3947
|
+
var $L199 = $L("interface");
|
|
3948
|
+
var $L200 = $L("global");
|
|
3949
|
+
var $L201 = $L("module");
|
|
3950
|
+
var $L202 = $L("namespace");
|
|
3951
|
+
var $L203 = $L("asserts");
|
|
3952
|
+
var $L204 = $L("keyof");
|
|
3953
|
+
var $L205 = $L("infer");
|
|
3954
|
+
var $L206 = $L("[]");
|
|
3955
|
+
var $L207 = $L("civet");
|
|
3870
3956
|
var $R0 = $R(new RegExp("(as|of|satisfies|then|when|implements|xor|xnor)(?!\\p{ID_Continue}|[\\u200C\\u200D$])", "suy"));
|
|
3871
3957
|
var $R1 = $R(new RegExp("[0-9]", "suy"));
|
|
3872
3958
|
var $R2 = $R(new RegExp("[)}]", "suy"));
|
|
@@ -3877,7 +3963,7 @@ ${input.slice(result.pos)}
|
|
|
3877
3963
|
var $R7 = $R(new RegExp("<(?!\\p{ID_Start}|[_$])", "suy"));
|
|
3878
3964
|
var $R8 = $R(new RegExp("!\\^\\^?", "suy"));
|
|
3879
3965
|
var $R9 = $R(new RegExp("(?!\\+\\+|--)[!~+-](?!\\s|[!~+-]*[&.])", "suy"));
|
|
3880
|
-
var $R10 = $R(new RegExp("(?=[\\s\\)])", "suy"));
|
|
3966
|
+
var $R10 = $R(new RegExp("(?=[\\s\\),])", "suy"));
|
|
3881
3967
|
var $R11 = $R(new RegExp('[^;"\\s]+', "suy"));
|
|
3882
3968
|
var $R12 = $R(new RegExp("(?:0|[1-9](?:_[0-9]|[0-9])*)n", "suy"));
|
|
3883
3969
|
var $R13 = $R(new RegExp("(?:0|[1-9](?:_[0-9]|[0-9])*)(?=\\.(?:\\p{ID_Start}|[_$]))", "suy"));
|
|
@@ -4502,7 +4588,7 @@ ${input.slice(result.pos)}
|
|
|
4502
4588
|
return result;
|
|
4503
4589
|
}
|
|
4504
4590
|
}
|
|
4505
|
-
var TrailingMemberExpressions$0 = $TS($S($Q(MemberExpressionRest), $Q($S(
|
|
4591
|
+
var TrailingMemberExpressions$0 = $TS($S($Q(MemberExpressionRest), $Q($S(IndentedAtLeast, $Y($S($E($EXPECT($L5, fail, 'TrailingMemberExpressions "?"')), $EXPECT($L6, fail, 'TrailingMemberExpressions "."'), $N($EXPECT($R1, fail, "TrailingMemberExpressions /[0-9]/")))), MemberExpressionRest))), function($skip, $loc, $0, $1, $2) {
|
|
4506
4592
|
return $1.concat($2);
|
|
4507
4593
|
});
|
|
4508
4594
|
function TrailingMemberExpressions(state) {
|
|
@@ -4553,7 +4639,7 @@ ${input.slice(result.pos)}
|
|
|
4553
4639
|
return result;
|
|
4554
4640
|
}
|
|
4555
4641
|
}
|
|
4556
|
-
var TrailingCallExpressions$0 = $P($S(
|
|
4642
|
+
var TrailingCallExpressions$0 = $P($S(IndentedAtLeast, $Y($S($E($EXPECT($L5, fail, 'TrailingCallExpressions "?"')), $EXPECT($L6, fail, 'TrailingCallExpressions "."'), $N($R$0($EXPECT($R1, fail, "TrailingCallExpressions /[0-9]/"))))), $P(CallExpressionRest)));
|
|
4557
4643
|
function TrailingCallExpressions(state) {
|
|
4558
4644
|
let eventData;
|
|
4559
4645
|
if (state.events) {
|
|
@@ -4601,7 +4687,7 @@ ${input.slice(result.pos)}
|
|
|
4601
4687
|
return result;
|
|
4602
4688
|
}
|
|
4603
4689
|
}
|
|
4604
|
-
var CommaDelimiter$0 = $S(
|
|
4690
|
+
var CommaDelimiter$0 = $S(NotDedented, Comma);
|
|
4605
4691
|
function CommaDelimiter(state) {
|
|
4606
4692
|
let eventData;
|
|
4607
4693
|
if (state.events) {
|
|
@@ -5511,10 +5597,7 @@ ${input.slice(result.pos)}
|
|
|
5511
5597
|
var head = $2;
|
|
5512
5598
|
var body = $3;
|
|
5513
5599
|
if (head.token === "&") {
|
|
5514
|
-
const ref =
|
|
5515
|
-
type: "Ref",
|
|
5516
|
-
base: "$"
|
|
5517
|
-
};
|
|
5600
|
+
const ref = makeRef("$");
|
|
5518
5601
|
const arrowBody = {
|
|
5519
5602
|
type: "PipelineExpression",
|
|
5520
5603
|
children: [ws, ref, body]
|
|
@@ -7285,11 +7368,7 @@ ${input.slice(result.pos)}
|
|
|
7285
7368
|
});
|
|
7286
7369
|
var AtIdentifierRef$1 = $TV(IdentifierName, function($skip, $loc, $0, $1) {
|
|
7287
7370
|
var id = $0;
|
|
7288
|
-
return
|
|
7289
|
-
type: "Ref",
|
|
7290
|
-
base: id.name,
|
|
7291
|
-
id: id.name
|
|
7292
|
-
};
|
|
7371
|
+
return makeRef(id.name);
|
|
7293
7372
|
});
|
|
7294
7373
|
function AtIdentifierRef(state) {
|
|
7295
7374
|
let eventData;
|
|
@@ -7911,11 +7990,7 @@ ${input.slice(result.pos)}
|
|
|
7911
7990
|
}
|
|
7912
7991
|
}
|
|
7913
7992
|
var EmptyBindingPattern$0 = $TV($EXPECT($L0, fail, 'EmptyBindingPattern ""'), function($skip, $loc, $0, $1) {
|
|
7914
|
-
const ref =
|
|
7915
|
-
type: "Ref",
|
|
7916
|
-
base: "ref",
|
|
7917
|
-
id: "ref"
|
|
7918
|
-
};
|
|
7993
|
+
const ref = makeRef();
|
|
7919
7994
|
return {
|
|
7920
7995
|
type: "EmptyBinding",
|
|
7921
7996
|
children: [ref],
|
|
@@ -8073,11 +8148,7 @@ ${input.slice(result.pos)}
|
|
|
8073
8148
|
return $skip;
|
|
8074
8149
|
let body, ref;
|
|
8075
8150
|
if (!rhs) {
|
|
8076
|
-
body = ref =
|
|
8077
|
-
type: "Ref",
|
|
8078
|
-
base: "$",
|
|
8079
|
-
id: "$"
|
|
8080
|
-
};
|
|
8151
|
+
body = ref = makeRef("$");
|
|
8081
8152
|
} else {
|
|
8082
8153
|
let exp = rhs;
|
|
8083
8154
|
while (!exp.ref && exp.expression) {
|
|
@@ -8257,11 +8328,7 @@ ${input.slice(result.pos)}
|
|
|
8257
8328
|
var binopRHS = $3;
|
|
8258
8329
|
if (!callExpRest && !binopRHS && !unaryPostfix)
|
|
8259
8330
|
return $skip;
|
|
8260
|
-
const ref =
|
|
8261
|
-
type: "Ref",
|
|
8262
|
-
base: "$",
|
|
8263
|
-
id: "$"
|
|
8264
|
-
};
|
|
8331
|
+
const ref = makeRef("$");
|
|
8265
8332
|
let exp = {
|
|
8266
8333
|
type: "AmpersandRef",
|
|
8267
8334
|
children: [ref],
|
|
@@ -8757,7 +8824,7 @@ ${input.slice(result.pos)}
|
|
|
8757
8824
|
var s = $3;
|
|
8758
8825
|
var ws = $4;
|
|
8759
8826
|
var c = $5;
|
|
8760
|
-
if (!s.
|
|
8827
|
+
if (!s.expressions.length)
|
|
8761
8828
|
return $skip;
|
|
8762
8829
|
return {
|
|
8763
8830
|
type: "BlockStatement",
|
|
@@ -8832,16 +8899,16 @@ ${input.slice(result.pos)}
|
|
|
8832
8899
|
return result;
|
|
8833
8900
|
}
|
|
8834
8901
|
}
|
|
8835
|
-
var SingleLineStatements$0 = $TS($S($Q($S($S($E(_), $N(EOS)), Statement, SemicolonDelimiter)), $E($S($S($E(_), $N(EOS)), Statement, $E(SemicolonDelimiter)))), function($skip, $loc, $0, $1, $2) {
|
|
8836
|
-
var stmts = $
|
|
8837
|
-
var last = $
|
|
8838
|
-
const
|
|
8902
|
+
var SingleLineStatements$0 = $TS($S(ForbidNewlineBinaryOp, $Q($S($S($E(_), $N(EOS)), Statement, SemicolonDelimiter)), $E($S($S($E(_), $N(EOS)), Statement, $E(SemicolonDelimiter))), RestoreNewlineBinaryOp), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
8903
|
+
var stmts = $2;
|
|
8904
|
+
var last = $3;
|
|
8905
|
+
const expressions = [...stmts];
|
|
8839
8906
|
if (last)
|
|
8840
|
-
|
|
8907
|
+
expressions.push(last);
|
|
8841
8908
|
return {
|
|
8842
8909
|
type: "BlockStatement",
|
|
8843
|
-
expressions
|
|
8844
|
-
children,
|
|
8910
|
+
expressions,
|
|
8911
|
+
children: [expressions],
|
|
8845
8912
|
bare: true
|
|
8846
8913
|
};
|
|
8847
8914
|
});
|
|
@@ -9297,9 +9364,7 @@ ${input.slice(result.pos)}
|
|
|
9297
9364
|
} else {
|
|
9298
9365
|
children = [open, content, ...ws, close];
|
|
9299
9366
|
}
|
|
9300
|
-
const names = children.flatMap((c) =>
|
|
9301
|
-
return c.names || [];
|
|
9302
|
-
});
|
|
9367
|
+
const names = children.flatMap((c) => c?.names || []);
|
|
9303
9368
|
return {
|
|
9304
9369
|
type: "ArrayExpression",
|
|
9305
9370
|
children,
|
|
@@ -9415,17 +9480,17 @@ ${input.slice(result.pos)}
|
|
|
9415
9480
|
}
|
|
9416
9481
|
}
|
|
9417
9482
|
var ArrayLiteralContent$0 = RangeExpression;
|
|
9418
|
-
var ArrayLiteralContent$1 = $S(
|
|
9419
|
-
var ArrayLiteralContent$2 = NestedElementList
|
|
9420
|
-
var ArrayLiteralContent$3 = $TS($S(ElementListWithIndentedApplicationForbidden, InsertComma, $E(NestedElementList)), function($skip, $loc, $0, $1, $2, $3) {
|
|
9483
|
+
var ArrayLiteralContent$1 = $S(NestedElementList, $Y($S(__, CloseBracket)));
|
|
9484
|
+
var ArrayLiteralContent$2 = $TS($S(ElementListWithIndentedApplicationForbidden, ArrayElementDelimiter, $E(NestedElementList), $Y($S(__, CloseBracket))), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
9421
9485
|
var list = $1;
|
|
9422
|
-
var
|
|
9486
|
+
var delimiter = $2;
|
|
9423
9487
|
var nested = $3;
|
|
9424
|
-
if (nested)
|
|
9425
|
-
return [...list, comma, ...nested];
|
|
9426
|
-
} else {
|
|
9488
|
+
if (!nested)
|
|
9427
9489
|
return list;
|
|
9428
|
-
|
|
9490
|
+
return [...list, delimiter, ...nested];
|
|
9491
|
+
});
|
|
9492
|
+
var ArrayLiteralContent$3 = $TV($Q($S(__, ElementListWithIndentedApplicationForbidden, ArrayElementDelimiter)), function($skip, $loc, $0, $1) {
|
|
9493
|
+
return $1.flat();
|
|
9429
9494
|
});
|
|
9430
9495
|
function ArrayLiteralContent(state) {
|
|
9431
9496
|
let eventData;
|
|
@@ -9573,9 +9638,9 @@ ${input.slice(result.pos)}
|
|
|
9573
9638
|
return result;
|
|
9574
9639
|
}
|
|
9575
9640
|
}
|
|
9576
|
-
var ElementList$0 = $TS($S(ArrayElementExpression, $Q(ElementListRest)), function($skip, $loc, $0, $1, $2) {
|
|
9577
|
-
var first = $
|
|
9578
|
-
var rest = $
|
|
9641
|
+
var ElementList$0 = $TS($S($N(EOS), ArrayElementExpression, $Q(ElementListRest)), function($skip, $loc, $0, $1, $2, $3) {
|
|
9642
|
+
var first = $2;
|
|
9643
|
+
var rest = $3;
|
|
9579
9644
|
if (rest.length) {
|
|
9580
9645
|
return [{
|
|
9581
9646
|
...first,
|
|
@@ -9612,7 +9677,7 @@ ${input.slice(result.pos)}
|
|
|
9612
9677
|
return result;
|
|
9613
9678
|
}
|
|
9614
9679
|
}
|
|
9615
|
-
var ElementListRest$0 = $S($S(
|
|
9680
|
+
var ElementListRest$0 = $S($S($E(_), Comma, $N(EOS)), ArrayElementExpression);
|
|
9616
9681
|
function ElementListRest(state) {
|
|
9617
9682
|
let eventData;
|
|
9618
9683
|
if (state.events) {
|
|
@@ -9641,12 +9706,7 @@ ${input.slice(result.pos)}
|
|
|
9641
9706
|
var ws = $2;
|
|
9642
9707
|
var dots = $3;
|
|
9643
9708
|
if (!exp) {
|
|
9644
|
-
exp = {
|
|
9645
|
-
type: "Ref",
|
|
9646
|
-
base: "ref",
|
|
9647
|
-
id: "ref",
|
|
9648
|
-
names: []
|
|
9649
|
-
};
|
|
9709
|
+
exp = { ...makeRef(), names: [] };
|
|
9650
9710
|
}
|
|
9651
9711
|
return {
|
|
9652
9712
|
type: "SpreadElement",
|
|
@@ -9727,26 +9787,16 @@ ${input.slice(result.pos)}
|
|
|
9727
9787
|
return result;
|
|
9728
9788
|
}
|
|
9729
9789
|
}
|
|
9730
|
-
var BracedObjectLiteral$0 = $TS($S(OpenBrace, AllowAll, $E($S(
|
|
9790
|
+
var BracedObjectLiteral$0 = $TS($S(OpenBrace, AllowAll, $E($S(BracedObjectLiteralContent, __, CloseBrace)), RestoreAll), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
9731
9791
|
var open = $1;
|
|
9732
9792
|
if (!$3)
|
|
9733
9793
|
return $skip;
|
|
9734
9794
|
const [properties, ...close] = $3;
|
|
9735
|
-
if (properties) {
|
|
9736
|
-
const children = [open, ...properties, close];
|
|
9737
|
-
return {
|
|
9738
|
-
type: "ObjectExpression",
|
|
9739
|
-
children,
|
|
9740
|
-
names: children.flatMap((c) => {
|
|
9741
|
-
return c.names || [];
|
|
9742
|
-
}),
|
|
9743
|
-
properties
|
|
9744
|
-
};
|
|
9745
|
-
}
|
|
9746
9795
|
return {
|
|
9747
9796
|
type: "ObjectExpression",
|
|
9748
|
-
children: [open, close],
|
|
9749
|
-
names: []
|
|
9797
|
+
children: [open, properties, close],
|
|
9798
|
+
names: properties.flatMap((c) => c.names || []),
|
|
9799
|
+
properties
|
|
9750
9800
|
};
|
|
9751
9801
|
});
|
|
9752
9802
|
function BracedObjectLiteral(state) {
|
|
@@ -9771,8 +9821,33 @@ ${input.slice(result.pos)}
|
|
|
9771
9821
|
return result;
|
|
9772
9822
|
}
|
|
9773
9823
|
}
|
|
9774
|
-
var BracedObjectLiteralContent$0 = NestedPropertyDefinitions
|
|
9775
|
-
|
|
9824
|
+
var BracedObjectLiteralContent$0 = $TS($S($Q($S(PropertyDefinition, ObjectPropertyDelimiter)), $E(NestedPropertyDefinitions)), function($skip, $loc, $0, $1, $2) {
|
|
9825
|
+
var line = $1;
|
|
9826
|
+
var nested = $2;
|
|
9827
|
+
line = line.flatMap(([prop, delim]) => {
|
|
9828
|
+
prop = Array.isArray(prop) ? prop : [prop];
|
|
9829
|
+
let last = prop[prop.length - 1];
|
|
9830
|
+
last = {
|
|
9831
|
+
...last,
|
|
9832
|
+
delim,
|
|
9833
|
+
children: [...last.children, delim]
|
|
9834
|
+
};
|
|
9835
|
+
return [...prop.slice(0, prop.length - 1), last];
|
|
9836
|
+
});
|
|
9837
|
+
return line.concat(nested || []);
|
|
9838
|
+
});
|
|
9839
|
+
var BracedObjectLiteralContent$1 = $TV($P($S(__, PropertyDefinition, ObjectPropertyDelimiter)), function($skip, $loc, $0, $1) {
|
|
9840
|
+
return $0.flatMap(([ws, prop, delim]) => {
|
|
9841
|
+
prop = Array.isArray(prop) ? prop : [prop];
|
|
9842
|
+
let last = prop[prop.length - 1];
|
|
9843
|
+
last = {
|
|
9844
|
+
...last,
|
|
9845
|
+
delim,
|
|
9846
|
+
children: [ws, ...last.children.slice(1), delim]
|
|
9847
|
+
};
|
|
9848
|
+
return [...prop.slice(0, prop.length - 1), last];
|
|
9849
|
+
});
|
|
9850
|
+
});
|
|
9776
9851
|
function BracedObjectLiteralContent(state) {
|
|
9777
9852
|
let eventData;
|
|
9778
9853
|
if (state.events) {
|
|
@@ -9796,9 +9871,11 @@ ${input.slice(result.pos)}
|
|
|
9796
9871
|
}
|
|
9797
9872
|
}
|
|
9798
9873
|
var NestedImplicitObjectLiteral$0 = $TS($S(InsertOpenBrace, NestedImplicitPropertyDefinitions, InsertNewline, InsertIndent, InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
9874
|
+
var properties = $2;
|
|
9799
9875
|
return {
|
|
9800
9876
|
type: "ObjectExpression",
|
|
9801
|
-
|
|
9877
|
+
properties,
|
|
9878
|
+
children: $0
|
|
9802
9879
|
};
|
|
9803
9880
|
});
|
|
9804
9881
|
function NestedImplicitObjectLiteral(state) {
|
|
@@ -9851,7 +9928,7 @@ ${input.slice(result.pos)}
|
|
|
9851
9928
|
return result;
|
|
9852
9929
|
}
|
|
9853
9930
|
}
|
|
9854
|
-
var NestedImplicitPropertyDefinition$0 = $TS($S(Nested,
|
|
9931
|
+
var NestedImplicitPropertyDefinition$0 = $TS($S(Nested, NamedProperty, ObjectPropertyDelimiter), function($skip, $loc, $0, $1, $2, $3) {
|
|
9855
9932
|
var ws = $1;
|
|
9856
9933
|
var prop = $2;
|
|
9857
9934
|
var delimiter = $3;
|
|
@@ -9954,7 +10031,7 @@ ${input.slice(result.pos)}
|
|
|
9954
10031
|
return result;
|
|
9955
10032
|
}
|
|
9956
10033
|
}
|
|
9957
|
-
var InlineObjectLiteral$0 = $TS($S(InsertInlineOpenBrace, SnugNamedProperty, $Q($S(ImplicitInlineObjectPropertyDelimiter,
|
|
10034
|
+
var InlineObjectLiteral$0 = $TS($S(InsertInlineOpenBrace, SnugNamedProperty, $Q($S(ImplicitInlineObjectPropertyDelimiter, NamedProperty)), $E($S($E(_), Comma, $Y(Dedented))), InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
9958
10035
|
var open = $1;
|
|
9959
10036
|
var first = $2;
|
|
9960
10037
|
var rest = $3;
|
|
@@ -9988,7 +10065,7 @@ ${input.slice(result.pos)}
|
|
|
9988
10065
|
}
|
|
9989
10066
|
}
|
|
9990
10067
|
var ImplicitInlineObjectPropertyDelimiter$0 = $S($E(_), Comma, $C(NotDedented, $E(_)));
|
|
9991
|
-
var ImplicitInlineObjectPropertyDelimiter$1 = $T($S($Y($S(
|
|
10068
|
+
var ImplicitInlineObjectPropertyDelimiter$1 = $T($S($Y($S(Nested, NamedProperty)), InsertComma, $C(Nested, $E(_))), function(value) {
|
|
9992
10069
|
return [value[1], value[2]];
|
|
9993
10070
|
});
|
|
9994
10071
|
function ImplicitInlineObjectPropertyDelimiter(state) {
|
|
@@ -10040,41 +10117,7 @@ ${input.slice(result.pos)}
|
|
|
10040
10117
|
return result;
|
|
10041
10118
|
}
|
|
10042
10119
|
}
|
|
10043
|
-
var
|
|
10044
|
-
return $0.flatMap(([prop, delim]) => {
|
|
10045
|
-
prop = Array.isArray(prop) ? prop : [prop];
|
|
10046
|
-
let last = prop[prop.length - 1];
|
|
10047
|
-
last = {
|
|
10048
|
-
...last,
|
|
10049
|
-
delim,
|
|
10050
|
-
children: [...last.children, delim]
|
|
10051
|
-
};
|
|
10052
|
-
return [...prop.slice(0, prop.length - 1), last];
|
|
10053
|
-
});
|
|
10054
|
-
});
|
|
10055
|
-
function PropertyDefinitionList(state) {
|
|
10056
|
-
let eventData;
|
|
10057
|
-
if (state.events) {
|
|
10058
|
-
const result = state.events.enter?.("PropertyDefinitionList", state);
|
|
10059
|
-
if (result) {
|
|
10060
|
-
if (result.cache)
|
|
10061
|
-
return result.cache;
|
|
10062
|
-
eventData = result.data;
|
|
10063
|
-
}
|
|
10064
|
-
}
|
|
10065
|
-
if (state.tokenize) {
|
|
10066
|
-
const result = $TOKEN("PropertyDefinitionList", state, PropertyDefinitionList$0(state));
|
|
10067
|
-
if (state.events)
|
|
10068
|
-
state.events.exit?.("PropertyDefinitionList", state, result, eventData);
|
|
10069
|
-
return result;
|
|
10070
|
-
} else {
|
|
10071
|
-
const result = PropertyDefinitionList$0(state);
|
|
10072
|
-
if (state.events)
|
|
10073
|
-
state.events.exit?.("PropertyDefinitionList", state, result, eventData);
|
|
10074
|
-
return result;
|
|
10075
|
-
}
|
|
10076
|
-
}
|
|
10077
|
-
var PropertyDefinition$0 = $TS($S(__, AtThis, IdentifierReference), function($skip, $loc, $0, $1, $2, $3) {
|
|
10120
|
+
var PropertyDefinition$0 = $TS($S($E(_), AtThis, IdentifierReference), function($skip, $loc, $0, $1, $2, $3) {
|
|
10078
10121
|
var ws = $1;
|
|
10079
10122
|
var at = $2;
|
|
10080
10123
|
var id = $3;
|
|
@@ -10087,7 +10130,7 @@ ${input.slice(result.pos)}
|
|
|
10087
10130
|
value
|
|
10088
10131
|
};
|
|
10089
10132
|
});
|
|
10090
|
-
var PropertyDefinition$1 = $TS($S(
|
|
10133
|
+
var PropertyDefinition$1 = $TS($S($E(_), NamedProperty), function($skip, $loc, $0, $1, $2) {
|
|
10091
10134
|
var ws = $1;
|
|
10092
10135
|
var prop = $2;
|
|
10093
10136
|
return {
|
|
@@ -10095,7 +10138,7 @@ ${input.slice(result.pos)}
|
|
|
10095
10138
|
children: [ws, ...prop.children]
|
|
10096
10139
|
};
|
|
10097
10140
|
});
|
|
10098
|
-
var PropertyDefinition$2 = $TS($S(
|
|
10141
|
+
var PropertyDefinition$2 = $TS($S($E(_), $TEXT($EXPECT($R6, fail, "PropertyDefinition /[!+-]/")), PropertyName), function($skip, $loc, $0, $1, $2, $3) {
|
|
10099
10142
|
var ws = $1;
|
|
10100
10143
|
var toggle = $2;
|
|
10101
10144
|
var id = $3;
|
|
@@ -10108,7 +10151,7 @@ ${input.slice(result.pos)}
|
|
|
10108
10151
|
value
|
|
10109
10152
|
};
|
|
10110
10153
|
});
|
|
10111
|
-
var PropertyDefinition$3 = $TS($S(
|
|
10154
|
+
var PropertyDefinition$3 = $TS($S($E(_), MethodDefinition), function($skip, $loc, $0, $1, $2) {
|
|
10112
10155
|
var ws = $1;
|
|
10113
10156
|
var def = $2;
|
|
10114
10157
|
if (!def.block || def.block.empty)
|
|
@@ -10118,7 +10161,7 @@ ${input.slice(result.pos)}
|
|
|
10118
10161
|
children: [ws, ...def.children]
|
|
10119
10162
|
};
|
|
10120
10163
|
});
|
|
10121
|
-
var PropertyDefinition$4 = $TS($S(
|
|
10164
|
+
var PropertyDefinition$4 = $TS($S($E(_), DotDotDot, ExtendedExpression), function($skip, $loc, $0, $1, $2, $3) {
|
|
10122
10165
|
var ws = $1;
|
|
10123
10166
|
var dots = $2;
|
|
10124
10167
|
var exp = $3;
|
|
@@ -10130,9 +10173,9 @@ ${input.slice(result.pos)}
|
|
|
10130
10173
|
value: exp
|
|
10131
10174
|
};
|
|
10132
10175
|
});
|
|
10133
|
-
var PropertyDefinition$5 = $TS($S(
|
|
10176
|
+
var PropertyDefinition$5 = $TS($S($E(_), $N(EOS), CallExpression), function($skip, $loc, $0, $1, $2, $3) {
|
|
10134
10177
|
var ws = $1;
|
|
10135
|
-
var value = $
|
|
10178
|
+
var value = $3;
|
|
10136
10179
|
switch (value.type) {
|
|
10137
10180
|
case "Identifier":
|
|
10138
10181
|
return { ...value, children: [ws, ...value.children] };
|
|
@@ -10253,41 +10296,8 @@ ${input.slice(result.pos)}
|
|
|
10253
10296
|
return result;
|
|
10254
10297
|
}
|
|
10255
10298
|
}
|
|
10256
|
-
var
|
|
10257
|
-
var
|
|
10258
|
-
var exp = $5;
|
|
10259
|
-
return {
|
|
10260
|
-
type: "Property",
|
|
10261
|
-
children: $0,
|
|
10262
|
-
name,
|
|
10263
|
-
names: exp.names || [],
|
|
10264
|
-
value: exp
|
|
10265
|
-
};
|
|
10266
|
-
});
|
|
10267
|
-
function ImplicitNamedProperty(state) {
|
|
10268
|
-
let eventData;
|
|
10269
|
-
if (state.events) {
|
|
10270
|
-
const result = state.events.enter?.("ImplicitNamedProperty", state);
|
|
10271
|
-
if (result) {
|
|
10272
|
-
if (result.cache)
|
|
10273
|
-
return result.cache;
|
|
10274
|
-
eventData = result.data;
|
|
10275
|
-
}
|
|
10276
|
-
}
|
|
10277
|
-
if (state.tokenize) {
|
|
10278
|
-
const result = $TOKEN("ImplicitNamedProperty", state, ImplicitNamedProperty$0(state));
|
|
10279
|
-
if (state.events)
|
|
10280
|
-
state.events.exit?.("ImplicitNamedProperty", state, result, eventData);
|
|
10281
|
-
return result;
|
|
10282
|
-
} else {
|
|
10283
|
-
const result = ImplicitNamedProperty$0(state);
|
|
10284
|
-
if (state.events)
|
|
10285
|
-
state.events.exit?.("ImplicitNamedProperty", state, result, eventData);
|
|
10286
|
-
return result;
|
|
10287
|
-
}
|
|
10288
|
-
}
|
|
10289
|
-
var SnugNamedProperty$0 = $TS($S(PropertyName, Colon, $C(MultiLineImplicitObjectLiteralAllowed, $N(EOS)), ExtendedExpression), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
10290
|
-
var exp = $4;
|
|
10299
|
+
var SnugNamedProperty$0 = $TS($S(PropertyName, Colon, ExtendedExpression), function($skip, $loc, $0, $1, $2, $3) {
|
|
10300
|
+
var exp = $3;
|
|
10291
10301
|
return {
|
|
10292
10302
|
type: "Property",
|
|
10293
10303
|
children: $0,
|
|
@@ -10863,7 +10873,7 @@ ${input.slice(result.pos)}
|
|
|
10863
10873
|
ws.push(...$2);
|
|
10864
10874
|
return [ws, $3];
|
|
10865
10875
|
});
|
|
10866
|
-
var NotDedentedBinaryOp$1 = $TS($S(
|
|
10876
|
+
var NotDedentedBinaryOp$1 = $TS($S(Nested, $E(_), $N(Identifier), BinaryOp), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
10867
10877
|
const ws = [...$1];
|
|
10868
10878
|
if ($2)
|
|
10869
10879
|
ws.push(...$2);
|
|
@@ -11651,7 +11661,7 @@ ${input.slice(result.pos)}
|
|
|
11651
11661
|
return result;
|
|
11652
11662
|
}
|
|
11653
11663
|
}
|
|
11654
|
-
var ElseClause$0 = $S(
|
|
11664
|
+
var ElseClause$0 = $S(Nested, Else, Block);
|
|
11655
11665
|
var ElseClause$1 = $S($E(_), Else, Block);
|
|
11656
11666
|
function ElseClause(state) {
|
|
11657
11667
|
let eventData;
|
|
@@ -11795,7 +11805,7 @@ ${input.slice(result.pos)}
|
|
|
11795
11805
|
return result;
|
|
11796
11806
|
}
|
|
11797
11807
|
}
|
|
11798
|
-
var ElseExpressionClause$0 = $TS($S($C($S(
|
|
11808
|
+
var ElseExpressionClause$0 = $TS($S($C($S(Nested, Else), $S($E(_), Else)), ElseExpressionBlock), function($skip, $loc, $0, $1, $2) {
|
|
11799
11809
|
return [...$1, $2];
|
|
11800
11810
|
});
|
|
11801
11811
|
function ElseExpressionClause(state) {
|
|
@@ -12292,7 +12302,8 @@ ${input.slice(result.pos)}
|
|
|
12292
12302
|
children: [$1, ...$2, ...children],
|
|
12293
12303
|
declaration,
|
|
12294
12304
|
block: null,
|
|
12295
|
-
blockPrefix: c.blockPrefix
|
|
12305
|
+
blockPrefix: c.blockPrefix,
|
|
12306
|
+
hoistDec: c.hoistDec
|
|
12296
12307
|
};
|
|
12297
12308
|
});
|
|
12298
12309
|
function ForClause(state) {
|
|
@@ -12400,7 +12411,7 @@ ${input.slice(result.pos)}
|
|
|
12400
12411
|
if (step) {
|
|
12401
12412
|
throw new Error("Can't use 'by' with 'from' in CoffeeScript for loops");
|
|
12402
12413
|
}
|
|
12403
|
-
kind
|
|
12414
|
+
kind = { ...kind, token: "of" };
|
|
12404
12415
|
} else if (kind.token === "of") {
|
|
12405
12416
|
if (step) {
|
|
12406
12417
|
throw new Error("Can't use 'by' with 'of' in CoffeeScript for loops");
|
|
@@ -12418,30 +12429,12 @@ ${input.slice(result.pos)}
|
|
|
12418
12429
|
}
|
|
12419
12430
|
kind.token = "in";
|
|
12420
12431
|
} else if (kind.token === "in") {
|
|
12421
|
-
const counterRef =
|
|
12422
|
-
|
|
12423
|
-
|
|
12424
|
-
|
|
12425
|
-
};
|
|
12426
|
-
const lenRef = {
|
|
12427
|
-
type: "Ref",
|
|
12428
|
-
base: "len",
|
|
12429
|
-
id: "len"
|
|
12430
|
-
};
|
|
12431
|
-
let expRef;
|
|
12432
|
-
switch (exp.type) {
|
|
12433
|
-
case "Identifier":
|
|
12434
|
-
expRef = exp;
|
|
12435
|
-
break;
|
|
12436
|
-
case "RangeExpression":
|
|
12437
|
-
return forRange(open, declaration, exp, step?.[2], close);
|
|
12438
|
-
default:
|
|
12439
|
-
expRef = {
|
|
12440
|
-
type: "Ref",
|
|
12441
|
-
base: "ref",
|
|
12442
|
-
id: "ref"
|
|
12443
|
-
};
|
|
12432
|
+
const counterRef = makeRef("i");
|
|
12433
|
+
const lenRef = makeRef("len");
|
|
12434
|
+
if (exp.type === "RangeExpression") {
|
|
12435
|
+
return forRange(open, declaration, exp, step?.[2], close);
|
|
12444
12436
|
}
|
|
12437
|
+
const expRef = maybeRef(exp);
|
|
12445
12438
|
const varRef = declaration;
|
|
12446
12439
|
let increment = "++", indexAssignment, assignmentNames = [...varRef.names];
|
|
12447
12440
|
if (index) {
|
|
@@ -12596,39 +12589,11 @@ ${input.slice(result.pos)}
|
|
|
12596
12589
|
children: $0
|
|
12597
12590
|
};
|
|
12598
12591
|
});
|
|
12599
|
-
var ForStatementParameters$2 = $TS($S($E($S(Await, __)), OpenParen, __, ForInOfDeclaration, __, $C(In, Of), ExpressionWithObjectApplicationForbidden, $E($S(__, By, ExpressionWithObjectApplicationForbidden)), __, CloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9, $10) {
|
|
12600
|
-
|
|
12601
|
-
var declaration = $4;
|
|
12602
|
-
var op = $6;
|
|
12603
|
-
var exp = $7;
|
|
12604
|
-
var step = $8;
|
|
12605
|
-
var close = $10;
|
|
12606
|
-
if (exp.type === "RangeExpression" && op.token === "of") {
|
|
12607
|
-
return forRange(open, declaration, exp, step, close);
|
|
12608
|
-
} else if (step) {
|
|
12609
|
-
throw new Error("for..of/in cannot use 'by' except with range literals");
|
|
12610
|
-
}
|
|
12611
|
-
return {
|
|
12612
|
-
declaration,
|
|
12613
|
-
children: $0
|
|
12614
|
-
};
|
|
12592
|
+
var ForStatementParameters$2 = $TS($S($E($S(Await, __)), $E($S(Each, __)), $S(OpenParen, __), ForInOfDeclaration, $E($S(__, Comma, __, ForInOfDeclaration)), __, $C(In, Of), ExpressionWithObjectApplicationForbidden, $E($S(__, By, ExpressionWithObjectApplicationForbidden)), $S(__, CloseParen)), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9, $10) {
|
|
12593
|
+
return processForInOf($0);
|
|
12615
12594
|
});
|
|
12616
|
-
var ForStatementParameters$3 = $TS($S($E($S(Await, __)), InsertOpenParen, ForInOfDeclaration, __, $C(In, Of), ExpressionWithObjectApplicationForbidden, $E($S(__, By, ExpressionWithObjectApplicationForbidden)), InsertCloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8) {
|
|
12617
|
-
|
|
12618
|
-
var declaration = $3;
|
|
12619
|
-
var op = $5;
|
|
12620
|
-
var exp = $6;
|
|
12621
|
-
var step = $7;
|
|
12622
|
-
var close = $8;
|
|
12623
|
-
if (exp.type === "RangeExpression" && op.token === "of") {
|
|
12624
|
-
return forRange(open, declaration, exp, step, close);
|
|
12625
|
-
} else if (step) {
|
|
12626
|
-
throw new Error("for..of/in cannot use 'by' except with range literals");
|
|
12627
|
-
}
|
|
12628
|
-
return {
|
|
12629
|
-
declaration,
|
|
12630
|
-
children: $0
|
|
12631
|
-
};
|
|
12595
|
+
var ForStatementParameters$3 = $TS($S($E($S(Await, __)), $E($S(Each, __)), InsertOpenParen, ForInOfDeclaration, $E($S(__, Comma, __, ForInOfDeclaration)), __, $C(In, Of), ExpressionWithObjectApplicationForbidden, $E($S(__, By, ExpressionWithObjectApplicationForbidden)), InsertCloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9, $10) {
|
|
12596
|
+
return processForInOf($0);
|
|
12632
12597
|
});
|
|
12633
12598
|
var ForStatementParameters$4 = ForRangeParameters;
|
|
12634
12599
|
function ForStatementParameters(state) {
|
|
@@ -12695,6 +12660,7 @@ ${input.slice(result.pos)}
|
|
|
12695
12660
|
type: "ForDeclaration",
|
|
12696
12661
|
children: $0,
|
|
12697
12662
|
declare: $1,
|
|
12663
|
+
binding,
|
|
12698
12664
|
names: binding.names
|
|
12699
12665
|
};
|
|
12700
12666
|
});
|
|
@@ -12729,16 +12695,18 @@ ${input.slice(result.pos)}
|
|
|
12729
12695
|
type: "ForDeclaration",
|
|
12730
12696
|
children: [c, binding],
|
|
12731
12697
|
declare: c,
|
|
12698
|
+
binding,
|
|
12732
12699
|
names: binding.names
|
|
12733
12700
|
};
|
|
12734
12701
|
});
|
|
12735
|
-
var ForDeclaration$1 = $TS($S(InsertConst, ForBinding, $EXPECT($R10, fail, "ForDeclaration /(?=[\\s\\)])/")), function($skip, $loc, $0, $1, $2, $3) {
|
|
12702
|
+
var ForDeclaration$1 = $TS($S(InsertConst, ForBinding, $EXPECT($R10, fail, "ForDeclaration /(?=[\\s\\),])/")), function($skip, $loc, $0, $1, $2, $3) {
|
|
12736
12703
|
var c = $1;
|
|
12737
12704
|
var binding = $2;
|
|
12738
12705
|
return {
|
|
12739
12706
|
type: "ForDeclaration",
|
|
12740
12707
|
children: [c, binding],
|
|
12741
12708
|
declare: c,
|
|
12709
|
+
binding,
|
|
12742
12710
|
names: binding.names
|
|
12743
12711
|
};
|
|
12744
12712
|
});
|
|
@@ -12899,7 +12867,7 @@ ${input.slice(result.pos)}
|
|
|
12899
12867
|
return result;
|
|
12900
12868
|
}
|
|
12901
12869
|
}
|
|
12902
|
-
var CaseBlock$0 = $TS($S($E($C(
|
|
12870
|
+
var CaseBlock$0 = $TS($S($E($C(Nested, _)), OpenBrace, NestedCaseClauses, __, CloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
12903
12871
|
var clauses = $3;
|
|
12904
12872
|
return {
|
|
12905
12873
|
type: "CaseBlock",
|
|
@@ -13116,11 +13084,9 @@ ${input.slice(result.pos)}
|
|
|
13116
13084
|
return result;
|
|
13117
13085
|
}
|
|
13118
13086
|
}
|
|
13119
|
-
var CaseExpressionList$0 = $TS($S(
|
|
13120
|
-
var first = $
|
|
13121
|
-
var rest = $
|
|
13122
|
-
if (!first)
|
|
13123
|
-
return $skip;
|
|
13087
|
+
var CaseExpressionList$0 = $TS($S($S($E(_), CaseExpression, InsertColon), $Q($S(__, Comma, CaseExpression, InsertColon))), function($skip, $loc, $0, $1, $2) {
|
|
13088
|
+
var first = $1;
|
|
13089
|
+
var rest = $2;
|
|
13124
13090
|
const result = rest.map(([ws, _comma, exp, col]) => {
|
|
13125
13091
|
exp = insertTrimmingSpace(exp, "");
|
|
13126
13092
|
if (ws.length)
|
|
@@ -13313,7 +13279,7 @@ ${input.slice(result.pos)}
|
|
|
13313
13279
|
return result;
|
|
13314
13280
|
}
|
|
13315
13281
|
}
|
|
13316
|
-
var CatchClause$0 = $TS($S($C(
|
|
13282
|
+
var CatchClause$0 = $TS($S($C(Nested, _), Catch, $E(CatchBind), $C(ThenClause, BracedOrEmptyBlock)), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
13317
13283
|
var block = $4;
|
|
13318
13284
|
return {
|
|
13319
13285
|
type: "CatchClause",
|
|
@@ -13367,7 +13333,7 @@ ${input.slice(result.pos)}
|
|
|
13367
13333
|
return result;
|
|
13368
13334
|
}
|
|
13369
13335
|
}
|
|
13370
|
-
var FinallyClause$0 = $S($C(
|
|
13336
|
+
var FinallyClause$0 = $S($C(Nested, _), Finally, $C(ThenClause, BracedOrEmptyBlock));
|
|
13371
13337
|
function FinallyClause(state) {
|
|
13372
13338
|
let eventData;
|
|
13373
13339
|
if (state.events) {
|
|
@@ -13475,10 +13441,7 @@ ${input.slice(result.pos)}
|
|
|
13475
13441
|
}
|
|
13476
13442
|
var DeclarationCondition$0 = $TV(LexicalDeclaration, function($skip, $loc, $0, $1) {
|
|
13477
13443
|
var dec = $0;
|
|
13478
|
-
const ref =
|
|
13479
|
-
type: "Ref",
|
|
13480
|
-
base: "ref"
|
|
13481
|
-
};
|
|
13444
|
+
const ref = makeRef();
|
|
13482
13445
|
const { decl, bindings } = dec;
|
|
13483
13446
|
const binding = bindings[0];
|
|
13484
13447
|
const { pattern, suffix, initializer, splices, thisAssignments } = binding;
|
|
@@ -13991,110 +13954,6 @@ ${input.slice(result.pos)}
|
|
|
13991
13954
|
return result;
|
|
13992
13955
|
}
|
|
13993
13956
|
}
|
|
13994
|
-
var ForbidMultiLineImplicitObjectLiteral$0 = $TV($EXPECT($L0, fail, 'ForbidMultiLineImplicitObjectLiteral ""'), function($skip, $loc, $0, $1) {
|
|
13995
|
-
module2.forbidMultiLineImplicitObjectLiteral.push(true);
|
|
13996
|
-
});
|
|
13997
|
-
function ForbidMultiLineImplicitObjectLiteral(state) {
|
|
13998
|
-
let eventData;
|
|
13999
|
-
if (state.events) {
|
|
14000
|
-
const result = state.events.enter?.("ForbidMultiLineImplicitObjectLiteral", state);
|
|
14001
|
-
if (result) {
|
|
14002
|
-
if (result.cache)
|
|
14003
|
-
return result.cache;
|
|
14004
|
-
eventData = result.data;
|
|
14005
|
-
}
|
|
14006
|
-
}
|
|
14007
|
-
if (state.tokenize) {
|
|
14008
|
-
const result = $TOKEN("ForbidMultiLineImplicitObjectLiteral", state, ForbidMultiLineImplicitObjectLiteral$0(state));
|
|
14009
|
-
if (state.events)
|
|
14010
|
-
state.events.exit?.("ForbidMultiLineImplicitObjectLiteral", state, result, eventData);
|
|
14011
|
-
return result;
|
|
14012
|
-
} else {
|
|
14013
|
-
const result = ForbidMultiLineImplicitObjectLiteral$0(state);
|
|
14014
|
-
if (state.events)
|
|
14015
|
-
state.events.exit?.("ForbidMultiLineImplicitObjectLiteral", state, result, eventData);
|
|
14016
|
-
return result;
|
|
14017
|
-
}
|
|
14018
|
-
}
|
|
14019
|
-
var AllowMultiLineImplicitObjectLiteral$0 = $TV($EXPECT($L0, fail, 'AllowMultiLineImplicitObjectLiteral ""'), function($skip, $loc, $0, $1) {
|
|
14020
|
-
module2.forbidMultiLineImplicitObjectLiteral.push(false);
|
|
14021
|
-
});
|
|
14022
|
-
function AllowMultiLineImplicitObjectLiteral(state) {
|
|
14023
|
-
let eventData;
|
|
14024
|
-
if (state.events) {
|
|
14025
|
-
const result = state.events.enter?.("AllowMultiLineImplicitObjectLiteral", state);
|
|
14026
|
-
if (result) {
|
|
14027
|
-
if (result.cache)
|
|
14028
|
-
return result.cache;
|
|
14029
|
-
eventData = result.data;
|
|
14030
|
-
}
|
|
14031
|
-
}
|
|
14032
|
-
if (state.tokenize) {
|
|
14033
|
-
const result = $TOKEN("AllowMultiLineImplicitObjectLiteral", state, AllowMultiLineImplicitObjectLiteral$0(state));
|
|
14034
|
-
if (state.events)
|
|
14035
|
-
state.events.exit?.("AllowMultiLineImplicitObjectLiteral", state, result, eventData);
|
|
14036
|
-
return result;
|
|
14037
|
-
} else {
|
|
14038
|
-
const result = AllowMultiLineImplicitObjectLiteral$0(state);
|
|
14039
|
-
if (state.events)
|
|
14040
|
-
state.events.exit?.("AllowMultiLineImplicitObjectLiteral", state, result, eventData);
|
|
14041
|
-
return result;
|
|
14042
|
-
}
|
|
14043
|
-
}
|
|
14044
|
-
var RestoreMultiLineImplicitObjectLiteral$0 = $TV($EXPECT($L0, fail, 'RestoreMultiLineImplicitObjectLiteral ""'), function($skip, $loc, $0, $1) {
|
|
14045
|
-
module2.forbidMultiLineImplicitObjectLiteral.pop();
|
|
14046
|
-
});
|
|
14047
|
-
function RestoreMultiLineImplicitObjectLiteral(state) {
|
|
14048
|
-
let eventData;
|
|
14049
|
-
if (state.events) {
|
|
14050
|
-
const result = state.events.enter?.("RestoreMultiLineImplicitObjectLiteral", state);
|
|
14051
|
-
if (result) {
|
|
14052
|
-
if (result.cache)
|
|
14053
|
-
return result.cache;
|
|
14054
|
-
eventData = result.data;
|
|
14055
|
-
}
|
|
14056
|
-
}
|
|
14057
|
-
if (state.tokenize) {
|
|
14058
|
-
const result = $TOKEN("RestoreMultiLineImplicitObjectLiteral", state, RestoreMultiLineImplicitObjectLiteral$0(state));
|
|
14059
|
-
if (state.events)
|
|
14060
|
-
state.events.exit?.("RestoreMultiLineImplicitObjectLiteral", state, result, eventData);
|
|
14061
|
-
return result;
|
|
14062
|
-
} else {
|
|
14063
|
-
const result = RestoreMultiLineImplicitObjectLiteral$0(state);
|
|
14064
|
-
if (state.events)
|
|
14065
|
-
state.events.exit?.("RestoreMultiLineImplicitObjectLiteral", state, result, eventData);
|
|
14066
|
-
return result;
|
|
14067
|
-
}
|
|
14068
|
-
}
|
|
14069
|
-
var MultiLineImplicitObjectLiteralAllowed$0 = $TV($EXPECT($L0, fail, 'MultiLineImplicitObjectLiteralAllowed ""'), function($skip, $loc, $0, $1) {
|
|
14070
|
-
if (module2.config.verbose) {
|
|
14071
|
-
console.log("forbidMultiLineImplicitObjectLiteral:", module2.forbidMultiLineImplicitObjectLiteral);
|
|
14072
|
-
}
|
|
14073
|
-
if (module2.multiLineImplicitObjectLiteralForbidden)
|
|
14074
|
-
return $skip;
|
|
14075
|
-
});
|
|
14076
|
-
function MultiLineImplicitObjectLiteralAllowed(state) {
|
|
14077
|
-
let eventData;
|
|
14078
|
-
if (state.events) {
|
|
14079
|
-
const result = state.events.enter?.("MultiLineImplicitObjectLiteralAllowed", state);
|
|
14080
|
-
if (result) {
|
|
14081
|
-
if (result.cache)
|
|
14082
|
-
return result.cache;
|
|
14083
|
-
eventData = result.data;
|
|
14084
|
-
}
|
|
14085
|
-
}
|
|
14086
|
-
if (state.tokenize) {
|
|
14087
|
-
const result = $TOKEN("MultiLineImplicitObjectLiteralAllowed", state, MultiLineImplicitObjectLiteralAllowed$0(state));
|
|
14088
|
-
if (state.events)
|
|
14089
|
-
state.events.exit?.("MultiLineImplicitObjectLiteralAllowed", state, result, eventData);
|
|
14090
|
-
return result;
|
|
14091
|
-
} else {
|
|
14092
|
-
const result = MultiLineImplicitObjectLiteralAllowed$0(state);
|
|
14093
|
-
if (state.events)
|
|
14094
|
-
state.events.exit?.("MultiLineImplicitObjectLiteralAllowed", state, result, eventData);
|
|
14095
|
-
return result;
|
|
14096
|
-
}
|
|
14097
|
-
}
|
|
14098
13957
|
var AllowNewlineBinaryOp$0 = $TV($EXPECT($L0, fail, 'AllowNewlineBinaryOp ""'), function($skip, $loc, $0, $1) {
|
|
14099
13958
|
module2.forbidNewlineBinaryOp.push(false);
|
|
14100
13959
|
});
|
|
@@ -14199,7 +14058,7 @@ ${input.slice(result.pos)}
|
|
|
14199
14058
|
return result;
|
|
14200
14059
|
}
|
|
14201
14060
|
}
|
|
14202
|
-
var AllowAll$0 = $S(AllowTrailingMemberProperty, AllowBracedApplication, AllowIndentedApplication,
|
|
14061
|
+
var AllowAll$0 = $S(AllowTrailingMemberProperty, AllowBracedApplication, AllowIndentedApplication, AllowClassImplicitCall, AllowNewlineBinaryOp);
|
|
14203
14062
|
function AllowAll(state) {
|
|
14204
14063
|
let eventData;
|
|
14205
14064
|
if (state.events) {
|
|
@@ -14222,7 +14081,7 @@ ${input.slice(result.pos)}
|
|
|
14222
14081
|
return result;
|
|
14223
14082
|
}
|
|
14224
14083
|
}
|
|
14225
|
-
var RestoreAll$0 = $S(RestoreTrailingMemberProperty, RestoreBracedApplication, RestoreIndentedApplication,
|
|
14084
|
+
var RestoreAll$0 = $S(RestoreTrailingMemberProperty, RestoreBracedApplication, RestoreIndentedApplication, RestoreClassImplicitCall, RestoreNewlineBinaryOp);
|
|
14226
14085
|
function RestoreAll(state) {
|
|
14227
14086
|
let eventData;
|
|
14228
14087
|
if (state.events) {
|
|
@@ -16825,7 +16684,7 @@ ${input.slice(result.pos)}
|
|
|
16825
16684
|
}
|
|
16826
16685
|
}
|
|
16827
16686
|
var StatementDelimiter$0 = SemicolonDelimiter;
|
|
16828
|
-
var StatementDelimiter$1 = $S($Y($S(
|
|
16687
|
+
var StatementDelimiter$1 = $S($Y($S(Nested, $C($EXPECT($L4, fail, 'StatementDelimiter "("'), $EXPECT($L114, fail, 'StatementDelimiter "["'), $EXPECT($L115, fail, 'StatementDelimiter "`"'), $EXPECT($L59, fail, 'StatementDelimiter "+"'), $EXPECT($L20, fail, 'StatementDelimiter "-"'), $EXPECT($L55, fail, 'StatementDelimiter "*"'), $EXPECT($L56, fail, 'StatementDelimiter "/"'), ObjectLiteral, Arrow, FatArrow, $S(Function, $E($S($E(_), Star)), $E(_), $EXPECT($L4, fail, 'StatementDelimiter "("'))))), InsertSemicolon);
|
|
16829
16688
|
var StatementDelimiter$2 = $Y(EOS);
|
|
16830
16689
|
function StatementDelimiter(state) {
|
|
16831
16690
|
let eventData;
|
|
@@ -17638,7 +17497,32 @@ ${input.slice(result.pos)}
|
|
|
17638
17497
|
return result;
|
|
17639
17498
|
}
|
|
17640
17499
|
}
|
|
17641
|
-
var
|
|
17500
|
+
var Each$0 = $TS($S($EXPECT($L138, fail, 'Each "each"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17501
|
+
return { $loc, token: $1 };
|
|
17502
|
+
});
|
|
17503
|
+
function Each(state) {
|
|
17504
|
+
let eventData;
|
|
17505
|
+
if (state.events) {
|
|
17506
|
+
const result = state.events.enter?.("Each", state);
|
|
17507
|
+
if (result) {
|
|
17508
|
+
if (result.cache)
|
|
17509
|
+
return result.cache;
|
|
17510
|
+
eventData = result.data;
|
|
17511
|
+
}
|
|
17512
|
+
}
|
|
17513
|
+
if (state.tokenize) {
|
|
17514
|
+
const result = $TOKEN("Each", state, Each$0(state));
|
|
17515
|
+
if (state.events)
|
|
17516
|
+
state.events.exit?.("Each", state, result, eventData);
|
|
17517
|
+
return result;
|
|
17518
|
+
} else {
|
|
17519
|
+
const result = Each$0(state);
|
|
17520
|
+
if (state.events)
|
|
17521
|
+
state.events.exit?.("Each", state, result, eventData);
|
|
17522
|
+
return result;
|
|
17523
|
+
}
|
|
17524
|
+
}
|
|
17525
|
+
var Else$0 = $TS($S($EXPECT($L139, fail, 'Else "else"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17642
17526
|
return { $loc, token: $1 };
|
|
17643
17527
|
});
|
|
17644
17528
|
function Else(state) {
|
|
@@ -17688,7 +17572,7 @@ ${input.slice(result.pos)}
|
|
|
17688
17572
|
return result;
|
|
17689
17573
|
}
|
|
17690
17574
|
}
|
|
17691
|
-
var Export$0 = $TS($S($EXPECT($
|
|
17575
|
+
var Export$0 = $TS($S($EXPECT($L140, fail, 'Export "export"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17692
17576
|
return { $loc, token: $1 };
|
|
17693
17577
|
});
|
|
17694
17578
|
function Export(state) {
|
|
@@ -17713,7 +17597,7 @@ ${input.slice(result.pos)}
|
|
|
17713
17597
|
return result;
|
|
17714
17598
|
}
|
|
17715
17599
|
}
|
|
17716
|
-
var Extends$0 = $TS($S($EXPECT($
|
|
17600
|
+
var Extends$0 = $TS($S($EXPECT($L141, fail, 'Extends "extends"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17717
17601
|
return { $loc, token: $1 };
|
|
17718
17602
|
});
|
|
17719
17603
|
function Extends(state) {
|
|
@@ -17738,7 +17622,7 @@ ${input.slice(result.pos)}
|
|
|
17738
17622
|
return result;
|
|
17739
17623
|
}
|
|
17740
17624
|
}
|
|
17741
|
-
var Finally$0 = $TS($S($EXPECT($
|
|
17625
|
+
var Finally$0 = $TS($S($EXPECT($L142, fail, 'Finally "finally"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17742
17626
|
return { $loc, token: $1 };
|
|
17743
17627
|
});
|
|
17744
17628
|
function Finally(state) {
|
|
@@ -17763,7 +17647,7 @@ ${input.slice(result.pos)}
|
|
|
17763
17647
|
return result;
|
|
17764
17648
|
}
|
|
17765
17649
|
}
|
|
17766
|
-
var For$0 = $TS($S($EXPECT($
|
|
17650
|
+
var For$0 = $TS($S($EXPECT($L143, fail, 'For "for"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17767
17651
|
return { $loc, token: $1 };
|
|
17768
17652
|
});
|
|
17769
17653
|
function For(state) {
|
|
@@ -17788,7 +17672,7 @@ ${input.slice(result.pos)}
|
|
|
17788
17672
|
return result;
|
|
17789
17673
|
}
|
|
17790
17674
|
}
|
|
17791
|
-
var From$0 = $TS($S($EXPECT($
|
|
17675
|
+
var From$0 = $TS($S($EXPECT($L144, fail, 'From "from"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17792
17676
|
return { $loc, token: $1 };
|
|
17793
17677
|
});
|
|
17794
17678
|
function From(state) {
|
|
@@ -17813,7 +17697,7 @@ ${input.slice(result.pos)}
|
|
|
17813
17697
|
return result;
|
|
17814
17698
|
}
|
|
17815
17699
|
}
|
|
17816
|
-
var Function$0 = $TS($S($EXPECT($
|
|
17700
|
+
var Function$0 = $TS($S($EXPECT($L145, fail, 'Function "function"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17817
17701
|
return { $loc, token: $1 };
|
|
17818
17702
|
});
|
|
17819
17703
|
function Function(state) {
|
|
@@ -17838,7 +17722,7 @@ ${input.slice(result.pos)}
|
|
|
17838
17722
|
return result;
|
|
17839
17723
|
}
|
|
17840
17724
|
}
|
|
17841
|
-
var GetOrSet$0 = $TS($S($C($EXPECT($
|
|
17725
|
+
var GetOrSet$0 = $TS($S($C($EXPECT($L146, fail, 'GetOrSet "get"'), $EXPECT($L147, fail, 'GetOrSet "set"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17842
17726
|
return { $loc, token: $1, type: "GetOrSet" };
|
|
17843
17727
|
});
|
|
17844
17728
|
function GetOrSet(state) {
|
|
@@ -17863,7 +17747,7 @@ ${input.slice(result.pos)}
|
|
|
17863
17747
|
return result;
|
|
17864
17748
|
}
|
|
17865
17749
|
}
|
|
17866
|
-
var If$0 = $TV($TEXT($S($EXPECT($
|
|
17750
|
+
var If$0 = $TV($TEXT($S($EXPECT($L148, fail, 'If "if"'), NonIdContinue, $E($EXPECT($L11, fail, 'If " "')))), function($skip, $loc, $0, $1) {
|
|
17867
17751
|
return { $loc, token: $1 };
|
|
17868
17752
|
});
|
|
17869
17753
|
function If(state) {
|
|
@@ -17913,7 +17797,7 @@ ${input.slice(result.pos)}
|
|
|
17913
17797
|
return result;
|
|
17914
17798
|
}
|
|
17915
17799
|
}
|
|
17916
|
-
var In$0 = $TS($S($EXPECT($
|
|
17800
|
+
var In$0 = $TS($S($EXPECT($L149, fail, 'In "in"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17917
17801
|
return { $loc, token: $1 };
|
|
17918
17802
|
});
|
|
17919
17803
|
function In(state) {
|
|
@@ -17938,7 +17822,7 @@ ${input.slice(result.pos)}
|
|
|
17938
17822
|
return result;
|
|
17939
17823
|
}
|
|
17940
17824
|
}
|
|
17941
|
-
var LetOrConst$0 = $TS($S($C($EXPECT($
|
|
17825
|
+
var LetOrConst$0 = $TS($S($C($EXPECT($L150, fail, 'LetOrConst "let"'), $EXPECT($L151, fail, 'LetOrConst "const"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17942
17826
|
return { $loc, token: $1 };
|
|
17943
17827
|
});
|
|
17944
17828
|
function LetOrConst(state) {
|
|
@@ -17963,7 +17847,7 @@ ${input.slice(result.pos)}
|
|
|
17963
17847
|
return result;
|
|
17964
17848
|
}
|
|
17965
17849
|
}
|
|
17966
|
-
var Const$0 = $TS($S($EXPECT($
|
|
17850
|
+
var Const$0 = $TS($S($EXPECT($L151, fail, 'Const "const"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17967
17851
|
return { $loc, token: $1 };
|
|
17968
17852
|
});
|
|
17969
17853
|
function Const(state) {
|
|
@@ -17988,7 +17872,7 @@ ${input.slice(result.pos)}
|
|
|
17988
17872
|
return result;
|
|
17989
17873
|
}
|
|
17990
17874
|
}
|
|
17991
|
-
var Is$0 = $TS($S($EXPECT($
|
|
17875
|
+
var Is$0 = $TS($S($EXPECT($L152, fail, 'Is "is"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
17992
17876
|
return { $loc, token: $1 };
|
|
17993
17877
|
});
|
|
17994
17878
|
function Is(state) {
|
|
@@ -18037,7 +17921,7 @@ ${input.slice(result.pos)}
|
|
|
18037
17921
|
return result;
|
|
18038
17922
|
}
|
|
18039
17923
|
}
|
|
18040
|
-
var Loop$0 = $TS($S($EXPECT($
|
|
17924
|
+
var Loop$0 = $TS($S($EXPECT($L153, fail, 'Loop "loop"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18041
17925
|
return { $loc, token: "while(true)" };
|
|
18042
17926
|
});
|
|
18043
17927
|
function Loop(state) {
|
|
@@ -18062,7 +17946,7 @@ ${input.slice(result.pos)}
|
|
|
18062
17946
|
return result;
|
|
18063
17947
|
}
|
|
18064
17948
|
}
|
|
18065
|
-
var New$0 = $TS($S($EXPECT($
|
|
17949
|
+
var New$0 = $TS($S($EXPECT($L154, fail, 'New "new"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18066
17950
|
return { $loc, token: $1 };
|
|
18067
17951
|
});
|
|
18068
17952
|
function New(state) {
|
|
@@ -18087,7 +17971,7 @@ ${input.slice(result.pos)}
|
|
|
18087
17971
|
return result;
|
|
18088
17972
|
}
|
|
18089
17973
|
}
|
|
18090
|
-
var Not$0 = $TS($S($EXPECT($
|
|
17974
|
+
var Not$0 = $TS($S($EXPECT($L155, fail, 'Not "not"'), NonIdContinue, $N($S($E(_), $EXPECT($L12, fail, 'Not ":"')))), function($skip, $loc, $0, $1, $2, $3) {
|
|
18091
17975
|
return { $loc, token: "!" };
|
|
18092
17976
|
});
|
|
18093
17977
|
function Not(state) {
|
|
@@ -18137,7 +18021,7 @@ ${input.slice(result.pos)}
|
|
|
18137
18021
|
return result;
|
|
18138
18022
|
}
|
|
18139
18023
|
}
|
|
18140
|
-
var OpenAngleBracket$0 = $TV($EXPECT($
|
|
18024
|
+
var OpenAngleBracket$0 = $TV($EXPECT($L156, fail, 'OpenAngleBracket "<"'), function($skip, $loc, $0, $1) {
|
|
18141
18025
|
return { $loc, token: $1 };
|
|
18142
18026
|
});
|
|
18143
18027
|
function OpenAngleBracket(state) {
|
|
@@ -18237,7 +18121,7 @@ ${input.slice(result.pos)}
|
|
|
18237
18121
|
return result;
|
|
18238
18122
|
}
|
|
18239
18123
|
}
|
|
18240
|
-
var Operator$0 = $TS($S($EXPECT($
|
|
18124
|
+
var Operator$0 = $TS($S($EXPECT($L157, fail, 'Operator "operator"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18241
18125
|
return { $loc, token: $1 };
|
|
18242
18126
|
});
|
|
18243
18127
|
function Operator(state) {
|
|
@@ -18262,7 +18146,7 @@ ${input.slice(result.pos)}
|
|
|
18262
18146
|
return result;
|
|
18263
18147
|
}
|
|
18264
18148
|
}
|
|
18265
|
-
var Public$0 = $TS($S($EXPECT($
|
|
18149
|
+
var Public$0 = $TS($S($EXPECT($L158, fail, 'Public "public"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18266
18150
|
return { $loc, token: $1 };
|
|
18267
18151
|
});
|
|
18268
18152
|
function Public(state) {
|
|
@@ -18287,7 +18171,7 @@ ${input.slice(result.pos)}
|
|
|
18287
18171
|
return result;
|
|
18288
18172
|
}
|
|
18289
18173
|
}
|
|
18290
|
-
var Private$0 = $TS($S($EXPECT($
|
|
18174
|
+
var Private$0 = $TS($S($EXPECT($L159, fail, 'Private "private"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18291
18175
|
return { $loc, token: $1 };
|
|
18292
18176
|
});
|
|
18293
18177
|
function Private(state) {
|
|
@@ -18312,7 +18196,7 @@ ${input.slice(result.pos)}
|
|
|
18312
18196
|
return result;
|
|
18313
18197
|
}
|
|
18314
18198
|
}
|
|
18315
|
-
var Protected$0 = $TS($S($EXPECT($
|
|
18199
|
+
var Protected$0 = $TS($S($EXPECT($L160, fail, 'Protected "protected"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18316
18200
|
return { $loc, token: $1 };
|
|
18317
18201
|
});
|
|
18318
18202
|
function Protected(state) {
|
|
@@ -18337,13 +18221,13 @@ ${input.slice(result.pos)}
|
|
|
18337
18221
|
return result;
|
|
18338
18222
|
}
|
|
18339
18223
|
}
|
|
18340
|
-
var Pipe$0 = $TV($C($EXPECT($
|
|
18224
|
+
var Pipe$0 = $TV($C($EXPECT($L161, fail, 'Pipe "||>"'), $EXPECT($L162, fail, 'Pipe "|\u25B7"')), function($skip, $loc, $0, $1) {
|
|
18341
18225
|
return { $loc, token: "||>" };
|
|
18342
18226
|
});
|
|
18343
|
-
var Pipe$1 = $TV($C($EXPECT($
|
|
18227
|
+
var Pipe$1 = $TV($C($EXPECT($L163, fail, 'Pipe "|>="'), $EXPECT($L164, fail, 'Pipe "\u25B7="')), function($skip, $loc, $0, $1) {
|
|
18344
18228
|
return { $loc, token: "|>=" };
|
|
18345
18229
|
});
|
|
18346
|
-
var Pipe$2 = $TV($C($EXPECT($
|
|
18230
|
+
var Pipe$2 = $TV($C($EXPECT($L165, fail, 'Pipe "|>"'), $EXPECT($L166, fail, 'Pipe "\u25B7"')), function($skip, $loc, $0, $1) {
|
|
18347
18231
|
return { $loc, token: "|>" };
|
|
18348
18232
|
});
|
|
18349
18233
|
function Pipe(state) {
|
|
@@ -18393,7 +18277,7 @@ ${input.slice(result.pos)}
|
|
|
18393
18277
|
return result;
|
|
18394
18278
|
}
|
|
18395
18279
|
}
|
|
18396
|
-
var Readonly$0 = $TS($S($EXPECT($
|
|
18280
|
+
var Readonly$0 = $TS($S($EXPECT($L167, fail, 'Readonly "readonly"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18397
18281
|
return { $loc, token: $1, ts: true };
|
|
18398
18282
|
});
|
|
18399
18283
|
function Readonly(state) {
|
|
@@ -18418,7 +18302,7 @@ ${input.slice(result.pos)}
|
|
|
18418
18302
|
return result;
|
|
18419
18303
|
}
|
|
18420
18304
|
}
|
|
18421
|
-
var Return$0 = $TS($S($EXPECT($
|
|
18305
|
+
var Return$0 = $TS($S($EXPECT($L168, fail, 'Return "return"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18422
18306
|
return { $loc, token: $1 };
|
|
18423
18307
|
});
|
|
18424
18308
|
function Return(state) {
|
|
@@ -18443,7 +18327,7 @@ ${input.slice(result.pos)}
|
|
|
18443
18327
|
return result;
|
|
18444
18328
|
}
|
|
18445
18329
|
}
|
|
18446
|
-
var Satisfies$0 = $TS($S($EXPECT($
|
|
18330
|
+
var Satisfies$0 = $TS($S($EXPECT($L169, fail, 'Satisfies "satisfies"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18447
18331
|
return { $loc, token: $1 };
|
|
18448
18332
|
});
|
|
18449
18333
|
function Satisfies(state) {
|
|
@@ -18493,7 +18377,7 @@ ${input.slice(result.pos)}
|
|
|
18493
18377
|
return result;
|
|
18494
18378
|
}
|
|
18495
18379
|
}
|
|
18496
|
-
var SingleQuote$0 = $TV($EXPECT($
|
|
18380
|
+
var SingleQuote$0 = $TV($EXPECT($L170, fail, `SingleQuote "'"`), function($skip, $loc, $0, $1) {
|
|
18497
18381
|
return { $loc, token: $1 };
|
|
18498
18382
|
});
|
|
18499
18383
|
function SingleQuote(state) {
|
|
@@ -18543,7 +18427,7 @@ ${input.slice(result.pos)}
|
|
|
18543
18427
|
return result;
|
|
18544
18428
|
}
|
|
18545
18429
|
}
|
|
18546
|
-
var Static$0 = $TS($S($EXPECT($
|
|
18430
|
+
var Static$0 = $TS($S($EXPECT($L171, fail, 'Static "static"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18547
18431
|
return { $loc, token: $1 };
|
|
18548
18432
|
});
|
|
18549
18433
|
var Static$1 = $TS($S($EXPECT($L118, fail, 'Static "@"'), $N($C($EXPECT($L4, fail, 'Static "("'), $EXPECT($L118, fail, 'Static "@"')))), function($skip, $loc, $0, $1, $2) {
|
|
@@ -18571,7 +18455,7 @@ ${input.slice(result.pos)}
|
|
|
18571
18455
|
return result;
|
|
18572
18456
|
}
|
|
18573
18457
|
}
|
|
18574
|
-
var SubstitutionStart$0 = $TV($EXPECT($
|
|
18458
|
+
var SubstitutionStart$0 = $TV($EXPECT($L172, fail, 'SubstitutionStart "${"'), function($skip, $loc, $0, $1) {
|
|
18575
18459
|
return { $loc, token: $1 };
|
|
18576
18460
|
});
|
|
18577
18461
|
function SubstitutionStart(state) {
|
|
@@ -18596,7 +18480,7 @@ ${input.slice(result.pos)}
|
|
|
18596
18480
|
return result;
|
|
18597
18481
|
}
|
|
18598
18482
|
}
|
|
18599
|
-
var Switch$0 = $TS($S($EXPECT($
|
|
18483
|
+
var Switch$0 = $TS($S($EXPECT($L173, fail, 'Switch "switch"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18600
18484
|
return { $loc, token: $1 };
|
|
18601
18485
|
});
|
|
18602
18486
|
function Switch(state) {
|
|
@@ -18621,7 +18505,7 @@ ${input.slice(result.pos)}
|
|
|
18621
18505
|
return result;
|
|
18622
18506
|
}
|
|
18623
18507
|
}
|
|
18624
|
-
var Target$0 = $TS($S($EXPECT($
|
|
18508
|
+
var Target$0 = $TS($S($EXPECT($L174, fail, 'Target "target"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18625
18509
|
return { $loc, token: $1 };
|
|
18626
18510
|
});
|
|
18627
18511
|
function Target(state) {
|
|
@@ -18646,7 +18530,7 @@ ${input.slice(result.pos)}
|
|
|
18646
18530
|
return result;
|
|
18647
18531
|
}
|
|
18648
18532
|
}
|
|
18649
|
-
var Then$0 = $TS($S(__, $EXPECT($
|
|
18533
|
+
var Then$0 = $TS($S(__, $EXPECT($L175, fail, 'Then "then"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3) {
|
|
18650
18534
|
return { $loc, token: "" };
|
|
18651
18535
|
});
|
|
18652
18536
|
function Then(state) {
|
|
@@ -18671,7 +18555,7 @@ ${input.slice(result.pos)}
|
|
|
18671
18555
|
return result;
|
|
18672
18556
|
}
|
|
18673
18557
|
}
|
|
18674
|
-
var This$0 = $TS($S($EXPECT($
|
|
18558
|
+
var This$0 = $TS($S($EXPECT($L176, fail, 'This "this"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18675
18559
|
return { $loc, token: $1 };
|
|
18676
18560
|
});
|
|
18677
18561
|
function This(state) {
|
|
@@ -18696,7 +18580,7 @@ ${input.slice(result.pos)}
|
|
|
18696
18580
|
return result;
|
|
18697
18581
|
}
|
|
18698
18582
|
}
|
|
18699
|
-
var Throw$0 = $TS($S($EXPECT($
|
|
18583
|
+
var Throw$0 = $TS($S($EXPECT($L177, fail, 'Throw "throw"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18700
18584
|
return { $loc, token: $1 };
|
|
18701
18585
|
});
|
|
18702
18586
|
function Throw(state) {
|
|
@@ -18721,7 +18605,7 @@ ${input.slice(result.pos)}
|
|
|
18721
18605
|
return result;
|
|
18722
18606
|
}
|
|
18723
18607
|
}
|
|
18724
|
-
var TripleDoubleQuote$0 = $TV($EXPECT($
|
|
18608
|
+
var TripleDoubleQuote$0 = $TV($EXPECT($L178, fail, 'TripleDoubleQuote "\\\\\\"\\\\\\"\\\\\\""'), function($skip, $loc, $0, $1) {
|
|
18725
18609
|
return { $loc, token: "`" };
|
|
18726
18610
|
});
|
|
18727
18611
|
function TripleDoubleQuote(state) {
|
|
@@ -18746,7 +18630,7 @@ ${input.slice(result.pos)}
|
|
|
18746
18630
|
return result;
|
|
18747
18631
|
}
|
|
18748
18632
|
}
|
|
18749
|
-
var TripleSingleQuote$0 = $TV($EXPECT($
|
|
18633
|
+
var TripleSingleQuote$0 = $TV($EXPECT($L179, fail, `TripleSingleQuote "'''"`), function($skip, $loc, $0, $1) {
|
|
18750
18634
|
return { $loc, token: "`" };
|
|
18751
18635
|
});
|
|
18752
18636
|
function TripleSingleQuote(state) {
|
|
@@ -18771,7 +18655,7 @@ ${input.slice(result.pos)}
|
|
|
18771
18655
|
return result;
|
|
18772
18656
|
}
|
|
18773
18657
|
}
|
|
18774
|
-
var TripleSlash$0 = $TV($EXPECT($
|
|
18658
|
+
var TripleSlash$0 = $TV($EXPECT($L180, fail, 'TripleSlash "///"'), function($skip, $loc, $0, $1) {
|
|
18775
18659
|
return { $loc, token: "/" };
|
|
18776
18660
|
});
|
|
18777
18661
|
function TripleSlash(state) {
|
|
@@ -18796,7 +18680,7 @@ ${input.slice(result.pos)}
|
|
|
18796
18680
|
return result;
|
|
18797
18681
|
}
|
|
18798
18682
|
}
|
|
18799
|
-
var TripleTick$0 = $TV($EXPECT($
|
|
18683
|
+
var TripleTick$0 = $TV($EXPECT($L181, fail, 'TripleTick "```"'), function($skip, $loc, $0, $1) {
|
|
18800
18684
|
return { $loc, token: "`" };
|
|
18801
18685
|
});
|
|
18802
18686
|
function TripleTick(state) {
|
|
@@ -18821,7 +18705,7 @@ ${input.slice(result.pos)}
|
|
|
18821
18705
|
return result;
|
|
18822
18706
|
}
|
|
18823
18707
|
}
|
|
18824
|
-
var Try$0 = $TS($S($EXPECT($
|
|
18708
|
+
var Try$0 = $TS($S($EXPECT($L182, fail, 'Try "try"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18825
18709
|
return { $loc, token: $1 };
|
|
18826
18710
|
});
|
|
18827
18711
|
function Try(state) {
|
|
@@ -18846,7 +18730,7 @@ ${input.slice(result.pos)}
|
|
|
18846
18730
|
return result;
|
|
18847
18731
|
}
|
|
18848
18732
|
}
|
|
18849
|
-
var Typeof$0 = $TS($S($EXPECT($
|
|
18733
|
+
var Typeof$0 = $TS($S($EXPECT($L183, fail, 'Typeof "typeof"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18850
18734
|
return { $loc, token: $1 };
|
|
18851
18735
|
});
|
|
18852
18736
|
function Typeof(state) {
|
|
@@ -18871,7 +18755,7 @@ ${input.slice(result.pos)}
|
|
|
18871
18755
|
return result;
|
|
18872
18756
|
}
|
|
18873
18757
|
}
|
|
18874
|
-
var Unless$0 = $TS($S($EXPECT($
|
|
18758
|
+
var Unless$0 = $TS($S($EXPECT($L184, fail, 'Unless "unless"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18875
18759
|
return { $loc, token: $1 };
|
|
18876
18760
|
});
|
|
18877
18761
|
function Unless(state) {
|
|
@@ -18896,7 +18780,7 @@ ${input.slice(result.pos)}
|
|
|
18896
18780
|
return result;
|
|
18897
18781
|
}
|
|
18898
18782
|
}
|
|
18899
|
-
var Until$0 = $TS($S($EXPECT($
|
|
18783
|
+
var Until$0 = $TS($S($EXPECT($L185, fail, 'Until "until"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18900
18784
|
return { $loc, token: $1 };
|
|
18901
18785
|
});
|
|
18902
18786
|
function Until(state) {
|
|
@@ -18921,7 +18805,7 @@ ${input.slice(result.pos)}
|
|
|
18921
18805
|
return result;
|
|
18922
18806
|
}
|
|
18923
18807
|
}
|
|
18924
|
-
var Var$0 = $TS($S($EXPECT($
|
|
18808
|
+
var Var$0 = $TS($S($EXPECT($L186, fail, 'Var "var"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18925
18809
|
return { $loc, token: $1 };
|
|
18926
18810
|
});
|
|
18927
18811
|
function Var(state) {
|
|
@@ -18946,7 +18830,7 @@ ${input.slice(result.pos)}
|
|
|
18946
18830
|
return result;
|
|
18947
18831
|
}
|
|
18948
18832
|
}
|
|
18949
|
-
var Void$0 = $TS($S($EXPECT($
|
|
18833
|
+
var Void$0 = $TS($S($EXPECT($L187, fail, 'Void "void"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18950
18834
|
return { $loc, token: $1 };
|
|
18951
18835
|
});
|
|
18952
18836
|
function Void(state) {
|
|
@@ -18971,7 +18855,7 @@ ${input.slice(result.pos)}
|
|
|
18971
18855
|
return result;
|
|
18972
18856
|
}
|
|
18973
18857
|
}
|
|
18974
|
-
var When$0 = $TS($S($EXPECT($
|
|
18858
|
+
var When$0 = $TS($S($EXPECT($L188, fail, 'When "when"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
18975
18859
|
return { $loc, token: "case" };
|
|
18976
18860
|
});
|
|
18977
18861
|
function When(state) {
|
|
@@ -18996,7 +18880,7 @@ ${input.slice(result.pos)}
|
|
|
18996
18880
|
return result;
|
|
18997
18881
|
}
|
|
18998
18882
|
}
|
|
18999
|
-
var While$0 = $TS($S($EXPECT($
|
|
18883
|
+
var While$0 = $TS($S($EXPECT($L189, fail, 'While "while"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
19000
18884
|
return { $loc, token: $1 };
|
|
19001
18885
|
});
|
|
19002
18886
|
function While(state) {
|
|
@@ -19021,7 +18905,7 @@ ${input.slice(result.pos)}
|
|
|
19021
18905
|
return result;
|
|
19022
18906
|
}
|
|
19023
18907
|
}
|
|
19024
|
-
var Yield$0 = $TS($S($EXPECT($
|
|
18908
|
+
var Yield$0 = $TS($S($EXPECT($L190, fail, 'Yield "yield"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
19025
18909
|
return { $loc, token: $1, type: "Yield" };
|
|
19026
18910
|
});
|
|
19027
18911
|
function Yield(state) {
|
|
@@ -19046,7 +18930,7 @@ ${input.slice(result.pos)}
|
|
|
19046
18930
|
return result;
|
|
19047
18931
|
}
|
|
19048
18932
|
}
|
|
19049
|
-
var JSXImplicitFragment$0 = $TS($S(JSXTag, $Q($S(
|
|
18933
|
+
var JSXImplicitFragment$0 = $TS($S(JSXTag, $Q($S(Nested, JSXTag))), function($skip, $loc, $0, $1, $2) {
|
|
19050
18934
|
const jsx = $2.length === 0 ? $1 : {
|
|
19051
18935
|
type: "JSXFragment",
|
|
19052
18936
|
children: [
|
|
@@ -19166,7 +19050,7 @@ ${input.slice(result.pos)}
|
|
|
19166
19050
|
return result;
|
|
19167
19051
|
}
|
|
19168
19052
|
}
|
|
19169
|
-
var JSXSelfClosingElement$0 = $TS($S($EXPECT($
|
|
19053
|
+
var JSXSelfClosingElement$0 = $TS($S($EXPECT($L156, fail, 'JSXSelfClosingElement "<"'), JSXElementName, $E(TypeArguments), $E(JSXAttributes), $E(Whitespace), $EXPECT($L191, fail, 'JSXSelfClosingElement "/>"')), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
|
|
19170
19054
|
return { type: "JSXElement", children: $0, tag: $2 };
|
|
19171
19055
|
});
|
|
19172
19056
|
function JSXSelfClosingElement(state) {
|
|
@@ -19242,7 +19126,7 @@ ${input.slice(result.pos)}
|
|
|
19242
19126
|
return result;
|
|
19243
19127
|
}
|
|
19244
19128
|
}
|
|
19245
|
-
var JSXOpeningElement$0 = $S($EXPECT($
|
|
19129
|
+
var JSXOpeningElement$0 = $S($EXPECT($L156, fail, 'JSXOpeningElement "<"'), JSXElementName, $E(TypeArguments), $E(JSXAttributes), $E(Whitespace), $EXPECT($L34, fail, 'JSXOpeningElement ">"'));
|
|
19246
19130
|
function JSXOpeningElement(state) {
|
|
19247
19131
|
let eventData;
|
|
19248
19132
|
if (state.events) {
|
|
@@ -19294,7 +19178,7 @@ ${input.slice(result.pos)}
|
|
|
19294
19178
|
return result;
|
|
19295
19179
|
}
|
|
19296
19180
|
}
|
|
19297
|
-
var JSXClosingElement$0 = $S($EXPECT($
|
|
19181
|
+
var JSXClosingElement$0 = $S($EXPECT($L192, fail, 'JSXClosingElement "</"'), $E(Whitespace), JSXElementName, $E(Whitespace), $EXPECT($L34, fail, 'JSXClosingElement ">"'));
|
|
19298
19182
|
function JSXClosingElement(state) {
|
|
19299
19183
|
let eventData;
|
|
19300
19184
|
if (state.events) {
|
|
@@ -19332,7 +19216,7 @@ ${input.slice(result.pos)}
|
|
|
19332
19216
|
];
|
|
19333
19217
|
return { type: "JSXFragment", children: parts, jsxChildren: children.jsxChildren };
|
|
19334
19218
|
});
|
|
19335
|
-
var JSXFragment$1 = $TS($S(CoffeeJSXEnabled, $EXPECT($
|
|
19219
|
+
var JSXFragment$1 = $TS($S(CoffeeJSXEnabled, $EXPECT($L193, fail, 'JSXFragment "<>"'), $E(JSXChildren), $E(Whitespace), JSXClosingFragment), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
19336
19220
|
var children = $3;
|
|
19337
19221
|
$0 = $0.slice(1);
|
|
19338
19222
|
return {
|
|
@@ -19363,7 +19247,7 @@ ${input.slice(result.pos)}
|
|
|
19363
19247
|
return result;
|
|
19364
19248
|
}
|
|
19365
19249
|
}
|
|
19366
|
-
var PushJSXOpeningFragment$0 = $TV($EXPECT($
|
|
19250
|
+
var PushJSXOpeningFragment$0 = $TV($EXPECT($L193, fail, 'PushJSXOpeningFragment "<>"'), function($skip, $loc, $0, $1) {
|
|
19367
19251
|
module2.JSXTagStack.push("");
|
|
19368
19252
|
return $1;
|
|
19369
19253
|
});
|
|
@@ -19417,7 +19301,7 @@ ${input.slice(result.pos)}
|
|
|
19417
19301
|
return result;
|
|
19418
19302
|
}
|
|
19419
19303
|
}
|
|
19420
|
-
var JSXClosingFragment$0 = $EXPECT($
|
|
19304
|
+
var JSXClosingFragment$0 = $EXPECT($L194, fail, 'JSXClosingFragment "</>"');
|
|
19421
19305
|
function JSXClosingFragment(state) {
|
|
19422
19306
|
let eventData;
|
|
19423
19307
|
if (state.events) {
|
|
@@ -20386,7 +20270,7 @@ ${input.slice(result.pos)}
|
|
|
20386
20270
|
return result;
|
|
20387
20271
|
}
|
|
20388
20272
|
}
|
|
20389
|
-
var JSXComment$0 = $TS($S($EXPECT($
|
|
20273
|
+
var JSXComment$0 = $TS($S($EXPECT($L195, fail, 'JSXComment "<!--"'), JSXCommentContent, $EXPECT($L196, fail, 'JSXComment "-->"')), function($skip, $loc, $0, $1, $2, $3) {
|
|
20390
20274
|
return ["{/*", $2, "*/}"];
|
|
20391
20275
|
});
|
|
20392
20276
|
function JSXComment(state) {
|
|
@@ -20566,7 +20450,7 @@ ${input.slice(result.pos)}
|
|
|
20566
20450
|
return result;
|
|
20567
20451
|
}
|
|
20568
20452
|
}
|
|
20569
|
-
var TypeDeclarationRest$0 = $S(TypeKeyword, $E(_), IdentifierName, $E(TypeParameters),
|
|
20453
|
+
var TypeDeclarationRest$0 = $S(TypeKeyword, $E(_), IdentifierName, $E(TypeParameters), OptionalEquals, $C($S($E(_), Type), $S(__, Type)));
|
|
20570
20454
|
var TypeDeclarationRest$1 = $S(Interface, $E(_), IdentifierName, $E(TypeParameters), $E(InterfaceExtendsClause), InterfaceBlock);
|
|
20571
20455
|
var TypeDeclarationRest$2 = $S(Namespace, $E(_), IdentifierName, ModuleBlock);
|
|
20572
20456
|
var TypeDeclarationRest$3 = FunctionSignature;
|
|
@@ -20592,6 +20476,32 @@ ${input.slice(result.pos)}
|
|
|
20592
20476
|
return result;
|
|
20593
20477
|
}
|
|
20594
20478
|
}
|
|
20479
|
+
var OptionalEquals$0 = $S(__, Equals);
|
|
20480
|
+
var OptionalEquals$1 = $T($S($Y(IndentedFurther), InsertSpaceEquals), function(value) {
|
|
20481
|
+
return value[1];
|
|
20482
|
+
});
|
|
20483
|
+
function OptionalEquals(state) {
|
|
20484
|
+
let eventData;
|
|
20485
|
+
if (state.events) {
|
|
20486
|
+
const result = state.events.enter?.("OptionalEquals", state);
|
|
20487
|
+
if (result) {
|
|
20488
|
+
if (result.cache)
|
|
20489
|
+
return result.cache;
|
|
20490
|
+
eventData = result.data;
|
|
20491
|
+
}
|
|
20492
|
+
}
|
|
20493
|
+
if (state.tokenize) {
|
|
20494
|
+
const result = $TOKEN("OptionalEquals", state, OptionalEquals$0(state) || OptionalEquals$1(state));
|
|
20495
|
+
if (state.events)
|
|
20496
|
+
state.events.exit?.("OptionalEquals", state, result, eventData);
|
|
20497
|
+
return result;
|
|
20498
|
+
} else {
|
|
20499
|
+
const result = OptionalEquals$0(state) || OptionalEquals$1(state);
|
|
20500
|
+
if (state.events)
|
|
20501
|
+
state.events.exit?.("OptionalEquals", state, result, eventData);
|
|
20502
|
+
return result;
|
|
20503
|
+
}
|
|
20504
|
+
}
|
|
20595
20505
|
var TypeLexicalDeclaration$0 = $S(__, LetOrConstOrVar, TypeDeclarationBinding, $Q($S(CommaDelimiter, __, TypeDeclarationBinding)));
|
|
20596
20506
|
var TypeLexicalDeclaration$1 = $S(__, EnumDeclaration);
|
|
20597
20507
|
var TypeLexicalDeclaration$2 = ClassSignature;
|
|
@@ -20689,7 +20599,7 @@ ${input.slice(result.pos)}
|
|
|
20689
20599
|
return result;
|
|
20690
20600
|
}
|
|
20691
20601
|
}
|
|
20692
|
-
var TypeKeyword$0 = $TS($S($EXPECT($
|
|
20602
|
+
var TypeKeyword$0 = $TS($S($EXPECT($L197, fail, 'TypeKeyword "type"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
20693
20603
|
return { $loc, token: $1 };
|
|
20694
20604
|
});
|
|
20695
20605
|
function TypeKeyword(state) {
|
|
@@ -20714,7 +20624,7 @@ ${input.slice(result.pos)}
|
|
|
20714
20624
|
return result;
|
|
20715
20625
|
}
|
|
20716
20626
|
}
|
|
20717
|
-
var Enum$0 = $TS($S($EXPECT($
|
|
20627
|
+
var Enum$0 = $TS($S($EXPECT($L198, fail, 'Enum "enum"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
20718
20628
|
return { $loc, token: $1 };
|
|
20719
20629
|
});
|
|
20720
20630
|
function Enum(state) {
|
|
@@ -20739,7 +20649,7 @@ ${input.slice(result.pos)}
|
|
|
20739
20649
|
return result;
|
|
20740
20650
|
}
|
|
20741
20651
|
}
|
|
20742
|
-
var Interface$0 = $TS($S($EXPECT($
|
|
20652
|
+
var Interface$0 = $TS($S($EXPECT($L199, fail, 'Interface "interface"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
20743
20653
|
return { $loc, token: $1 };
|
|
20744
20654
|
});
|
|
20745
20655
|
function Interface(state) {
|
|
@@ -20764,7 +20674,7 @@ ${input.slice(result.pos)}
|
|
|
20764
20674
|
return result;
|
|
20765
20675
|
}
|
|
20766
20676
|
}
|
|
20767
|
-
var Global$0 = $TS($S($EXPECT($
|
|
20677
|
+
var Global$0 = $TS($S($EXPECT($L200, fail, 'Global "global"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
20768
20678
|
return { $loc, token: $1 };
|
|
20769
20679
|
});
|
|
20770
20680
|
function Global(state) {
|
|
@@ -20789,7 +20699,7 @@ ${input.slice(result.pos)}
|
|
|
20789
20699
|
return result;
|
|
20790
20700
|
}
|
|
20791
20701
|
}
|
|
20792
|
-
var Module$0 = $TS($S($EXPECT($
|
|
20702
|
+
var Module$0 = $TS($S($EXPECT($L201, fail, 'Module "module"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
20793
20703
|
return { $loc, token: $1 };
|
|
20794
20704
|
});
|
|
20795
20705
|
function Module(state) {
|
|
@@ -20814,7 +20724,7 @@ ${input.slice(result.pos)}
|
|
|
20814
20724
|
return result;
|
|
20815
20725
|
}
|
|
20816
20726
|
}
|
|
20817
|
-
var Namespace$0 = $TS($S($EXPECT($
|
|
20727
|
+
var Namespace$0 = $TS($S($EXPECT($L202, fail, 'Namespace "namespace"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
20818
20728
|
return { $loc, token: $1 };
|
|
20819
20729
|
});
|
|
20820
20730
|
function Namespace(state) {
|
|
@@ -21508,7 +21418,7 @@ ${input.slice(result.pos)}
|
|
|
21508
21418
|
return result;
|
|
21509
21419
|
}
|
|
21510
21420
|
}
|
|
21511
|
-
var ReturnType$0 = $TS($S($E($S(__, $EXPECT($
|
|
21421
|
+
var ReturnType$0 = $TS($S($E($S(__, $EXPECT($L203, fail, 'ReturnType "asserts"'), NonIdContinue)), TypePredicate), function($skip, $loc, $0, $1, $2) {
|
|
21512
21422
|
var asserts = $1;
|
|
21513
21423
|
var t = $2;
|
|
21514
21424
|
if (asserts) {
|
|
@@ -21548,7 +21458,7 @@ ${input.slice(result.pos)}
|
|
|
21548
21458
|
return result;
|
|
21549
21459
|
}
|
|
21550
21460
|
}
|
|
21551
|
-
var TypePredicate$0 = $TS($S(Type, $E($S(__, $EXPECT($
|
|
21461
|
+
var TypePredicate$0 = $TS($S(Type, $E($S(__, $EXPECT($L152, fail, 'TypePredicate "is"'), NonIdContinue, Type))), function($skip, $loc, $0, $1, $2) {
|
|
21552
21462
|
var lhs = $1;
|
|
21553
21463
|
var rhs = $2;
|
|
21554
21464
|
if (!rhs)
|
|
@@ -21690,10 +21600,10 @@ ${input.slice(result.pos)}
|
|
|
21690
21600
|
return result;
|
|
21691
21601
|
}
|
|
21692
21602
|
}
|
|
21693
|
-
var TypeUnaryOp$0 = $S($EXPECT($
|
|
21694
|
-
var TypeUnaryOp$1 = $S($EXPECT($
|
|
21695
|
-
var TypeUnaryOp$2 = $S($EXPECT($
|
|
21696
|
-
var TypeUnaryOp$3 = $S($EXPECT($
|
|
21603
|
+
var TypeUnaryOp$0 = $S($EXPECT($L204, fail, 'TypeUnaryOp "keyof"'), NonIdContinue);
|
|
21604
|
+
var TypeUnaryOp$1 = $S($EXPECT($L183, fail, 'TypeUnaryOp "typeof"'), NonIdContinue);
|
|
21605
|
+
var TypeUnaryOp$2 = $S($EXPECT($L205, fail, 'TypeUnaryOp "infer"'), NonIdContinue);
|
|
21606
|
+
var TypeUnaryOp$3 = $S($EXPECT($L167, fail, 'TypeUnaryOp "readonly"'), NonIdContinue);
|
|
21697
21607
|
function TypeUnaryOp(state) {
|
|
21698
21608
|
let eventData;
|
|
21699
21609
|
if (state.events) {
|
|
@@ -21739,10 +21649,10 @@ ${input.slice(result.pos)}
|
|
|
21739
21649
|
return result;
|
|
21740
21650
|
}
|
|
21741
21651
|
}
|
|
21742
|
-
var TypePrimary$0 =
|
|
21743
|
-
var TypePrimary$1 =
|
|
21744
|
-
var TypePrimary$2 = $S($E(_),
|
|
21745
|
-
var TypePrimary$3 = $S($E(_),
|
|
21652
|
+
var TypePrimary$0 = $S($E(_), TypeTuple);
|
|
21653
|
+
var TypePrimary$1 = InterfaceBlock;
|
|
21654
|
+
var TypePrimary$2 = $S($E(_), FunctionType);
|
|
21655
|
+
var TypePrimary$3 = $S($E(_), InlineInterfaceLiteral);
|
|
21746
21656
|
var TypePrimary$4 = $S($E(_), ImportType);
|
|
21747
21657
|
var TypePrimary$5 = $TS($S($E(_), TypeLiteral), function($skip, $loc, $0, $1, $2) {
|
|
21748
21658
|
var t = $2;
|
|
@@ -21855,25 +21765,34 @@ ${input.slice(result.pos)}
|
|
|
21855
21765
|
return result;
|
|
21856
21766
|
}
|
|
21857
21767
|
}
|
|
21858
|
-
var TypeElement$0 = $TS($S(__, IdentifierName, $E(_), DotDotDot, $S(__, $E($S(QuestionMark, $E(_))), Colon, __), Type), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
|
|
21768
|
+
var TypeElement$0 = $TS($S(__, $E($S(DotDotDot, __)), IdentifierName, $E($S($E(_), DotDotDot)), $S(__, $E($S(QuestionMark, $E(_))), Colon, __), Type), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
|
|
21859
21769
|
var ws = $1;
|
|
21860
|
-
var
|
|
21861
|
-
var
|
|
21862
|
-
var
|
|
21770
|
+
var dots1 = $2;
|
|
21771
|
+
var name = $3;
|
|
21772
|
+
var dots2 = $4;
|
|
21863
21773
|
var colon = $5;
|
|
21864
21774
|
var type = $6;
|
|
21865
|
-
|
|
21775
|
+
let dots = dots1 || dots2 && [dots2[1], dots2[0]];
|
|
21776
|
+
if (dots1 && dots2) {
|
|
21777
|
+
dots = [dots, {
|
|
21778
|
+
type: "Error",
|
|
21779
|
+
message: "... both before and after identifier"
|
|
21780
|
+
}];
|
|
21781
|
+
}
|
|
21782
|
+
return [ws, dots, name, colon, type];
|
|
21866
21783
|
});
|
|
21867
|
-
var TypeElement$1 = $
|
|
21784
|
+
var TypeElement$1 = $S(__, DotDotDot, __, Type);
|
|
21785
|
+
var TypeElement$2 = $TS($S(Type, $E($S($E(_), DotDotDot))), function($skip, $loc, $0, $1, $2) {
|
|
21868
21786
|
var type = $1;
|
|
21869
|
-
var
|
|
21870
|
-
|
|
21787
|
+
var spaceDots = $2;
|
|
21788
|
+
if (!spaceDots)
|
|
21789
|
+
return type;
|
|
21790
|
+
const [space, dots] = spaceDots;
|
|
21871
21791
|
const ws = getTrimmingSpace(type);
|
|
21872
21792
|
if (!ws)
|
|
21873
21793
|
return [dots, space, type];
|
|
21874
21794
|
return [ws, dots, space, insertTrimmingSpace(type, "")];
|
|
21875
21795
|
});
|
|
21876
|
-
var TypeElement$2 = $S($E($S(__, DotDotDot)), $E($S(__, IdentifierName, __, $E($S(QuestionMark, $E(_))), Colon, __)), Type);
|
|
21877
21796
|
function TypeElement(state) {
|
|
21878
21797
|
let eventData;
|
|
21879
21798
|
if (state.events) {
|
|
@@ -21947,7 +21866,7 @@ ${input.slice(result.pos)}
|
|
|
21947
21866
|
return result;
|
|
21948
21867
|
}
|
|
21949
21868
|
}
|
|
21950
|
-
var TypeConditional$0 = $TS($S(TypeBinary, $E($S(__, $EXPECT($
|
|
21869
|
+
var TypeConditional$0 = $TS($S(TypeBinary, $E($S(__, $EXPECT($L141, fail, 'TypeConditional "extends"'), NonIdContinue, Type, $E($S(__, QuestionMark, Type, __, Colon, Type))))), function($skip, $loc, $0, $1, $2) {
|
|
21951
21870
|
if ($2)
|
|
21952
21871
|
return $0;
|
|
21953
21872
|
return $1;
|
|
@@ -22079,10 +21998,10 @@ ${input.slice(result.pos)}
|
|
|
22079
21998
|
}
|
|
22080
21999
|
var TypeLiteral$0 = TypeTemplateLiteral;
|
|
22081
22000
|
var TypeLiteral$1 = Literal;
|
|
22082
|
-
var TypeLiteral$2 = $TS($S($EXPECT($
|
|
22001
|
+
var TypeLiteral$2 = $TS($S($EXPECT($L187, fail, 'TypeLiteral "void"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
22083
22002
|
return { type: "VoidType", $loc, token: $1 };
|
|
22084
22003
|
});
|
|
22085
|
-
var TypeLiteral$3 = $TV($EXPECT($
|
|
22004
|
+
var TypeLiteral$3 = $TV($EXPECT($L206, fail, 'TypeLiteral "[]"'), function($skip, $loc, $0, $1) {
|
|
22086
22005
|
return { $loc, token: "[]" };
|
|
22087
22006
|
});
|
|
22088
22007
|
function TypeLiteral(state) {
|
|
@@ -22263,7 +22182,7 @@ ${input.slice(result.pos)}
|
|
|
22263
22182
|
return result;
|
|
22264
22183
|
}
|
|
22265
22184
|
}
|
|
22266
|
-
var TypeArguments$0 = $TS($S($EXPECT($
|
|
22185
|
+
var TypeArguments$0 = $TS($S($EXPECT($L156, fail, 'TypeArguments "<"'), $P(TypeArgument), __, $EXPECT($L34, fail, 'TypeArguments ">"')), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
22267
22186
|
var args = $2;
|
|
22268
22187
|
return { ts: true, types: args.map(([, t]) => t), children: $0 };
|
|
22269
22188
|
});
|
|
@@ -22335,7 +22254,7 @@ ${input.slice(result.pos)}
|
|
|
22335
22254
|
return result;
|
|
22336
22255
|
}
|
|
22337
22256
|
}
|
|
22338
|
-
var TypeParameters$0 = $TS($S($E(_), $EXPECT($
|
|
22257
|
+
var TypeParameters$0 = $TS($S($E(_), $EXPECT($L156, fail, 'TypeParameters "<"'), $P(TypeParameter), __, $EXPECT($L34, fail, 'TypeParameters ">"')), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
22339
22258
|
var parameters = $3;
|
|
22340
22259
|
return {
|
|
22341
22260
|
type: "TypeParameters",
|
|
@@ -22366,7 +22285,7 @@ ${input.slice(result.pos)}
|
|
|
22366
22285
|
return result;
|
|
22367
22286
|
}
|
|
22368
22287
|
}
|
|
22369
|
-
var TypeParameter$0 = $S(__, $E($S($EXPECT($
|
|
22288
|
+
var TypeParameter$0 = $S(__, $E($S($EXPECT($L151, fail, 'TypeParameter "const"'), $E(_))), Identifier, $E(TypeConstraint), $E(TypeInitializer), TypeParameterDelimiter);
|
|
22370
22289
|
function TypeParameter(state) {
|
|
22371
22290
|
let eventData;
|
|
22372
22291
|
if (state.events) {
|
|
@@ -22389,7 +22308,7 @@ ${input.slice(result.pos)}
|
|
|
22389
22308
|
return result;
|
|
22390
22309
|
}
|
|
22391
22310
|
}
|
|
22392
|
-
var TypeConstraint$0 = $S(__, $EXPECT($
|
|
22311
|
+
var TypeConstraint$0 = $S(__, $EXPECT($L141, fail, 'TypeConstraint "extends"'), NonIdContinue, Type);
|
|
22393
22312
|
function TypeConstraint(state) {
|
|
22394
22313
|
let eventData;
|
|
22395
22314
|
if (state.events) {
|
|
@@ -22540,7 +22459,7 @@ ${input.slice(result.pos)}
|
|
|
22540
22459
|
return result;
|
|
22541
22460
|
}
|
|
22542
22461
|
}
|
|
22543
|
-
var CivetPrologueContent$0 = $TS($S($EXPECT($
|
|
22462
|
+
var CivetPrologueContent$0 = $TS($S($EXPECT($L207, fail, 'CivetPrologueContent "civet"'), NonIdContinue, $Q(CivetOption), $EXPECT($R63, fail, "CivetPrologueContent /[\\s]*/")), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
22544
22463
|
var options = $3;
|
|
22545
22464
|
return {
|
|
22546
22465
|
type: "CivetPrologue",
|
|
@@ -22976,6 +22895,31 @@ ${input.slice(result.pos)}
|
|
|
22976
22895
|
return result;
|
|
22977
22896
|
}
|
|
22978
22897
|
}
|
|
22898
|
+
var InsertSpaceEquals$0 = $TV($EXPECT($L0, fail, 'InsertSpaceEquals ""'), function($skip, $loc, $0, $1) {
|
|
22899
|
+
return { $loc, token: " =" };
|
|
22900
|
+
});
|
|
22901
|
+
function InsertSpaceEquals(state) {
|
|
22902
|
+
let eventData;
|
|
22903
|
+
if (state.events) {
|
|
22904
|
+
const result = state.events.enter?.("InsertSpaceEquals", state);
|
|
22905
|
+
if (result) {
|
|
22906
|
+
if (result.cache)
|
|
22907
|
+
return result.cache;
|
|
22908
|
+
eventData = result.data;
|
|
22909
|
+
}
|
|
22910
|
+
}
|
|
22911
|
+
if (state.tokenize) {
|
|
22912
|
+
const result = $TOKEN("InsertSpaceEquals", state, InsertSpaceEquals$0(state));
|
|
22913
|
+
if (state.events)
|
|
22914
|
+
state.events.exit?.("InsertSpaceEquals", state, result, eventData);
|
|
22915
|
+
return result;
|
|
22916
|
+
} else {
|
|
22917
|
+
const result = InsertSpaceEquals$0(state);
|
|
22918
|
+
if (state.events)
|
|
22919
|
+
state.events.exit?.("InsertSpaceEquals", state, result, eventData);
|
|
22920
|
+
return result;
|
|
22921
|
+
}
|
|
22922
|
+
}
|
|
22979
22923
|
var InsertConst$0 = $TV($EXPECT($L0, fail, 'InsertConst ""'), function($skip, $loc, $0, $1) {
|
|
22980
22924
|
return { $loc, token: "const " };
|
|
22981
22925
|
});
|
|
@@ -23588,7 +23532,6 @@ ${input.slice(result.pos)}
|
|
|
23588
23532
|
module2.forbidIndentedApplication = [false];
|
|
23589
23533
|
module2.forbidBracedApplication = [false];
|
|
23590
23534
|
module2.forbidTrailingMemberProperty = [false];
|
|
23591
|
-
module2.forbidMultiLineImplicitObjectLiteral = [false];
|
|
23592
23535
|
module2.forbidNewlineBinaryOp = [false];
|
|
23593
23536
|
module2.JSXTagStack = [];
|
|
23594
23537
|
module2.operators = /* @__PURE__ */ new Set();
|
|
@@ -23625,12 +23568,6 @@ ${input.slice(result.pos)}
|
|
|
23625
23568
|
return s[s.length - 1];
|
|
23626
23569
|
}
|
|
23627
23570
|
},
|
|
23628
|
-
multiLineImplicitObjectLiteralForbidden: {
|
|
23629
|
-
get() {
|
|
23630
|
-
const { forbidMultiLineImplicitObjectLiteral: s } = module2;
|
|
23631
|
-
return s[s.length - 1];
|
|
23632
|
-
}
|
|
23633
|
-
},
|
|
23634
23571
|
newlineBinaryOpForbidden: {
|
|
23635
23572
|
get() {
|
|
23636
23573
|
const { forbidNewlineBinaryOp: s } = module2;
|
|
@@ -23765,11 +23702,7 @@ ${input.slice(result.pos)}
|
|
|
23765
23702
|
module2.getRef = function(base) {
|
|
23766
23703
|
if (refs.hasOwnProperty(base))
|
|
23767
23704
|
return refs[base];
|
|
23768
|
-
const ref =
|
|
23769
|
-
type: "Ref",
|
|
23770
|
-
base,
|
|
23771
|
-
id: base
|
|
23772
|
-
};
|
|
23705
|
+
const ref = makeRef(base);
|
|
23773
23706
|
if (declareRef.hasOwnProperty(base))
|
|
23774
23707
|
declareRef[base](ref);
|
|
23775
23708
|
return refs[base] = ref;
|
|
@@ -23933,19 +23866,11 @@ ${input.slice(result.pos)}
|
|
|
23933
23866
|
return result;
|
|
23934
23867
|
}
|
|
23935
23868
|
}
|
|
23936
|
-
var
|
|
23937
|
-
|
|
23938
|
-
const { level } = indent;
|
|
23939
|
-
const currentIndentLevel = module2.currentIndent.level;
|
|
23940
|
-
if (level === currentIndentLevel) {
|
|
23941
|
-
return $0;
|
|
23942
|
-
}
|
|
23943
|
-
return $skip;
|
|
23944
|
-
});
|
|
23945
|
-
function Samedent(state) {
|
|
23869
|
+
var PushIndent$0 = $Y($S(EOS, TrackIndented));
|
|
23870
|
+
function PushIndent(state) {
|
|
23946
23871
|
let eventData;
|
|
23947
23872
|
if (state.events) {
|
|
23948
|
-
const result = state.events.enter?.("
|
|
23873
|
+
const result = state.events.enter?.("PushIndent", state);
|
|
23949
23874
|
if (result) {
|
|
23950
23875
|
if (result.cache)
|
|
23951
23876
|
return result.cache;
|
|
@@ -23953,30 +23878,27 @@ ${input.slice(result.pos)}
|
|
|
23953
23878
|
}
|
|
23954
23879
|
}
|
|
23955
23880
|
if (state.tokenize) {
|
|
23956
|
-
const result = $TOKEN("
|
|
23881
|
+
const result = $TOKEN("PushIndent", state, PushIndent$0(state));
|
|
23957
23882
|
if (state.events)
|
|
23958
|
-
state.events.exit?.("
|
|
23883
|
+
state.events.exit?.("PushIndent", state, result, eventData);
|
|
23959
23884
|
return result;
|
|
23960
23885
|
} else {
|
|
23961
|
-
const result =
|
|
23886
|
+
const result = PushIndent$0(state);
|
|
23962
23887
|
if (state.events)
|
|
23963
|
-
state.events.exit?.("
|
|
23888
|
+
state.events.exit?.("PushIndent", state, result, eventData);
|
|
23964
23889
|
return result;
|
|
23965
23890
|
}
|
|
23966
23891
|
}
|
|
23967
|
-
var
|
|
23968
|
-
|
|
23969
|
-
|
|
23970
|
-
const currentIndentLevel = module2.currentIndent.level;
|
|
23971
|
-
if (level > currentIndentLevel) {
|
|
23972
|
-
return $0;
|
|
23892
|
+
var PopIndent$0 = $TV($EXPECT($L0, fail, 'PopIndent ""'), function($skip, $loc, $0, $1) {
|
|
23893
|
+
if (module2.config.verbose) {
|
|
23894
|
+
console.log("popping indent", module2.indentLevels[module2.indentLevels.length - 1], "->", module2.indentLevels[module2.indentLevels.length - 2]);
|
|
23973
23895
|
}
|
|
23974
|
-
|
|
23896
|
+
module2.indentLevels.pop();
|
|
23975
23897
|
});
|
|
23976
|
-
function
|
|
23898
|
+
function PopIndent(state) {
|
|
23977
23899
|
let eventData;
|
|
23978
23900
|
if (state.events) {
|
|
23979
|
-
const result = state.events.enter?.("
|
|
23901
|
+
const result = state.events.enter?.("PopIndent", state);
|
|
23980
23902
|
if (result) {
|
|
23981
23903
|
if (result.cache)
|
|
23982
23904
|
return result.cache;
|
|
@@ -23984,29 +23906,30 @@ ${input.slice(result.pos)}
|
|
|
23984
23906
|
}
|
|
23985
23907
|
}
|
|
23986
23908
|
if (state.tokenize) {
|
|
23987
|
-
const result = $TOKEN("
|
|
23909
|
+
const result = $TOKEN("PopIndent", state, PopIndent$0(state));
|
|
23988
23910
|
if (state.events)
|
|
23989
|
-
state.events.exit?.("
|
|
23911
|
+
state.events.exit?.("PopIndent", state, result, eventData);
|
|
23990
23912
|
return result;
|
|
23991
23913
|
} else {
|
|
23992
|
-
const result =
|
|
23914
|
+
const result = PopIndent$0(state);
|
|
23993
23915
|
if (state.events)
|
|
23994
|
-
state.events.exit?.("
|
|
23916
|
+
state.events.exit?.("PopIndent", state, result, eventData);
|
|
23995
23917
|
return result;
|
|
23996
23918
|
}
|
|
23997
23919
|
}
|
|
23998
|
-
var
|
|
23999
|
-
|
|
24000
|
-
if (
|
|
24001
|
-
|
|
24002
|
-
if (
|
|
24003
|
-
|
|
24004
|
-
|
|
23920
|
+
var Nested$0 = $TS($S(EOS, Indent), function($skip, $loc, $0, $1, $2) {
|
|
23921
|
+
var indent = $2;
|
|
23922
|
+
if (indent.level === module2.currentIndent.level)
|
|
23923
|
+
return $0;
|
|
23924
|
+
if (module2.config.verbose) {
|
|
23925
|
+
console.log(`failing Nested: ${indent.level} does not match current indent level ${module2.currentIndent.level}`);
|
|
23926
|
+
}
|
|
23927
|
+
return $skip;
|
|
24005
23928
|
});
|
|
24006
|
-
function
|
|
23929
|
+
function Nested(state) {
|
|
24007
23930
|
let eventData;
|
|
24008
23931
|
if (state.events) {
|
|
24009
|
-
const result = state.events.enter?.("
|
|
23932
|
+
const result = state.events.enter?.("Nested", state);
|
|
24010
23933
|
if (result) {
|
|
24011
23934
|
if (result.cache)
|
|
24012
23935
|
return result.cache;
|
|
@@ -24014,24 +23937,27 @@ ${input.slice(result.pos)}
|
|
|
24014
23937
|
}
|
|
24015
23938
|
}
|
|
24016
23939
|
if (state.tokenize) {
|
|
24017
|
-
const result = $TOKEN("
|
|
23940
|
+
const result = $TOKEN("Nested", state, Nested$0(state));
|
|
24018
23941
|
if (state.events)
|
|
24019
|
-
state.events.exit?.("
|
|
23942
|
+
state.events.exit?.("Nested", state, result, eventData);
|
|
24020
23943
|
return result;
|
|
24021
23944
|
} else {
|
|
24022
|
-
const result =
|
|
23945
|
+
const result = Nested$0(state);
|
|
24023
23946
|
if (state.events)
|
|
24024
|
-
state.events.exit?.("
|
|
23947
|
+
state.events.exit?.("Nested", state, result, eventData);
|
|
24025
23948
|
return result;
|
|
24026
23949
|
}
|
|
24027
23950
|
}
|
|
24028
|
-
var
|
|
24029
|
-
|
|
23951
|
+
var IndentedFurther$0 = $TS($S(EOS, Indent), function($skip, $loc, $0, $1, $2) {
|
|
23952
|
+
var indent = $2;
|
|
23953
|
+
if (indent.level > module2.currentIndent.level)
|
|
23954
|
+
return $0;
|
|
23955
|
+
return $skip;
|
|
24030
23956
|
});
|
|
24031
|
-
function
|
|
23957
|
+
function IndentedFurther(state) {
|
|
24032
23958
|
let eventData;
|
|
24033
23959
|
if (state.events) {
|
|
24034
|
-
const result = state.events.enter?.("
|
|
23960
|
+
const result = state.events.enter?.("IndentedFurther", state);
|
|
24035
23961
|
if (result) {
|
|
24036
23962
|
if (result.cache)
|
|
24037
23963
|
return result.cache;
|
|
@@ -24039,22 +23965,27 @@ ${input.slice(result.pos)}
|
|
|
24039
23965
|
}
|
|
24040
23966
|
}
|
|
24041
23967
|
if (state.tokenize) {
|
|
24042
|
-
const result = $TOKEN("
|
|
23968
|
+
const result = $TOKEN("IndentedFurther", state, IndentedFurther$0(state));
|
|
24043
23969
|
if (state.events)
|
|
24044
|
-
state.events.exit?.("
|
|
23970
|
+
state.events.exit?.("IndentedFurther", state, result, eventData);
|
|
24045
23971
|
return result;
|
|
24046
23972
|
} else {
|
|
24047
|
-
const result =
|
|
23973
|
+
const result = IndentedFurther$0(state);
|
|
24048
23974
|
if (state.events)
|
|
24049
|
-
state.events.exit?.("
|
|
23975
|
+
state.events.exit?.("IndentedFurther", state, result, eventData);
|
|
24050
23976
|
return result;
|
|
24051
23977
|
}
|
|
24052
23978
|
}
|
|
24053
|
-
var
|
|
24054
|
-
|
|
23979
|
+
var IndentedAtLeast$0 = $TS($S(EOS, Indent), function($skip, $loc, $0, $1, $2) {
|
|
23980
|
+
var indent = $2;
|
|
23981
|
+
if (indent.level >= module2.currentIndent.level)
|
|
23982
|
+
return $0;
|
|
23983
|
+
return $skip;
|
|
23984
|
+
});
|
|
23985
|
+
function IndentedAtLeast(state) {
|
|
24055
23986
|
let eventData;
|
|
24056
23987
|
if (state.events) {
|
|
24057
|
-
const result = state.events.enter?.("
|
|
23988
|
+
const result = state.events.enter?.("IndentedAtLeast", state);
|
|
24058
23989
|
if (result) {
|
|
24059
23990
|
if (result.cache)
|
|
24060
23991
|
return result.cache;
|
|
@@ -24062,27 +23993,29 @@ ${input.slice(result.pos)}
|
|
|
24062
23993
|
}
|
|
24063
23994
|
}
|
|
24064
23995
|
if (state.tokenize) {
|
|
24065
|
-
const result = $TOKEN("
|
|
23996
|
+
const result = $TOKEN("IndentedAtLeast", state, IndentedAtLeast$0(state));
|
|
24066
23997
|
if (state.events)
|
|
24067
|
-
state.events.exit?.("
|
|
23998
|
+
state.events.exit?.("IndentedAtLeast", state, result, eventData);
|
|
24068
23999
|
return result;
|
|
24069
24000
|
} else {
|
|
24070
|
-
const result =
|
|
24001
|
+
const result = IndentedAtLeast$0(state);
|
|
24071
24002
|
if (state.events)
|
|
24072
|
-
state.events.exit?.("
|
|
24003
|
+
state.events.exit?.("IndentedAtLeast", state, result, eventData);
|
|
24073
24004
|
return result;
|
|
24074
24005
|
}
|
|
24075
24006
|
}
|
|
24076
|
-
var
|
|
24077
|
-
|
|
24078
|
-
|
|
24079
|
-
|
|
24080
|
-
|
|
24007
|
+
var NotDedented$0 = $TS($S($E(IndentedAtLeast), $E(_)), function($skip, $loc, $0, $1, $2) {
|
|
24008
|
+
const ws = [];
|
|
24009
|
+
if ($1)
|
|
24010
|
+
ws.push(...$1);
|
|
24011
|
+
if ($2)
|
|
24012
|
+
ws.push(...$2);
|
|
24013
|
+
return ws.flat(Infinity).filter(Boolean);
|
|
24081
24014
|
});
|
|
24082
|
-
function
|
|
24015
|
+
function NotDedented(state) {
|
|
24083
24016
|
let eventData;
|
|
24084
24017
|
if (state.events) {
|
|
24085
|
-
const result = state.events.enter?.("
|
|
24018
|
+
const result = state.events.enter?.("NotDedented", state);
|
|
24086
24019
|
if (result) {
|
|
24087
24020
|
if (result.cache)
|
|
24088
24021
|
return result.cache;
|
|
@@ -24090,37 +24023,24 @@ ${input.slice(result.pos)}
|
|
|
24090
24023
|
}
|
|
24091
24024
|
}
|
|
24092
24025
|
if (state.tokenize) {
|
|
24093
|
-
const result = $TOKEN("
|
|
24026
|
+
const result = $TOKEN("NotDedented", state, NotDedented$0(state));
|
|
24094
24027
|
if (state.events)
|
|
24095
|
-
state.events.exit?.("
|
|
24028
|
+
state.events.exit?.("NotDedented", state, result, eventData);
|
|
24096
24029
|
return result;
|
|
24097
24030
|
} else {
|
|
24098
|
-
const result =
|
|
24031
|
+
const result = NotDedented$0(state);
|
|
24099
24032
|
if (state.events)
|
|
24100
|
-
state.events.exit?.("
|
|
24033
|
+
state.events.exit?.("NotDedented", state, result, eventData);
|
|
24101
24034
|
return result;
|
|
24102
24035
|
}
|
|
24103
24036
|
}
|
|
24104
|
-
var
|
|
24105
|
-
|
|
24106
|
-
var indent = $2;
|
|
24107
|
-
const { level } = indent;
|
|
24108
|
-
const currentIndent = module2.currentIndent;
|
|
24109
|
-
if (module2.config.verbose) {
|
|
24110
|
-
console.log("Indented", level, currentIndent);
|
|
24111
|
-
}
|
|
24112
|
-
if (level !== currentIndent.level) {
|
|
24113
|
-
if (module2.config.verbose) {
|
|
24114
|
-
console.log("skipped nested");
|
|
24115
|
-
}
|
|
24116
|
-
return $skip;
|
|
24117
|
-
}
|
|
24118
|
-
return $0;
|
|
24037
|
+
var Dedented$0 = $T($S($N(IndentedAtLeast), EOS), function(value) {
|
|
24038
|
+
return value[1];
|
|
24119
24039
|
});
|
|
24120
|
-
function
|
|
24040
|
+
function Dedented(state) {
|
|
24121
24041
|
let eventData;
|
|
24122
24042
|
if (state.events) {
|
|
24123
|
-
const result = state.events.enter?.("
|
|
24043
|
+
const result = state.events.enter?.("Dedented", state);
|
|
24124
24044
|
if (result) {
|
|
24125
24045
|
if (result.cache)
|
|
24126
24046
|
return result.cache;
|
|
@@ -24128,14 +24048,14 @@ ${input.slice(result.pos)}
|
|
|
24128
24048
|
}
|
|
24129
24049
|
}
|
|
24130
24050
|
if (state.tokenize) {
|
|
24131
|
-
const result = $TOKEN("
|
|
24051
|
+
const result = $TOKEN("Dedented", state, Dedented$0(state));
|
|
24132
24052
|
if (state.events)
|
|
24133
|
-
state.events.exit?.("
|
|
24053
|
+
state.events.exit?.("Dedented", state, result, eventData);
|
|
24134
24054
|
return result;
|
|
24135
24055
|
} else {
|
|
24136
|
-
const result =
|
|
24056
|
+
const result = Dedented$0(state);
|
|
24137
24057
|
if (state.events)
|
|
24138
|
-
state.events.exit?.("
|
|
24058
|
+
state.events.exit?.("Dedented", state, result, eventData);
|
|
24139
24059
|
return result;
|
|
24140
24060
|
}
|
|
24141
24061
|
}
|
|
@@ -24163,12 +24083,14 @@ ${input.slice(result.pos)}
|
|
|
24163
24083
|
literalValue,
|
|
24164
24084
|
makeEmptyBlock,
|
|
24165
24085
|
makeLeftHandSideExpression,
|
|
24086
|
+
makeRef,
|
|
24166
24087
|
maybeRef,
|
|
24167
24088
|
modifyString,
|
|
24089
|
+
processAssignmentDeclaration,
|
|
24168
24090
|
processBinaryOpExpression,
|
|
24169
24091
|
processCallMemberExpression,
|
|
24170
24092
|
processCoffeeInterpolation,
|
|
24171
|
-
|
|
24093
|
+
processForInOf,
|
|
24172
24094
|
processProgram,
|
|
24173
24095
|
processUnaryExpression,
|
|
24174
24096
|
quoteString,
|
|
@@ -24613,7 +24535,7 @@ var parse;
|
|
|
24613
24535
|
var uncacheable;
|
|
24614
24536
|
({ parse } = import_parser.default);
|
|
24615
24537
|
({ SourceMap: SourceMap2 } = util_exports);
|
|
24616
|
-
uncacheable = /* @__PURE__ */ new Set(["ActualAssignment", "AllowAll", "AllowClassImplicitCall", "AllowBracedApplication", "AllowIndentedApplication", "AllowMultiLineImplicitObjectLiteral", "AllowNewlineBinaryOp", "AllowTrailingMemberProperty", "AllowedTrailingMemberExpressions", "ApplicationStart", "Arguments", "ArgumentsWithTrailingMemberExpressions", "ArrowFunction", "ArrowFunctionTail", "AssignmentExpression", "AssignmentExpressionTail", "BinaryOpExpression", "BinaryOpRHS", "BracedApplicationAllowed", "BracedBlock", "BracedObjectLiteralContent", "BracedOrEmptyBlock", "CallExpression", "CallExpressionRest", "ClassImplicitCallForbidden", "CoffeeCommentEnabled", "CommaDelimiter", "ConditionalExpression", "ConditionFragment", "Declaration", "Debugger", "Dedented", "ElementListWithIndentedApplicationForbidden", "ElseClause", "Expression", "ExpressionStatement", "ExpressionWithIndentedApplicationForbidden", "ExpressionWithObjectApplicationForbidden", "ExtendedExpression", "FatArrowBody", "ForbidClassImplicitCall", "ForbidBracedApplication", "ForbidIndentedApplication", "ForbidMultiLineImplicitObjectLiteral", "ForbidNewlineBinaryOp", "ForbidTrailingMemberProperty", "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", "NestedClassSignatureElement", "NestedClassSignatureElements", "NestedDeclareElement", "NestedDeclareElements", "NestedElement", "NestedElementList", "NestedImplicitObjectLiteral", "NestedImplicitPropertyDefinition", "NestedImplicitPropertyDefinitions", "NestedInterfaceProperty", "NestedJSXChildExpression", "NestedModuleItem", "NestedModuleItems", "NestedNonAssignmentExtendedExpression", "NestedObject", "NestedPropertyDefinitions", "NewlineBinaryOpAllowed", "NonPipelineAssignmentExpression", "NonPipelineExtendedExpression", "NonPipelinePostfixedExpression", "NonSingleBracedBlock", "NotDedented", "ObjectLiteral", "PatternExpressionList", "PopIndent", "PopJSXStack", "PostfixedExpression", "PostfixedStatement", "PrimaryExpression", "PushIndent", "PushJSXOpeningElement", "PushJSXOpeningFragment", "RestoreAll", "RestoreClassImplicitCall", "RestoreMultiLineImplicitObjectLiteral", "RestoreBracedApplication", "RestoreIndentedApplication", "RestoreTrailingMemberProperty", "RestoreNewlineBinaryOp", "RHS", "
|
|
24538
|
+
uncacheable = /* @__PURE__ */ new Set(["ActualAssignment", "AllowAll", "AllowClassImplicitCall", "AllowBracedApplication", "AllowIndentedApplication", "AllowMultiLineImplicitObjectLiteral", "AllowNewlineBinaryOp", "AllowTrailingMemberProperty", "AllowedTrailingMemberExpressions", "ApplicationStart", "Arguments", "ArgumentsWithTrailingMemberExpressions", "ArrowFunction", "ArrowFunctionTail", "AssignmentExpression", "AssignmentExpressionTail", "BinaryOpExpression", "BinaryOpRHS", "BracedApplicationAllowed", "BracedBlock", "BracedObjectLiteralContent", "BracedOrEmptyBlock", "CallExpression", "CallExpressionRest", "ClassImplicitCallForbidden", "CoffeeCommentEnabled", "CommaDelimiter", "ConditionalExpression", "ConditionFragment", "Declaration", "Debugger", "Dedented", "ElementListWithIndentedApplicationForbidden", "ElseClause", "Expression", "ExpressionStatement", "ExpressionWithIndentedApplicationForbidden", "ExpressionWithObjectApplicationForbidden", "ExtendedExpression", "FatArrowBody", "ForbidClassImplicitCall", "ForbidBracedApplication", "ForbidIndentedApplication", "ForbidMultiLineImplicitObjectLiteral", "ForbidNewlineBinaryOp", "ForbidTrailingMemberProperty", "FunctionDeclaration", "FunctionExpression", "HoistableDeclaration", "ImplicitArguments", "ImplicitInlineObjectPropertyDelimiter", "ImplicitNestedBlock", "IndentedApplicationAllowed", "IndentedAtLeast", "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", "NestedClassSignatureElement", "NestedClassSignatureElements", "NestedDeclareElement", "NestedDeclareElements", "NestedElement", "NestedElementList", "NestedImplicitObjectLiteral", "NestedImplicitPropertyDefinition", "NestedImplicitPropertyDefinitions", "NestedInterfaceProperty", "NestedJSXChildExpression", "NestedModuleItem", "NestedModuleItems", "NestedNonAssignmentExtendedExpression", "NestedObject", "NestedPropertyDefinitions", "NewlineBinaryOpAllowed", "NonPipelineArgumentPart", "NonPipelineArgumentList", "NonPipelineAssignmentExpression", "NonPipelineExtendedExpression", "NonPipelinePostfixedExpression", "NonSingleBracedBlock", "NotDedented", "ObjectLiteral", "PatternExpressionList", "PopIndent", "PopJSXStack", "PostfixedExpression", "PostfixedStatement", "PrimaryExpression", "PushIndent", "PushJSXOpeningElement", "PushJSXOpeningFragment", "RestoreAll", "RestoreClassImplicitCall", "RestoreMultiLineImplicitObjectLiteral", "RestoreBracedApplication", "RestoreIndentedApplication", "RestoreTrailingMemberProperty", "RestoreNewlineBinaryOp", "RHS", "ShortCircuitExpression", "SingleLineAssignmentExpression", "SingleLineBinaryOpRHS", "SingleLineComment", "SingleLineStatements", "SnugNamedProperty", "Statement", "StatementListItem", "SuffixedExpression", "SuffixedStatement", "ThinArrowFunction", "TrackIndented", "TrailingMemberExpressions", "TrailingMemberPropertyAllowed", "TypedJSXElement", "TypedJSXFragment", "UnaryExpression", "UpdateExpression"]);
|
|
24617
24539
|
var compile = function(src, options) {
|
|
24618
24540
|
var ast, code, events, filename, ref, result, sm;
|
|
24619
24541
|
if (!options) {
|