@danielx/civet 0.5.35 → 0.5.37
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 +143 -224
- package/dist/main.js +143 -224
- package/dist/main.mjs +143 -224
- package/package.json +1 -1
- package/register.js +1 -1
package/dist/main.mjs
CHANGED
|
@@ -434,7 +434,7 @@ ${input.slice(result.pos)}
|
|
|
434
434
|
ExplicitArguments,
|
|
435
435
|
ApplicationStart,
|
|
436
436
|
IndentedApplicationAllowed,
|
|
437
|
-
|
|
437
|
+
ArgumentsWithTrailingMemberExpressions,
|
|
438
438
|
ArgumentList,
|
|
439
439
|
NestedArgumentList,
|
|
440
440
|
NestedArgument,
|
|
@@ -848,6 +848,8 @@ ${input.slice(result.pos)}
|
|
|
848
848
|
TypeDeclaration,
|
|
849
849
|
TypeDeclarationModifier,
|
|
850
850
|
TypeDeclarationRest,
|
|
851
|
+
InterfaceExtendsClause,
|
|
852
|
+
InterfaceExtendsTarget,
|
|
851
853
|
TypeKeyword,
|
|
852
854
|
Interface,
|
|
853
855
|
Namespace,
|
|
@@ -880,10 +882,6 @@ ${input.slice(result.pos)}
|
|
|
880
882
|
TypeBinaryOp,
|
|
881
883
|
FunctionType,
|
|
882
884
|
TypeArguments,
|
|
883
|
-
InlineTypeArguments,
|
|
884
|
-
InlineTypeArgument,
|
|
885
|
-
InlineTypeArgumentDelimiter,
|
|
886
|
-
CompactTypeArguments,
|
|
887
885
|
TypeArgument,
|
|
888
886
|
TypeArgumentDelimiter,
|
|
889
887
|
TypeParameters,
|
|
@@ -938,13 +936,13 @@ ${input.slice(result.pos)}
|
|
|
938
936
|
Nested
|
|
939
937
|
});
|
|
940
938
|
var $L0 = $L("");
|
|
941
|
-
var $L1 = $L("
|
|
942
|
-
var $L2 = $L("
|
|
943
|
-
var $L3 = $L("
|
|
944
|
-
var $L4 = $L("
|
|
945
|
-
var $L5 = $L("
|
|
946
|
-
var $L6 = $L("
|
|
947
|
-
var $L7 = $L("
|
|
939
|
+
var $L1 = $L(".");
|
|
940
|
+
var $L2 = $L("++");
|
|
941
|
+
var $L3 = $L("--");
|
|
942
|
+
var $L4 = $L("=>");
|
|
943
|
+
var $L5 = $L(" ");
|
|
944
|
+
var $L6 = $L("implements");
|
|
945
|
+
var $L7 = $L("#");
|
|
948
946
|
var $L8 = $L("super");
|
|
949
947
|
var $L9 = $L("import");
|
|
950
948
|
var $L10 = $L("!");
|
|
@@ -1104,7 +1102,7 @@ ${input.slice(result.pos)}
|
|
|
1104
1102
|
var $L164 = $L("infer");
|
|
1105
1103
|
var $L165 = $L("[]");
|
|
1106
1104
|
var $L166 = $L("civet");
|
|
1107
|
-
var $R0 = $R(new RegExp("(for|of|then|when)(?!\\p{ID_Continue}|[\\u200C\\u200D$])", "suy"));
|
|
1105
|
+
var $R0 = $R(new RegExp("(as|for|of|satisfies|then|when)(?!\\p{ID_Continue}|[\\u200C\\u200D$])", "suy"));
|
|
1108
1106
|
var $R1 = $R(new RegExp("[&]", "suy"));
|
|
1109
1107
|
var $R2 = $R(new RegExp("[!~+-]+", "suy"));
|
|
1110
1108
|
var $R3 = $R(new RegExp("(?:\\p{ID_Start}|[_$])(?:\\p{ID_Continue}|[\\u200C\\u200D$])*", "suy"));
|
|
@@ -1141,7 +1139,7 @@ ${input.slice(result.pos)}
|
|
|
1141
1139
|
var $R34 = $R(new RegExp("(?:by)(?!\\p{ID_Continue})", "suy"));
|
|
1142
1140
|
var $R35 = $R(new RegExp("(?:of)(?!\\p{ID_Continue})", "suy"));
|
|
1143
1141
|
var $R36 = $R(new RegExp("(?:not)(?!\\p{ID_Continue})", "suy"));
|
|
1144
|
-
var $R37 = $R(new RegExp("(?:and|
|
|
1142
|
+
var $R37 = $R(new RegExp("(?:and|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|function|if|import|in|instanceof|interface|is|let|loop|new|null|or|private|protected|public|return|static|super|switch|this|throw|true|try|typeof|unless|until|var|void|while|with|yield)(?!\\p{ID_Continue})", "suy"));
|
|
1145
1143
|
var $R38 = $R(new RegExp("\\/\\/(?!\\/)[^\\r\\n]*", "suy"));
|
|
1146
1144
|
var $R39 = $R(new RegExp(".", "suy"));
|
|
1147
1145
|
var $R40 = $R(new RegExp("#(?!##(?!#))([^\\r\\n]*)", "suy"));
|
|
@@ -1351,7 +1349,7 @@ ${input.slice(result.pos)}
|
|
|
1351
1349
|
}
|
|
1352
1350
|
}
|
|
1353
1351
|
var Arguments$0 = ExplicitArguments;
|
|
1354
|
-
var Arguments$1 = $TS($S($E($S(
|
|
1352
|
+
var Arguments$1 = $TS($S($E($S(TypeArguments, $N($S(__, ImplementsToken)))), ApplicationStart, InsertOpenParen, $Q(_), ArgumentList, InsertCloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
|
|
1355
1353
|
var ta = $1;
|
|
1356
1354
|
var open = $3;
|
|
1357
1355
|
var ws = $4;
|
|
@@ -1455,11 +1453,11 @@ ${input.slice(result.pos)}
|
|
|
1455
1453
|
return result;
|
|
1456
1454
|
}
|
|
1457
1455
|
}
|
|
1458
|
-
var
|
|
1459
|
-
function
|
|
1456
|
+
var ArgumentsWithTrailingMemberExpressions$0 = $S(Arguments, $Q($S(Samedent, $Y($EXPECT($L1, fail, 'ArgumentsWithTrailingMemberExpressions "."')), MemberExpressionRest)));
|
|
1457
|
+
function ArgumentsWithTrailingMemberExpressions(state) {
|
|
1460
1458
|
let eventData;
|
|
1461
1459
|
if (state.events) {
|
|
1462
|
-
const result = state.events.enter?.("
|
|
1460
|
+
const result = state.events.enter?.("ArgumentsWithTrailingMemberExpressions", state);
|
|
1463
1461
|
if (result) {
|
|
1464
1462
|
if (result.cache)
|
|
1465
1463
|
return result.cache;
|
|
@@ -1467,14 +1465,14 @@ ${input.slice(result.pos)}
|
|
|
1467
1465
|
}
|
|
1468
1466
|
}
|
|
1469
1467
|
if (state.tokenize) {
|
|
1470
|
-
const result = $TOKEN("
|
|
1468
|
+
const result = $TOKEN("ArgumentsWithTrailingMemberExpressions", state, ArgumentsWithTrailingMemberExpressions$0(state));
|
|
1471
1469
|
if (state.events)
|
|
1472
|
-
state.events.exit?.("
|
|
1470
|
+
state.events.exit?.("ArgumentsWithTrailingMemberExpressions", state, result, eventData);
|
|
1473
1471
|
return result;
|
|
1474
1472
|
} else {
|
|
1475
|
-
const result =
|
|
1473
|
+
const result = ArgumentsWithTrailingMemberExpressions$0(state);
|
|
1476
1474
|
if (state.events)
|
|
1477
|
-
state.events.exit?.("
|
|
1475
|
+
state.events.exit?.("ArgumentsWithTrailingMemberExpressions", state, result, eventData);
|
|
1478
1476
|
return result;
|
|
1479
1477
|
}
|
|
1480
1478
|
}
|
|
@@ -1798,7 +1796,7 @@ ${input.slice(result.pos)}
|
|
|
1798
1796
|
return result;
|
|
1799
1797
|
}
|
|
1800
1798
|
}
|
|
1801
|
-
var UpdateExpressionSymbol$0 = $TV($C($EXPECT($
|
|
1799
|
+
var UpdateExpressionSymbol$0 = $TV($C($EXPECT($L2, fail, 'UpdateExpressionSymbol "++"'), $EXPECT($L3, fail, 'UpdateExpressionSymbol "--"')), function($skip, $loc, $0, $1) {
|
|
1802
1800
|
return { $loc, token: $1 };
|
|
1803
1801
|
});
|
|
1804
1802
|
function UpdateExpressionSymbol(state) {
|
|
@@ -2090,7 +2088,7 @@ ${input.slice(result.pos)}
|
|
|
2090
2088
|
return result;
|
|
2091
2089
|
}
|
|
2092
2090
|
}
|
|
2093
|
-
var FatArrow$0 = $TS($S(__, $EXPECT($
|
|
2091
|
+
var FatArrow$0 = $TS($S(__, $EXPECT($L4, fail, 'FatArrow "=>"')), function($skip, $loc, $0, $1, $2) {
|
|
2094
2092
|
var ws = $1;
|
|
2095
2093
|
if (!ws.length)
|
|
2096
2094
|
return " =>";
|
|
@@ -2173,7 +2171,7 @@ ${input.slice(result.pos)}
|
|
|
2173
2171
|
}
|
|
2174
2172
|
}
|
|
2175
2173
|
var TernaryRest$0 = NestedTernaryRest;
|
|
2176
|
-
var TernaryRest$1 = $TS($S($N(CoffeeBinaryExistentialEnabled), $Y($EXPECT($
|
|
2174
|
+
var TernaryRest$1 = $TS($S($N(CoffeeBinaryExistentialEnabled), $Y($EXPECT($L5, fail, 'TernaryRest " "')), $Q(TrailingComment), QuestionMark, ExtendedExpression, __, Colon, ExtendedExpression), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8) {
|
|
2177
2175
|
return $0.slice(2);
|
|
2178
2176
|
});
|
|
2179
2177
|
function TernaryRest(state) {
|
|
@@ -2533,7 +2531,7 @@ ${input.slice(result.pos)}
|
|
|
2533
2531
|
return result;
|
|
2534
2532
|
}
|
|
2535
2533
|
}
|
|
2536
|
-
var ExtendsToken$0 = $TS($S(Loc, __, OpenAngleBracket, $E($EXPECT($
|
|
2534
|
+
var ExtendsToken$0 = $TS($S(Loc, __, OpenAngleBracket, $E($EXPECT($L5, fail, 'ExtendsToken " "'))), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
2537
2535
|
var l = $1;
|
|
2538
2536
|
var ws = $2;
|
|
2539
2537
|
var lt = $3;
|
|
@@ -2629,7 +2627,7 @@ ${input.slice(result.pos)}
|
|
|
2629
2627
|
return result;
|
|
2630
2628
|
}
|
|
2631
2629
|
}
|
|
2632
|
-
var ImplementsToken$0 = $TS($S($EXPECT($
|
|
2630
|
+
var ImplementsToken$0 = $TS($S($EXPECT($L6, fail, 'ImplementsToken "implements"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
|
|
2633
2631
|
return { $loc, token: $1 };
|
|
2634
2632
|
});
|
|
2635
2633
|
function ImplementsToken(state) {
|
|
@@ -2878,7 +2876,7 @@ ${input.slice(result.pos)}
|
|
|
2878
2876
|
}
|
|
2879
2877
|
}
|
|
2880
2878
|
var ThisLiteral$0 = This;
|
|
2881
|
-
var ThisLiteral$1 = $TS($S(At, $TEXT($S($E($EXPECT($
|
|
2879
|
+
var ThisLiteral$1 = $TS($S(At, $TEXT($S($E($EXPECT($L7, fail, 'ThisLiteral "#"')), IdentifierName))), function($skip, $loc, $0, $1, $2) {
|
|
2882
2880
|
var t = $1;
|
|
2883
2881
|
var id = $2;
|
|
2884
2882
|
return [{ ...t, token: "this." }, id];
|
|
@@ -2909,7 +2907,7 @@ ${input.slice(result.pos)}
|
|
|
2909
2907
|
return result;
|
|
2910
2908
|
}
|
|
2911
2909
|
}
|
|
2912
|
-
var LeftHandSideExpression$0 = $TS($S($Q($S(New, $N($EXPECT($
|
|
2910
|
+
var LeftHandSideExpression$0 = $TS($S($Q($S(New, $N($EXPECT($L1, fail, 'LeftHandSideExpression "."')), __)), CallExpression), function($skip, $loc, $0, $1, $2) {
|
|
2913
2911
|
if ($1.length)
|
|
2914
2912
|
return $0;
|
|
2915
2913
|
return $2;
|
|
@@ -2936,8 +2934,8 @@ ${input.slice(result.pos)}
|
|
|
2936
2934
|
return result;
|
|
2937
2935
|
}
|
|
2938
2936
|
}
|
|
2939
|
-
var CallExpression$0 = $S($EXPECT($L8, fail, 'CallExpression "super"'),
|
|
2940
|
-
var CallExpression$1 = $TS($S($EXPECT($L9, fail, 'CallExpression "import"'),
|
|
2937
|
+
var CallExpression$0 = $S($EXPECT($L8, fail, 'CallExpression "super"'), ArgumentsWithTrailingMemberExpressions, $Q(CallExpressionRest));
|
|
2938
|
+
var CallExpression$1 = $TS($S($EXPECT($L9, fail, 'CallExpression "import"'), ArgumentsWithTrailingMemberExpressions, $Q(CallExpressionRest)), function($skip, $loc, $0, $1, $2, $3) {
|
|
2941
2939
|
return {
|
|
2942
2940
|
type: "CallExpression",
|
|
2943
2941
|
children: $0
|
|
@@ -2976,7 +2974,7 @@ ${input.slice(result.pos)}
|
|
|
2976
2974
|
}
|
|
2977
2975
|
var CallExpressionRest$0 = MemberExpressionRest;
|
|
2978
2976
|
var CallExpressionRest$1 = TemplateLiteral;
|
|
2979
|
-
var CallExpressionRest$2 = $S($E($C(OptionalShorthand, NonNullAssertion)),
|
|
2977
|
+
var CallExpressionRest$2 = $S($E($C(OptionalShorthand, NonNullAssertion)), ArgumentsWithTrailingMemberExpressions);
|
|
2980
2978
|
function CallExpressionRest(state) {
|
|
2981
2979
|
let eventData;
|
|
2982
2980
|
if (state.events) {
|
|
@@ -3047,7 +3045,7 @@ ${input.slice(result.pos)}
|
|
|
3047
3045
|
return result;
|
|
3048
3046
|
}
|
|
3049
3047
|
}
|
|
3050
|
-
var AdditionalReservedWords$0 = $R$0($EXPECT($R0, fail, "AdditionalReservedWords /(for|of|then|when)(?!\\p{ID_Continue}|[\\u200C\\u200D$])/"));
|
|
3048
|
+
var AdditionalReservedWords$0 = $R$0($EXPECT($R0, fail, "AdditionalReservedWords /(as|for|of|satisfies|then|when)(?!\\p{ID_Continue}|[\\u200C\\u200D$])/"));
|
|
3051
3049
|
var AdditionalReservedWords$1 = AtAt;
|
|
3052
3050
|
function AdditionalReservedWords(state) {
|
|
3053
3051
|
let eventData;
|
|
@@ -4574,16 +4572,8 @@ ${input.slice(result.pos)}
|
|
|
4574
4572
|
return result;
|
|
4575
4573
|
}
|
|
4576
4574
|
}
|
|
4577
|
-
var ThenClause$0 = $
|
|
4578
|
-
|
|
4579
|
-
var s = $3;
|
|
4580
|
-
const expressions = [[ws, s]];
|
|
4581
|
-
return {
|
|
4582
|
-
type: "BlockStatement",
|
|
4583
|
-
expressions,
|
|
4584
|
-
children: [expressions],
|
|
4585
|
-
bare: true
|
|
4586
|
-
};
|
|
4575
|
+
var ThenClause$0 = $T($S(Then, SingleLineStatements), function(value) {
|
|
4576
|
+
return value[1];
|
|
4587
4577
|
});
|
|
4588
4578
|
function ThenClause(state) {
|
|
4589
4579
|
let eventData;
|
|
@@ -4688,8 +4678,8 @@ ${input.slice(result.pos)}
|
|
|
4688
4678
|
var c = $5;
|
|
4689
4679
|
return {
|
|
4690
4680
|
type: "BlockStatement",
|
|
4691
|
-
expressions: s,
|
|
4692
|
-
children: [o, s, ws, c]
|
|
4681
|
+
expressions: s.expressions,
|
|
4682
|
+
children: [o, s.children, ws, c]
|
|
4693
4683
|
};
|
|
4694
4684
|
});
|
|
4695
4685
|
function BracedBlock(state) {
|
|
@@ -4714,13 +4704,18 @@ ${input.slice(result.pos)}
|
|
|
4714
4704
|
return result;
|
|
4715
4705
|
}
|
|
4716
4706
|
}
|
|
4717
|
-
var SingleLineStatements$0 = $TS($S($S($Q(
|
|
4718
|
-
var
|
|
4719
|
-
var
|
|
4720
|
-
|
|
4721
|
-
|
|
4722
|
-
|
|
4723
|
-
return
|
|
4707
|
+
var SingleLineStatements$0 = $TS($S($Q($S($Q(_), Statement, SemicolonDelimiter)), $E($S($Q(_), Statement, $E(SemicolonDelimiter)))), function($skip, $loc, $0, $1, $2) {
|
|
4708
|
+
var stmts = $1;
|
|
4709
|
+
var last = $2;
|
|
4710
|
+
const children = [...stmts];
|
|
4711
|
+
if (last)
|
|
4712
|
+
children.push(last);
|
|
4713
|
+
return {
|
|
4714
|
+
type: "BlockStatement",
|
|
4715
|
+
expressions: children,
|
|
4716
|
+
children,
|
|
4717
|
+
bare: true
|
|
4718
|
+
};
|
|
4724
4719
|
});
|
|
4725
4720
|
function SingleLineStatements(state) {
|
|
4726
4721
|
let eventData;
|
|
@@ -6252,7 +6247,7 @@ ${input.slice(result.pos)}
|
|
|
6252
6247
|
return result;
|
|
6253
6248
|
}
|
|
6254
6249
|
}
|
|
6255
|
-
var PrivateIdentifier$0 = $TV($TEXT($S($EXPECT($
|
|
6250
|
+
var PrivateIdentifier$0 = $TV($TEXT($S($EXPECT($L7, fail, 'PrivateIdentifier "#"'), IdentifierName)), function($skip, $loc, $0, $1) {
|
|
6256
6251
|
return {
|
|
6257
6252
|
type: "Identifier",
|
|
6258
6253
|
name: $0,
|
|
@@ -8013,48 +8008,34 @@ ${input.slice(result.pos)}
|
|
|
8013
8008
|
}
|
|
8014
8009
|
}
|
|
8015
8010
|
var CaseClause$0 = $T($S(Case, CaseExpressionList, $C(NestedBlockStatements, NoExpressions)), function(value) {
|
|
8016
|
-
|
|
8017
|
-
var expressions = value[2];
|
|
8018
|
-
return { "type": "CaseClause", "cases": cases, "expressions": expressions, "children": value };
|
|
8011
|
+
return { "type": "CaseClause", "children": value };
|
|
8019
8012
|
});
|
|
8020
|
-
var CaseClause$1 = $TS($S(When, CaseExpressionList, InsertOpenBrace, $
|
|
8013
|
+
var CaseClause$1 = $TS($S(When, CaseExpressionList, InsertOpenBrace, $C(ThenClause, NestedBlockStatements, NoExpressions), InsertBreak, InsertNewline, InsertIndent, InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8) {
|
|
8021
8014
|
var cases = $2;
|
|
8022
|
-
var
|
|
8015
|
+
var block = $4;
|
|
8023
8016
|
var b = $5;
|
|
8024
|
-
let children = $0;
|
|
8025
|
-
if (!expressions) {
|
|
8026
|
-
expressions = [];
|
|
8027
|
-
children = children.map((c, i) => i === 3 ? expressions : c);
|
|
8028
|
-
}
|
|
8029
|
-
if (expressions.expressions) {
|
|
8030
|
-
expressions = expressions.expressions;
|
|
8031
|
-
}
|
|
8032
8017
|
return {
|
|
8033
8018
|
type: "WhenClause",
|
|
8034
8019
|
cases,
|
|
8035
|
-
|
|
8020
|
+
block,
|
|
8036
8021
|
break: b,
|
|
8037
|
-
children
|
|
8022
|
+
children: $0
|
|
8038
8023
|
};
|
|
8039
8024
|
});
|
|
8040
8025
|
var CaseClause$2 = $TS($S(Default, ImpliedColon, $C(NestedBlockStatements, NoExpressions)), function($skip, $loc, $0, $1, $2, $3) {
|
|
8041
|
-
var
|
|
8042
|
-
if (expressions.expressions)
|
|
8043
|
-
expressions = expressions.expressions;
|
|
8026
|
+
var block = $3;
|
|
8044
8027
|
return {
|
|
8045
8028
|
type: "DefaultClause",
|
|
8046
|
-
|
|
8029
|
+
block,
|
|
8047
8030
|
children: $0
|
|
8048
8031
|
};
|
|
8049
8032
|
});
|
|
8050
|
-
var CaseClause$3 = $TS($S(Else, ImpliedColon, InsertOpenBrace, $C(NestedBlockStatements,
|
|
8051
|
-
var
|
|
8033
|
+
var CaseClause$3 = $TS($S(Else, ImpliedColon, InsertOpenBrace, $C(NestedBlockStatements, SingleLineStatements), InsertNewline, InsertIndent, InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7) {
|
|
8034
|
+
var block = $4;
|
|
8052
8035
|
$1.token = "default";
|
|
8053
|
-
if (expressions.expressions)
|
|
8054
|
-
expressions = expressions.expressions;
|
|
8055
8036
|
return {
|
|
8056
8037
|
type: "DefaultClause",
|
|
8057
|
-
|
|
8038
|
+
block,
|
|
8058
8039
|
children: $0
|
|
8059
8040
|
};
|
|
8060
8041
|
});
|
|
@@ -8811,7 +8792,7 @@ ${input.slice(result.pos)}
|
|
|
8811
8792
|
}
|
|
8812
8793
|
}
|
|
8813
8794
|
var ImportAsToken$0 = $S(__, As);
|
|
8814
|
-
var ImportAsToken$1 = $TS($S(Loc, __, Colon, $E($EXPECT($
|
|
8795
|
+
var ImportAsToken$1 = $TS($S(Loc, __, Colon, $E($EXPECT($L5, fail, 'ImportAsToken " "'))), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
8815
8796
|
var l = $1;
|
|
8816
8797
|
var ws = $2;
|
|
8817
8798
|
var c = $3;
|
|
@@ -10383,7 +10364,7 @@ ${input.slice(result.pos)}
|
|
|
10383
10364
|
var ReservedWord$3 = $S(CoffeeOfEnabled, $R$0($EXPECT($R35, fail, "ReservedWord /(?:of)(?!\\p{ID_Continue})/")));
|
|
10384
10365
|
var ReservedWord$4 = $S(CoffeeNotEnabled, $R$0($EXPECT($R36, fail, "ReservedWord /(?:not)(?!\\p{ID_Continue})/")));
|
|
10385
10366
|
var ReservedWord$5 = $S($EXPECT($L71, fail, 'ReservedWord "not"'), NonIdContinue, __, $EXPECT($L72, fail, 'ReservedWord "in"'), NonIdContinue);
|
|
10386
|
-
var ReservedWord$6 = $R$0($EXPECT($R37, fail, "ReservedWord /(?:and|
|
|
10367
|
+
var ReservedWord$6 = $R$0($EXPECT($R37, fail, "ReservedWord /(?:and|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|function|if|import|in|instanceof|interface|is|let|loop|new|null|or|private|protected|public|return|static|super|switch|this|throw|true|try|typeof|unless|until|var|void|while|with|yield)(?!\\p{ID_Continue})/"));
|
|
10387
10368
|
function ReservedWord(state) {
|
|
10388
10369
|
let eventData;
|
|
10389
10370
|
if (state.events) {
|
|
@@ -10901,7 +10882,7 @@ ${input.slice(result.pos)}
|
|
|
10901
10882
|
return result;
|
|
10902
10883
|
}
|
|
10903
10884
|
}
|
|
10904
|
-
var Abstract$0 = $TV($TEXT($S($EXPECT($L89, fail, 'Abstract "abstract"'), NonIdContinue, $E($EXPECT($
|
|
10885
|
+
var Abstract$0 = $TV($TEXT($S($EXPECT($L89, fail, 'Abstract "abstract"'), NonIdContinue, $E($EXPECT($L5, fail, 'Abstract " "')))), function($skip, $loc, $0, $1) {
|
|
10905
10886
|
return { $loc, token: $1, ts: true };
|
|
10906
10887
|
});
|
|
10907
10888
|
function Abstract(state) {
|
|
@@ -11426,7 +11407,7 @@ ${input.slice(result.pos)}
|
|
|
11426
11407
|
return result;
|
|
11427
11408
|
}
|
|
11428
11409
|
}
|
|
11429
|
-
var Dot$0 = $TV($EXPECT($
|
|
11410
|
+
var Dot$0 = $TV($EXPECT($L1, fail, 'Dot "."'), function($skip, $loc, $0, $1) {
|
|
11430
11411
|
return { $loc, token: $1 };
|
|
11431
11412
|
});
|
|
11432
11413
|
function Dot(state) {
|
|
@@ -11751,7 +11732,7 @@ ${input.slice(result.pos)}
|
|
|
11751
11732
|
return result;
|
|
11752
11733
|
}
|
|
11753
11734
|
}
|
|
11754
|
-
var If$0 = $TV($TEXT($S($EXPECT($L115, fail, 'If "if"'), NonIdContinue, $E($EXPECT($
|
|
11735
|
+
var If$0 = $TV($TEXT($S($EXPECT($L115, fail, 'If "if"'), NonIdContinue, $E($EXPECT($L5, fail, 'If " "')))), function($skip, $loc, $0, $1) {
|
|
11755
11736
|
return { $loc, token: $1 };
|
|
11756
11737
|
});
|
|
11757
11738
|
function If(state) {
|
|
@@ -11901,7 +11882,7 @@ ${input.slice(result.pos)}
|
|
|
11901
11882
|
return result;
|
|
11902
11883
|
}
|
|
11903
11884
|
}
|
|
11904
|
-
var Not$0 = $TS($S(CoffeeNotEnabled, $EXPECT($L71, fail, 'Not "not"'), NonIdContinue, $E($EXPECT($
|
|
11885
|
+
var Not$0 = $TS($S(CoffeeNotEnabled, $EXPECT($L71, fail, 'Not "not"'), NonIdContinue, $E($EXPECT($L5, fail, 'Not " "'))), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
11905
11886
|
return { $loc, token: "!" };
|
|
11906
11887
|
});
|
|
11907
11888
|
function Not(state) {
|
|
@@ -12936,7 +12917,7 @@ ${input.slice(result.pos)}
|
|
|
12936
12917
|
return result;
|
|
12937
12918
|
}
|
|
12938
12919
|
}
|
|
12939
|
-
var JSXSelfClosingElement$0 = $TS($S($EXPECT($L120, fail, 'JSXSelfClosingElement "<"'), $TEXT(JSXElementName), $E(
|
|
12920
|
+
var JSXSelfClosingElement$0 = $TS($S($EXPECT($L120, fail, 'JSXSelfClosingElement "<"'), $TEXT(JSXElementName), $E(TypeArguments), $E(JSXAttributes), $E(Whitespace), $EXPECT($L152, fail, 'JSXSelfClosingElement "/>"')), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
|
|
12940
12921
|
return { type: "JSXElement", children: $0 };
|
|
12941
12922
|
});
|
|
12942
12923
|
function JSXSelfClosingElement(state) {
|
|
@@ -12961,7 +12942,7 @@ ${input.slice(result.pos)}
|
|
|
12961
12942
|
return result;
|
|
12962
12943
|
}
|
|
12963
12944
|
}
|
|
12964
|
-
var JSXOpeningElement$0 = $S($EXPECT($L120, fail, 'JSXOpeningElement "<"'), $TEXT(JSXElementName), $E(
|
|
12945
|
+
var JSXOpeningElement$0 = $S($EXPECT($L120, fail, 'JSXOpeningElement "<"'), $TEXT(JSXElementName), $E(TypeArguments), $E(JSXAttributes), $E(Whitespace), $EXPECT($L25, fail, 'JSXOpeningElement ">"'));
|
|
12965
12946
|
function JSXOpeningElement(state) {
|
|
12966
12947
|
let eventData;
|
|
12967
12948
|
if (state.events) {
|
|
@@ -13241,7 +13222,7 @@ ${input.slice(result.pos)}
|
|
|
13241
13222
|
}
|
|
13242
13223
|
});
|
|
13243
13224
|
var JSXAttribute$2 = $S(InsertInlineOpenBrace, DotDotDot, InlineJSXAttributeValue, InsertCloseBrace);
|
|
13244
|
-
var JSXAttribute$3 = $TS($S($EXPECT($
|
|
13225
|
+
var JSXAttribute$3 = $TS($S($EXPECT($L7, fail, 'JSXAttribute "#"'), JSXShorthandString), function($skip, $loc, $0, $1, $2) {
|
|
13245
13226
|
return [" ", "id=", $2];
|
|
13246
13227
|
});
|
|
13247
13228
|
var JSXAttribute$4 = $TS($S(Dot, JSXShorthandString), function($skip, $loc, $0, $1, $2) {
|
|
@@ -14041,7 +14022,7 @@ ${input.slice(result.pos)}
|
|
|
14041
14022
|
}
|
|
14042
14023
|
}
|
|
14043
14024
|
var TypeDeclarationRest$0 = $S(TypeKeyword, $Q(TrailingComment), IdentifierName, $E(TypeParameters), __, Equals, __, Type);
|
|
14044
|
-
var TypeDeclarationRest$1 = $S(Interface, $Q(TrailingComment), IdentifierName, $E(TypeParameters), InterfaceBlock);
|
|
14025
|
+
var TypeDeclarationRest$1 = $S(Interface, $Q(TrailingComment), IdentifierName, $E(TypeParameters), $E(InterfaceExtendsClause), InterfaceBlock);
|
|
14045
14026
|
var TypeDeclarationRest$2 = $S(Namespace, $Q(TrailingComment), IdentifierName, NamespaceBlock);
|
|
14046
14027
|
var TypeDeclarationRest$3 = FunctionSignature;
|
|
14047
14028
|
function TypeDeclarationRest(state) {
|
|
@@ -14066,6 +14047,52 @@ ${input.slice(result.pos)}
|
|
|
14066
14047
|
return result;
|
|
14067
14048
|
}
|
|
14068
14049
|
}
|
|
14050
|
+
var InterfaceExtendsClause$0 = $S(ExtendsToken, InterfaceExtendsTarget);
|
|
14051
|
+
function InterfaceExtendsClause(state) {
|
|
14052
|
+
let eventData;
|
|
14053
|
+
if (state.events) {
|
|
14054
|
+
const result = state.events.enter?.("InterfaceExtendsClause", state);
|
|
14055
|
+
if (result) {
|
|
14056
|
+
if (result.cache)
|
|
14057
|
+
return result.cache;
|
|
14058
|
+
eventData = result.data;
|
|
14059
|
+
}
|
|
14060
|
+
}
|
|
14061
|
+
if (state.tokenize) {
|
|
14062
|
+
const result = $TOKEN("InterfaceExtendsClause", state, InterfaceExtendsClause$0(state));
|
|
14063
|
+
if (state.events)
|
|
14064
|
+
state.events.exit?.("InterfaceExtendsClause", state, result, eventData);
|
|
14065
|
+
return result;
|
|
14066
|
+
} else {
|
|
14067
|
+
const result = InterfaceExtendsClause$0(state);
|
|
14068
|
+
if (state.events)
|
|
14069
|
+
state.events.exit?.("InterfaceExtendsClause", state, result, eventData);
|
|
14070
|
+
return result;
|
|
14071
|
+
}
|
|
14072
|
+
}
|
|
14073
|
+
var InterfaceExtendsTarget$0 = ImplementsTarget;
|
|
14074
|
+
function InterfaceExtendsTarget(state) {
|
|
14075
|
+
let eventData;
|
|
14076
|
+
if (state.events) {
|
|
14077
|
+
const result = state.events.enter?.("InterfaceExtendsTarget", state);
|
|
14078
|
+
if (result) {
|
|
14079
|
+
if (result.cache)
|
|
14080
|
+
return result.cache;
|
|
14081
|
+
eventData = result.data;
|
|
14082
|
+
}
|
|
14083
|
+
}
|
|
14084
|
+
if (state.tokenize) {
|
|
14085
|
+
const result = $TOKEN("InterfaceExtendsTarget", state, InterfaceExtendsTarget$0(state));
|
|
14086
|
+
if (state.events)
|
|
14087
|
+
state.events.exit?.("InterfaceExtendsTarget", state, result, eventData);
|
|
14088
|
+
return result;
|
|
14089
|
+
} else {
|
|
14090
|
+
const result = InterfaceExtendsTarget$0(state);
|
|
14091
|
+
if (state.events)
|
|
14092
|
+
state.events.exit?.("InterfaceExtendsTarget", state, result, eventData);
|
|
14093
|
+
return result;
|
|
14094
|
+
}
|
|
14095
|
+
}
|
|
14069
14096
|
var TypeKeyword$0 = $S($EXPECT($L159, fail, 'TypeKeyword "type"'), NonIdContinue);
|
|
14070
14097
|
function TypeKeyword(state) {
|
|
14071
14098
|
let eventData;
|
|
@@ -14828,7 +14855,7 @@ ${input.slice(result.pos)}
|
|
|
14828
14855
|
return result;
|
|
14829
14856
|
}
|
|
14830
14857
|
}
|
|
14831
|
-
var FunctionType$0 = $S(Parameters, __, $EXPECT($
|
|
14858
|
+
var FunctionType$0 = $S(Parameters, __, $EXPECT($L4, fail, 'FunctionType "=>"'), Type);
|
|
14832
14859
|
function FunctionType(state) {
|
|
14833
14860
|
let eventData;
|
|
14834
14861
|
if (state.events) {
|
|
@@ -14851,7 +14878,7 @@ ${input.slice(result.pos)}
|
|
|
14851
14878
|
return result;
|
|
14852
14879
|
}
|
|
14853
14880
|
}
|
|
14854
|
-
var TypeArguments$0 = $TS($S(
|
|
14881
|
+
var TypeArguments$0 = $TS($S($EXPECT($L120, fail, 'TypeArguments "<"'), $P(TypeArgument), __, $EXPECT($L25, fail, 'TypeArguments ">"')), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
14855
14882
|
return { ts: true, children: $0 };
|
|
14856
14883
|
});
|
|
14857
14884
|
function TypeArguments(state) {
|
|
@@ -14876,103 +14903,6 @@ ${input.slice(result.pos)}
|
|
|
14876
14903
|
return result;
|
|
14877
14904
|
}
|
|
14878
14905
|
}
|
|
14879
|
-
var InlineTypeArguments$0 = $TS($S($Q(_), $EXPECT($L120, fail, 'InlineTypeArguments "<"'), $P(InlineTypeArgument), $Q(_), $EXPECT($L25, fail, 'InlineTypeArguments ">"')), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
|
|
14880
|
-
return { ts: true, children: $0 };
|
|
14881
|
-
});
|
|
14882
|
-
function InlineTypeArguments(state) {
|
|
14883
|
-
let eventData;
|
|
14884
|
-
if (state.events) {
|
|
14885
|
-
const result = state.events.enter?.("InlineTypeArguments", state);
|
|
14886
|
-
if (result) {
|
|
14887
|
-
if (result.cache)
|
|
14888
|
-
return result.cache;
|
|
14889
|
-
eventData = result.data;
|
|
14890
|
-
}
|
|
14891
|
-
}
|
|
14892
|
-
if (state.tokenize) {
|
|
14893
|
-
const result = $TOKEN("InlineTypeArguments", state, InlineTypeArguments$0(state));
|
|
14894
|
-
if (state.events)
|
|
14895
|
-
state.events.exit?.("InlineTypeArguments", state, result, eventData);
|
|
14896
|
-
return result;
|
|
14897
|
-
} else {
|
|
14898
|
-
const result = InlineTypeArguments$0(state);
|
|
14899
|
-
if (state.events)
|
|
14900
|
-
state.events.exit?.("InlineTypeArguments", state, result, eventData);
|
|
14901
|
-
return result;
|
|
14902
|
-
}
|
|
14903
|
-
}
|
|
14904
|
-
var InlineTypeArgument$0 = $S($Q(_), Type, InlineTypeArgumentDelimiter);
|
|
14905
|
-
function InlineTypeArgument(state) {
|
|
14906
|
-
let eventData;
|
|
14907
|
-
if (state.events) {
|
|
14908
|
-
const result = state.events.enter?.("InlineTypeArgument", state);
|
|
14909
|
-
if (result) {
|
|
14910
|
-
if (result.cache)
|
|
14911
|
-
return result.cache;
|
|
14912
|
-
eventData = result.data;
|
|
14913
|
-
}
|
|
14914
|
-
}
|
|
14915
|
-
if (state.tokenize) {
|
|
14916
|
-
const result = $TOKEN("InlineTypeArgument", state, InlineTypeArgument$0(state));
|
|
14917
|
-
if (state.events)
|
|
14918
|
-
state.events.exit?.("InlineTypeArgument", state, result, eventData);
|
|
14919
|
-
return result;
|
|
14920
|
-
} else {
|
|
14921
|
-
const result = InlineTypeArgument$0(state);
|
|
14922
|
-
if (state.events)
|
|
14923
|
-
state.events.exit?.("InlineTypeArgument", state, result, eventData);
|
|
14924
|
-
return result;
|
|
14925
|
-
}
|
|
14926
|
-
}
|
|
14927
|
-
var InlineTypeArgumentDelimiter$0 = $S($Q(_), Comma);
|
|
14928
|
-
var InlineTypeArgumentDelimiter$1 = $Y($S($Q(_), $EXPECT($L25, fail, 'InlineTypeArgumentDelimiter ">"')));
|
|
14929
|
-
function InlineTypeArgumentDelimiter(state) {
|
|
14930
|
-
let eventData;
|
|
14931
|
-
if (state.events) {
|
|
14932
|
-
const result = state.events.enter?.("InlineTypeArgumentDelimiter", state);
|
|
14933
|
-
if (result) {
|
|
14934
|
-
if (result.cache)
|
|
14935
|
-
return result.cache;
|
|
14936
|
-
eventData = result.data;
|
|
14937
|
-
}
|
|
14938
|
-
}
|
|
14939
|
-
if (state.tokenize) {
|
|
14940
|
-
const result = $TOKEN("InlineTypeArgumentDelimiter", state, InlineTypeArgumentDelimiter$0(state) || InlineTypeArgumentDelimiter$1(state));
|
|
14941
|
-
if (state.events)
|
|
14942
|
-
state.events.exit?.("InlineTypeArgumentDelimiter", state, result, eventData);
|
|
14943
|
-
return result;
|
|
14944
|
-
} else {
|
|
14945
|
-
const result = InlineTypeArgumentDelimiter$0(state) || InlineTypeArgumentDelimiter$1(state);
|
|
14946
|
-
if (state.events)
|
|
14947
|
-
state.events.exit?.("InlineTypeArgumentDelimiter", state, result, eventData);
|
|
14948
|
-
return result;
|
|
14949
|
-
}
|
|
14950
|
-
}
|
|
14951
|
-
var CompactTypeArguments$0 = $TS($S($EXPECT($L120, fail, 'CompactTypeArguments "<"'), $P(TypeArgument), __, $EXPECT($L25, fail, 'CompactTypeArguments ">"')), function($skip, $loc, $0, $1, $2, $3, $4) {
|
|
14952
|
-
return { ts: true, children: $0 };
|
|
14953
|
-
});
|
|
14954
|
-
function CompactTypeArguments(state) {
|
|
14955
|
-
let eventData;
|
|
14956
|
-
if (state.events) {
|
|
14957
|
-
const result = state.events.enter?.("CompactTypeArguments", state);
|
|
14958
|
-
if (result) {
|
|
14959
|
-
if (result.cache)
|
|
14960
|
-
return result.cache;
|
|
14961
|
-
eventData = result.data;
|
|
14962
|
-
}
|
|
14963
|
-
}
|
|
14964
|
-
if (state.tokenize) {
|
|
14965
|
-
const result = $TOKEN("CompactTypeArguments", state, CompactTypeArguments$0(state));
|
|
14966
|
-
if (state.events)
|
|
14967
|
-
state.events.exit?.("CompactTypeArguments", state, result, eventData);
|
|
14968
|
-
return result;
|
|
14969
|
-
} else {
|
|
14970
|
-
const result = CompactTypeArguments$0(state);
|
|
14971
|
-
if (state.events)
|
|
14972
|
-
state.events.exit?.("CompactTypeArguments", state, result, eventData);
|
|
14973
|
-
return result;
|
|
14974
|
-
}
|
|
14975
|
-
}
|
|
14976
14906
|
var TypeArgument$0 = $S(__, Type, TypeArgumentDelimiter);
|
|
14977
14907
|
function TypeArgument(state) {
|
|
14978
14908
|
let eventData;
|
|
@@ -16150,6 +16080,16 @@ ${input.slice(result.pos)}
|
|
|
16150
16080
|
};
|
|
16151
16081
|
module.prelude.push(["", ["const ", moduloRef, typeSuffix, " = (a, b) => (a % b + b) % b", "\n"]]);
|
|
16152
16082
|
},
|
|
16083
|
+
returnSymbol(ref) {
|
|
16084
|
+
module.prelude.push({
|
|
16085
|
+
children: [
|
|
16086
|
+
"const ",
|
|
16087
|
+
ref,
|
|
16088
|
+
` = Symbol("return")';
|
|
16089
|
+
`
|
|
16090
|
+
]
|
|
16091
|
+
});
|
|
16092
|
+
},
|
|
16153
16093
|
JSX(jsxRef) {
|
|
16154
16094
|
module.prelude.push({
|
|
16155
16095
|
ts: true,
|
|
@@ -16446,35 +16386,19 @@ ${input.slice(result.pos)}
|
|
|
16446
16386
|
if (!node)
|
|
16447
16387
|
return;
|
|
16448
16388
|
switch (node.type) {
|
|
16449
|
-
case "AssignmentExpression":
|
|
16450
|
-
node.children.unshift(ref, ".push(");
|
|
16451
|
-
node.children.push(")");
|
|
16452
|
-
return;
|
|
16453
|
-
case "Identifier":
|
|
16454
|
-
node.children.unshift(ref, ".push(");
|
|
16455
|
-
node.children.push(")");
|
|
16456
|
-
return;
|
|
16457
16389
|
case "BlockStatement":
|
|
16458
16390
|
insertPush(node.expressions[node.expressions.length - 1], ref);
|
|
16459
16391
|
return;
|
|
16460
|
-
case "ObjectBindingPattern":
|
|
16461
|
-
case "ObjectExpression":
|
|
16462
|
-
module.insertTrimmingSpace(node.children[0], "");
|
|
16463
|
-
node.children.unshift(ref, ".push(");
|
|
16464
|
-
node.children.push(")");
|
|
16465
|
-
return;
|
|
16466
16392
|
case "CaseBlock":
|
|
16467
16393
|
node.clauses.forEach((clause) => {
|
|
16468
16394
|
insertPush(clause, ref);
|
|
16469
16395
|
});
|
|
16470
16396
|
return;
|
|
16471
|
-
case "CaseClause":
|
|
16472
|
-
return;
|
|
16473
16397
|
case "WhenClause":
|
|
16474
|
-
insertPush(node.
|
|
16398
|
+
insertPush(node.block, ref);
|
|
16475
16399
|
return;
|
|
16476
16400
|
case "DefaultClause":
|
|
16477
|
-
insertPush(node.
|
|
16401
|
+
insertPush(node.block, ref);
|
|
16478
16402
|
return;
|
|
16479
16403
|
}
|
|
16480
16404
|
if (!Array.isArray(node))
|
|
@@ -16520,41 +16444,35 @@ ${input.slice(result.pos)}
|
|
|
16520
16444
|
node.splice(1, 0, ref, ".push(");
|
|
16521
16445
|
node.push(")");
|
|
16522
16446
|
}
|
|
16447
|
+
function wrapWithReturn(expression) {
|
|
16448
|
+
const children = expression ? ["return ", expression] : ["return"];
|
|
16449
|
+
return {
|
|
16450
|
+
type: "ReturnStatement",
|
|
16451
|
+
children
|
|
16452
|
+
};
|
|
16453
|
+
}
|
|
16523
16454
|
function insertReturn(node) {
|
|
16524
16455
|
if (!node)
|
|
16525
16456
|
return;
|
|
16526
16457
|
switch (node.type) {
|
|
16527
|
-
case "AssignmentExpression":
|
|
16528
|
-
node.children.unshift("return ");
|
|
16529
|
-
return;
|
|
16530
|
-
case "Identifier":
|
|
16531
|
-
node.children.unshift("return ");
|
|
16532
|
-
return;
|
|
16533
16458
|
case "BlockStatement":
|
|
16534
16459
|
insertReturn(node.expressions[node.expressions.length - 1]);
|
|
16535
16460
|
return;
|
|
16536
|
-
case "ObjectBindingPattern":
|
|
16537
|
-
case "ObjectExpression":
|
|
16538
|
-
module.insertTrimmingSpace(node.children[0], "");
|
|
16539
|
-
node.children.unshift("return ");
|
|
16540
|
-
return;
|
|
16541
16461
|
case "CaseBlock":
|
|
16542
16462
|
node.clauses.forEach((clause) => {
|
|
16543
16463
|
insertReturn(clause);
|
|
16544
16464
|
});
|
|
16545
16465
|
return;
|
|
16546
|
-
case "CaseClause":
|
|
16547
|
-
return;
|
|
16548
16466
|
case "WhenClause":
|
|
16549
16467
|
node.children.splice(node.children.indexOf(node.break), 1);
|
|
16550
|
-
if (node.
|
|
16551
|
-
node.
|
|
16468
|
+
if (node.block.length === 0) {
|
|
16469
|
+
node.block.push(wrapWithReturn());
|
|
16552
16470
|
return;
|
|
16553
16471
|
}
|
|
16554
|
-
insertReturn(node.
|
|
16472
|
+
insertReturn(node.block);
|
|
16555
16473
|
return;
|
|
16556
16474
|
case "DefaultClause":
|
|
16557
|
-
insertReturn(node.
|
|
16475
|
+
insertReturn(node.block);
|
|
16558
16476
|
return;
|
|
16559
16477
|
}
|
|
16560
16478
|
if (!Array.isArray(node))
|
|
@@ -16586,7 +16504,7 @@ ${input.slice(result.pos)}
|
|
|
16586
16504
|
if (exp.children[3])
|
|
16587
16505
|
insertReturn(exp.children[3][2]);
|
|
16588
16506
|
else
|
|
16589
|
-
exp.children.push(["\n", indent,
|
|
16507
|
+
exp.children.push(["\n", indent, wrapWithReturn()]);
|
|
16590
16508
|
return;
|
|
16591
16509
|
case "SwitchStatement":
|
|
16592
16510
|
insertReturn(exp.children[2]);
|
|
@@ -16599,7 +16517,8 @@ ${input.slice(result.pos)}
|
|
|
16599
16517
|
}
|
|
16600
16518
|
if (node[node.length - 1]?.type === "SemicolonDelimiter")
|
|
16601
16519
|
return;
|
|
16602
|
-
|
|
16520
|
+
const returnStatement = wrapWithReturn(node[1]);
|
|
16521
|
+
node.splice(1, 1, returnStatement);
|
|
16603
16522
|
}
|
|
16604
16523
|
module.makeLeftHandSideExpression = function(exp) {
|
|
16605
16524
|
switch (exp.type) {
|
|
@@ -17954,7 +17873,7 @@ var uncacheable;
|
|
|
17954
17873
|
({ parse } = import_parser.default);
|
|
17955
17874
|
({ SourceMap: SourceMap2, base64Encode: base64Encode2 } = util_exports);
|
|
17956
17875
|
defaultOptions = {};
|
|
17957
|
-
uncacheable = /* @__PURE__ */ new Set(["
|
|
17876
|
+
uncacheable = /* @__PURE__ */ new Set(["ActualAssignment", "ApplicationStart", "Arguments", "ArgumentsWithTrailingMemberExpressions", "ArrowFunction", "ArrowFunctionTail", "AssignmentExpression", "AssignmentExpressionTail", "BinaryOpExpression", "BinaryOpRHS", "BracedBlock", "BracedObjectLiteralContent", "BracedOrEmptyBlock", "CallExpression", "CallExpressionRest", "CoffeeCommentEnabled", "ConditionalExpression", "Debugger", "ElseClause", "Expression", "ExpressionStatement", "ExpressionWithIndentedApplicationSuppressed", "ExtendedExpression", "FatArrowBody", "ImplicitInlineObjectPropertyDelimiter", "ImplicitNestedBlock", "IndentedApplicationAllowed", "IndentedFurther", "IndentedJSXChildExpression", "InlineObjectLiteral", "InsertIndent", "JSXChild", "JSXChildren", "JSXElement", "JSXFragment", "JSXImplicitFragment", "JSXMixedChildren", "JSXNestedChildren", "JSXTag", "LeftHandSideExpression", "MemberExpression", "MemberExpressionRest", "Nested", "NestedBindingElement", "NestedBindingElements", "NestedBlockExpression", "NestedBlockExpression", "NestedBlockStatement", "NestedBlockStatements", "NestedElement", "NestedElementList", "NestedImplicitObjectLiteral", "NestedImplicitPropertyDefinition", "NestedImplicitPropertyDefinitions", "NestedInterfaceProperty", "NestedJSXChildExpression", "NestedObject", "NestedPropertyDefinitions", "ObjectLiteral", "PopIndent", "PrimaryExpression", "PushIndent", "Samedent", "ShortCircuitExpression", "SingleLineComment", "SingleLineStatements", "SnugNamedProperty", "Statement", "SuppressIndentedApplication", "ThinArrowFunction", "TrackIndented", "TypedJSXElement", "TypedJSXFragment", "UnaryExpression", "UpdateExpression"]);
|
|
17958
17877
|
var compile = function(src, options = defaultOptions) {
|
|
17959
17878
|
var ast, code, events, filename, sm, srcMapJSON;
|
|
17960
17879
|
filename = options.filename || "unknown";
|