@danielx/civet 0.5.60 → 0.5.61

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 CHANGED
@@ -451,6 +451,7 @@ ${input.slice(result.pos)}
451
451
  ArgumentPart,
452
452
  BinaryOpExpression,
453
453
  BinaryOpRHS,
454
+ RHS,
454
455
  ParenthesizedAssignment,
455
456
  UnaryExpression,
456
457
  UnaryPostfix,
@@ -668,7 +669,7 @@ ${input.slice(result.pos)}
668
669
  TryExpression,
669
670
  CatchClause,
670
671
  CatchBind,
671
- Finally,
672
+ FinallyClause,
672
673
  CatchParameter,
673
674
  Condition,
674
675
  ExpressionWithIndentedApplicationSuppressed,
@@ -801,6 +802,7 @@ ${input.slice(result.pos)}
801
802
  Equals,
802
803
  Export,
803
804
  Extends,
805
+ Finally,
804
806
  For,
805
807
  From,
806
808
  Function,
@@ -935,6 +937,7 @@ ${input.slice(result.pos)}
935
937
  InlineInterfacePropertyDelimiter,
936
938
  TypeBinaryOp,
937
939
  FunctionType,
940
+ TypeArrowFunction,
938
941
  TypeArguments,
939
942
  TypeArgument,
940
943
  TypeArgumentDelimiter,
@@ -1078,41 +1081,41 @@ ${input.slice(result.pos)}
1078
1081
  var $L80 = $L("|");
1079
1082
  var $L81 = $L(";");
1080
1083
  var $L82 = $L("own");
1081
- var $L83 = $L("finally");
1082
- var $L84 = $L("break");
1083
- var $L85 = $L("continue");
1084
- var $L86 = $L("debugger");
1085
- var $L87 = $L("assert");
1086
- var $L88 = $L(":=");
1087
- var $L89 = $L(".=");
1088
- var $L90 = $L("/*");
1089
- var $L91 = $L("*/");
1090
- var $L92 = $L("\\");
1091
- var $L93 = $L("[");
1092
- var $L94 = $L("`");
1093
- var $L95 = $L("abstract");
1094
- var $L96 = $L("as");
1095
- var $L97 = $L("@");
1096
- var $L98 = $L("@@");
1097
- var $L99 = $L("async");
1098
- var $L100 = $L("await");
1099
- var $L101 = $L("by");
1100
- var $L102 = $L("case");
1101
- var $L103 = $L("catch");
1102
- var $L104 = $L("class");
1103
- var $L105 = $L("#{");
1104
- var $L106 = $L(",");
1105
- var $L107 = $L("declare");
1106
- var $L108 = $L("default");
1107
- var $L109 = $L("delete");
1108
- var $L110 = $L("do");
1109
- var $L111 = $L("..");
1110
- var $L112 = $L("...");
1111
- var $L113 = $L("::");
1112
- var $L114 = $L('"');
1113
- var $L115 = $L("else");
1114
- var $L116 = $L("export");
1115
- var $L117 = $L("extends");
1084
+ var $L83 = $L("break");
1085
+ var $L84 = $L("continue");
1086
+ var $L85 = $L("debugger");
1087
+ var $L86 = $L("assert");
1088
+ var $L87 = $L(":=");
1089
+ var $L88 = $L(".=");
1090
+ var $L89 = $L("/*");
1091
+ var $L90 = $L("*/");
1092
+ var $L91 = $L("\\");
1093
+ var $L92 = $L("[");
1094
+ var $L93 = $L("`");
1095
+ var $L94 = $L("abstract");
1096
+ var $L95 = $L("as");
1097
+ var $L96 = $L("@");
1098
+ var $L97 = $L("@@");
1099
+ var $L98 = $L("async");
1100
+ var $L99 = $L("await");
1101
+ var $L100 = $L("by");
1102
+ var $L101 = $L("case");
1103
+ var $L102 = $L("catch");
1104
+ var $L103 = $L("class");
1105
+ var $L104 = $L("#{");
1106
+ var $L105 = $L(",");
1107
+ var $L106 = $L("declare");
1108
+ var $L107 = $L("default");
1109
+ var $L108 = $L("delete");
1110
+ var $L109 = $L("do");
1111
+ var $L110 = $L("..");
1112
+ var $L111 = $L("...");
1113
+ var $L112 = $L("::");
1114
+ var $L113 = $L('"');
1115
+ var $L114 = $L("else");
1116
+ var $L115 = $L("export");
1117
+ var $L116 = $L("extends");
1118
+ var $L117 = $L("finally");
1116
1119
  var $L118 = $L("for");
1117
1120
  var $L119 = $L("from");
1118
1121
  var $L120 = $L("function");
@@ -1868,7 +1871,12 @@ ${input.slice(result.pos)}
1868
1871
  return result;
1869
1872
  }
1870
1873
  }
1871
- var BinaryOpRHS$0 = $S(__, BinaryOp, __, $C(ParenthesizedAssignment, UnaryExpression, ExpressionizedStatement));
1874
+ var BinaryOpRHS$0 = $TS($S(BinaryOp, RHS), function($skip, $loc, $0, $1, $2) {
1875
+ var op = $1;
1876
+ var rhs = $2;
1877
+ return [[], op, [], rhs];
1878
+ });
1879
+ var BinaryOpRHS$1 = $S(__, BinaryOp, $C(_, $S(EOS, __)), RHS);
1872
1880
  function BinaryOpRHS(state) {
1873
1881
  let eventData;
1874
1882
  if (state.events) {
@@ -1880,17 +1888,42 @@ ${input.slice(result.pos)}
1880
1888
  }
1881
1889
  }
1882
1890
  if (state.tokenize) {
1883
- const result = $TOKEN("BinaryOpRHS", state, BinaryOpRHS$0(state));
1891
+ const result = $TOKEN("BinaryOpRHS", state, BinaryOpRHS$0(state) || BinaryOpRHS$1(state));
1884
1892
  if (state.events)
1885
1893
  state.events.exit?.("BinaryOpRHS", state, result, eventData);
1886
1894
  return result;
1887
1895
  } else {
1888
- const result = BinaryOpRHS$0(state);
1896
+ const result = BinaryOpRHS$0(state) || BinaryOpRHS$1(state);
1889
1897
  if (state.events)
1890
1898
  state.events.exit?.("BinaryOpRHS", state, result, eventData);
1891
1899
  return result;
1892
1900
  }
1893
1901
  }
1902
+ var RHS$0 = ParenthesizedAssignment;
1903
+ var RHS$1 = UnaryExpression;
1904
+ var RHS$2 = ExpressionizedStatement;
1905
+ function RHS(state) {
1906
+ let eventData;
1907
+ if (state.events) {
1908
+ const result = state.events.enter?.("RHS", state);
1909
+ if (result) {
1910
+ if (result.cache)
1911
+ return result.cache;
1912
+ eventData = result.data;
1913
+ }
1914
+ }
1915
+ if (state.tokenize) {
1916
+ const result = $TOKEN("RHS", state, RHS$0(state) || RHS$1(state) || RHS$2(state));
1917
+ if (state.events)
1918
+ state.events.exit?.("RHS", state, result, eventData);
1919
+ return result;
1920
+ } else {
1921
+ const result = RHS$0(state) || RHS$1(state) || RHS$2(state);
1922
+ if (state.events)
1923
+ state.events.exit?.("RHS", state, result, eventData);
1924
+ return result;
1925
+ }
1926
+ }
1894
1927
  var ParenthesizedAssignment$0 = $S(InsertOpenParen, ActualAssignment, InsertCloseParen);
1895
1928
  function ParenthesizedAssignment(state) {
1896
1929
  let eventData;
@@ -9229,7 +9262,7 @@ ${input.slice(result.pos)}
9229
9262
  return result;
9230
9263
  }
9231
9264
  }
9232
- var TryStatement$0 = $TS($S(Try, BracedBlock, $E(CatchClause), $E(Finally)), function($skip, $loc, $0, $1, $2, $3, $4) {
9265
+ var TryStatement$0 = $TS($S(Try, BracedOrEmptyBlock, $E(CatchClause), $E(FinallyClause)), function($skip, $loc, $0, $1, $2, $3, $4) {
9233
9266
  var t = $1;
9234
9267
  var b = $2;
9235
9268
  var c = $3;
@@ -9297,7 +9330,7 @@ ${input.slice(result.pos)}
9297
9330
  return result;
9298
9331
  }
9299
9332
  }
9300
- var CatchClause$0 = $S(__, Catch, $E(CatchBind), BracedBlock);
9333
+ var CatchClause$0 = $S($C(Samedent, _), Catch, $E(CatchBind), $C(ThenClause, BracedOrEmptyBlock));
9301
9334
  function CatchClause(state) {
9302
9335
  let eventData;
9303
9336
  if (state.events) {
@@ -9320,8 +9353,8 @@ ${input.slice(result.pos)}
9320
9353
  return result;
9321
9354
  }
9322
9355
  }
9323
- var CatchBind$0 = $S(__, OpenParen, __, CatchParameter, __, CloseParen);
9324
- var CatchBind$1 = $S($N(EOS), $Q(TrailingComment), InsertOpenParen, CatchParameter, InsertCloseParen);
9356
+ var CatchBind$0 = $S($E(_), OpenParen, __, CatchParameter, __, CloseParen);
9357
+ var CatchBind$1 = $S(_, InsertOpenParen, CatchParameter, InsertCloseParen);
9325
9358
  function CatchBind(state) {
9326
9359
  let eventData;
9327
9360
  if (state.events) {
@@ -9344,11 +9377,11 @@ ${input.slice(result.pos)}
9344
9377
  return result;
9345
9378
  }
9346
9379
  }
9347
- var Finally$0 = $S(__, $EXPECT($L83, fail, 'Finally "finally"'), NonIdContinue, BracedBlock);
9348
- function Finally(state) {
9380
+ var FinallyClause$0 = $S($C(Samedent, _), Finally, $C(ThenClause, BracedOrEmptyBlock));
9381
+ function FinallyClause(state) {
9349
9382
  let eventData;
9350
9383
  if (state.events) {
9351
- const result = state.events.enter?.("Finally", state);
9384
+ const result = state.events.enter?.("FinallyClause", state);
9352
9385
  if (result) {
9353
9386
  if (result.cache)
9354
9387
  return result.cache;
@@ -9356,14 +9389,14 @@ ${input.slice(result.pos)}
9356
9389
  }
9357
9390
  }
9358
9391
  if (state.tokenize) {
9359
- const result = $TOKEN("Finally", state, Finally$0(state));
9392
+ const result = $TOKEN("FinallyClause", state, FinallyClause$0(state));
9360
9393
  if (state.events)
9361
- state.events.exit?.("Finally", state, result, eventData);
9394
+ state.events.exit?.("FinallyClause", state, result, eventData);
9362
9395
  return result;
9363
9396
  } else {
9364
- const result = Finally$0(state);
9397
+ const result = FinallyClause$0(state);
9365
9398
  if (state.events)
9366
- state.events.exit?.("Finally", state, result, eventData);
9399
+ state.events.exit?.("FinallyClause", state, result, eventData);
9367
9400
  return result;
9368
9401
  }
9369
9402
  }
@@ -9584,13 +9617,13 @@ ${input.slice(result.pos)}
9584
9617
  return result;
9585
9618
  }
9586
9619
  }
9587
- var KeywordStatement$0 = $T($S($EXPECT($L84, fail, 'KeywordStatement "break"'), NonIdContinue), function(value) {
9620
+ var KeywordStatement$0 = $T($S($EXPECT($L83, fail, 'KeywordStatement "break"'), NonIdContinue), function(value) {
9588
9621
  return { "type": "BreakStatement", "children": value };
9589
9622
  });
9590
- var KeywordStatement$1 = $T($S($EXPECT($L85, fail, 'KeywordStatement "continue"'), NonIdContinue), function(value) {
9623
+ var KeywordStatement$1 = $T($S($EXPECT($L84, fail, 'KeywordStatement "continue"'), NonIdContinue), function(value) {
9591
9624
  return { "type": "ContinueStatement", "children": value };
9592
9625
  });
9593
- var KeywordStatement$2 = $T($S($EXPECT($L86, fail, 'KeywordStatement "debugger"'), NonIdContinue), function(value) {
9626
+ var KeywordStatement$2 = $T($S($EXPECT($L85, fail, 'KeywordStatement "debugger"'), NonIdContinue), function(value) {
9594
9627
  return { "type": "DebuggerStatement", "children": value };
9595
9628
  });
9596
9629
  var KeywordStatement$3 = $T($S(Return, $E(MaybeNestedExpression)), function(value) {
@@ -9621,7 +9654,7 @@ ${input.slice(result.pos)}
9621
9654
  return result;
9622
9655
  }
9623
9656
  }
9624
- var DebuggerExpression$0 = $TS($S($EXPECT($L86, fail, 'DebuggerExpression "debugger"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9657
+ var DebuggerExpression$0 = $TS($S($EXPECT($L85, fail, 'DebuggerExpression "debugger"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9625
9658
  return {
9626
9659
  type: "DebuggerExpression",
9627
9660
  children: ["(()=>{", $1, "})()"]
@@ -9898,7 +9931,7 @@ ${input.slice(result.pos)}
9898
9931
  return result;
9899
9932
  }
9900
9933
  }
9901
- var ImportAssertion$0 = $S($E(_), $EXPECT($L87, fail, 'ImportAssertion "assert"'), NonIdContinue, $E(_), ObjectLiteral);
9934
+ var ImportAssertion$0 = $S($E(_), $EXPECT($L86, fail, 'ImportAssertion "assert"'), NonIdContinue, $E(_), ObjectLiteral);
9902
9935
  function ImportAssertion(state) {
9903
9936
  let eventData;
9904
9937
  if (state.events) {
@@ -10502,7 +10535,7 @@ ${input.slice(result.pos)}
10502
10535
  return result;
10503
10536
  }
10504
10537
  }
10505
- var ConstAssignment$0 = $TV($EXPECT($L88, fail, 'ConstAssignment ":="'), function($skip, $loc, $0, $1) {
10538
+ var ConstAssignment$0 = $TV($EXPECT($L87, fail, 'ConstAssignment ":="'), function($skip, $loc, $0, $1) {
10506
10539
  return { $loc, token: "=" };
10507
10540
  });
10508
10541
  function ConstAssignment(state) {
@@ -10527,7 +10560,7 @@ ${input.slice(result.pos)}
10527
10560
  return result;
10528
10561
  }
10529
10562
  }
10530
- var LetAssignment$0 = $TV($EXPECT($L89, fail, 'LetAssignment ".="'), function($skip, $loc, $0, $1) {
10563
+ var LetAssignment$0 = $TV($EXPECT($L88, fail, 'LetAssignment ".="'), function($skip, $loc, $0, $1) {
10531
10564
  return { $loc, token: "=" };
10532
10565
  });
10533
10566
  function LetAssignment(state) {
@@ -11766,7 +11799,7 @@ ${input.slice(result.pos)}
11766
11799
  return result;
11767
11800
  }
11768
11801
  }
11769
- var JSMultiLineComment$0 = $TV($TEXT($S($EXPECT($L90, fail, 'JSMultiLineComment "/*"'), $Q($S($N($EXPECT($L91, fail, 'JSMultiLineComment "*/"')), $EXPECT($R40, fail, "JSMultiLineComment /./"))), $EXPECT($L91, fail, 'JSMultiLineComment "*/"'))), function($skip, $loc, $0, $1) {
11802
+ var JSMultiLineComment$0 = $TV($TEXT($S($EXPECT($L89, fail, 'JSMultiLineComment "/*"'), $Q($S($N($EXPECT($L90, fail, 'JSMultiLineComment "*/"')), $EXPECT($R40, fail, "JSMultiLineComment /./"))), $EXPECT($L90, fail, 'JSMultiLineComment "*/"'))), function($skip, $loc, $0, $1) {
11770
11803
  return { $loc, token: $1 };
11771
11804
  });
11772
11805
  function JSMultiLineComment(state) {
@@ -11865,7 +11898,7 @@ ${input.slice(result.pos)}
11865
11898
  return result;
11866
11899
  }
11867
11900
  }
11868
- var InlineComment$0 = $TV($TEXT($S($EXPECT($L90, fail, 'InlineComment "/*"'), $TEXT($Q($S($N($EXPECT($L91, fail, 'InlineComment "*/"')), $EXPECT($R44, fail, "InlineComment /[^\\r\\n]/")))), $EXPECT($L91, fail, 'InlineComment "*/"'))), function($skip, $loc, $0, $1) {
11901
+ var InlineComment$0 = $TV($TEXT($S($EXPECT($L89, fail, 'InlineComment "/*"'), $TEXT($Q($S($N($EXPECT($L90, fail, 'InlineComment "*/"')), $EXPECT($R44, fail, "InlineComment /[^\\r\\n]/")))), $EXPECT($L90, fail, 'InlineComment "*/"'))), function($skip, $loc, $0, $1) {
11869
11902
  return { $loc, token: $1 };
11870
11903
  });
11871
11904
  function InlineComment(state) {
@@ -11964,7 +11997,7 @@ ${input.slice(result.pos)}
11964
11997
  var NonNewlineWhitespace$0 = $TR($EXPECT($R45, fail, "NonNewlineWhitespace /[ \\t]+/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
11965
11998
  return { $loc, token: $0 };
11966
11999
  });
11967
- var NonNewlineWhitespace$1 = $T($S(CoffeeLineContinuationEnabled, $EXPECT($L92, fail, 'NonNewlineWhitespace "\\\\\\\\"'), EOL), function(value) {
12000
+ var NonNewlineWhitespace$1 = $T($S(CoffeeLineContinuationEnabled, $EXPECT($L91, fail, 'NonNewlineWhitespace "\\\\\\\\"'), EOL), function(value) {
11968
12001
  return "";
11969
12002
  });
11970
12003
  function NonNewlineWhitespace(state) {
@@ -12116,7 +12149,7 @@ ${input.slice(result.pos)}
12116
12149
  }
12117
12150
  }
12118
12151
  var StatementDelimiter$0 = SemicolonDelimiter;
12119
- var StatementDelimiter$1 = $S($Y($S(Samedent, $C($EXPECT($L2, fail, 'StatementDelimiter "("'), $EXPECT($L93, fail, 'StatementDelimiter "["'), $EXPECT($L94, fail, 'StatementDelimiter "`"'), $EXPECT($L56, fail, 'StatementDelimiter "+"'), $EXPECT($L15, fail, 'StatementDelimiter "-"'), $EXPECT($L52, fail, 'StatementDelimiter "*"'), $EXPECT($L53, fail, 'StatementDelimiter "/"'), ObjectLiteral))), InsertSemicolon);
12152
+ var StatementDelimiter$1 = $S($Y($S(Samedent, $C($EXPECT($L2, fail, 'StatementDelimiter "("'), $EXPECT($L92, fail, 'StatementDelimiter "["'), $EXPECT($L93, fail, 'StatementDelimiter "`"'), $EXPECT($L56, fail, 'StatementDelimiter "+"'), $EXPECT($L15, fail, 'StatementDelimiter "-"'), $EXPECT($L52, fail, 'StatementDelimiter "*"'), $EXPECT($L53, fail, 'StatementDelimiter "/"'), ObjectLiteral))), InsertSemicolon);
12120
12153
  var StatementDelimiter$2 = $Y(EOS);
12121
12154
  function StatementDelimiter(state) {
12122
12155
  let eventData;
@@ -12216,7 +12249,7 @@ ${input.slice(result.pos)}
12216
12249
  return result;
12217
12250
  }
12218
12251
  }
12219
- var Abstract$0 = $TV($TEXT($S($EXPECT($L95, fail, 'Abstract "abstract"'), NonIdContinue, $E($EXPECT($L8, fail, 'Abstract " "')))), function($skip, $loc, $0, $1) {
12252
+ var Abstract$0 = $TV($TEXT($S($EXPECT($L94, fail, 'Abstract "abstract"'), NonIdContinue, $E($EXPECT($L8, fail, 'Abstract " "')))), function($skip, $loc, $0, $1) {
12220
12253
  return { $loc, token: $1, ts: true };
12221
12254
  });
12222
12255
  function Abstract(state) {
@@ -12266,7 +12299,7 @@ ${input.slice(result.pos)}
12266
12299
  return result;
12267
12300
  }
12268
12301
  }
12269
- var As$0 = $TS($S($EXPECT($L96, fail, 'As "as"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12302
+ var As$0 = $TS($S($EXPECT($L95, fail, 'As "as"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12270
12303
  return { $loc, token: $1 };
12271
12304
  });
12272
12305
  function As(state) {
@@ -12291,7 +12324,7 @@ ${input.slice(result.pos)}
12291
12324
  return result;
12292
12325
  }
12293
12326
  }
12294
- var At$0 = $TV($EXPECT($L97, fail, 'At "@"'), function($skip, $loc, $0, $1) {
12327
+ var At$0 = $TV($EXPECT($L96, fail, 'At "@"'), function($skip, $loc, $0, $1) {
12295
12328
  return { $loc, token: $1 };
12296
12329
  });
12297
12330
  function At(state) {
@@ -12316,7 +12349,7 @@ ${input.slice(result.pos)}
12316
12349
  return result;
12317
12350
  }
12318
12351
  }
12319
- var AtAt$0 = $TV($EXPECT($L98, fail, 'AtAt "@@"'), function($skip, $loc, $0, $1) {
12352
+ var AtAt$0 = $TV($EXPECT($L97, fail, 'AtAt "@@"'), function($skip, $loc, $0, $1) {
12320
12353
  return { $loc, token: "@" };
12321
12354
  });
12322
12355
  function AtAt(state) {
@@ -12341,7 +12374,7 @@ ${input.slice(result.pos)}
12341
12374
  return result;
12342
12375
  }
12343
12376
  }
12344
- var Async$0 = $TS($S($EXPECT($L99, fail, 'Async "async"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12377
+ var Async$0 = $TS($S($EXPECT($L98, fail, 'Async "async"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12345
12378
  return { $loc, token: $1, type: "Async" };
12346
12379
  });
12347
12380
  function Async(state) {
@@ -12366,7 +12399,7 @@ ${input.slice(result.pos)}
12366
12399
  return result;
12367
12400
  }
12368
12401
  }
12369
- var Await$0 = $TS($S($EXPECT($L100, fail, 'Await "await"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12402
+ var Await$0 = $TS($S($EXPECT($L99, fail, 'Await "await"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12370
12403
  return { $loc, token: $1 };
12371
12404
  });
12372
12405
  function Await(state) {
@@ -12391,7 +12424,7 @@ ${input.slice(result.pos)}
12391
12424
  return result;
12392
12425
  }
12393
12426
  }
12394
- var Backtick$0 = $TV($EXPECT($L94, fail, 'Backtick "`"'), function($skip, $loc, $0, $1) {
12427
+ var Backtick$0 = $TV($EXPECT($L93, fail, 'Backtick "`"'), function($skip, $loc, $0, $1) {
12395
12428
  return { $loc, token: $1 };
12396
12429
  });
12397
12430
  function Backtick(state) {
@@ -12416,7 +12449,7 @@ ${input.slice(result.pos)}
12416
12449
  return result;
12417
12450
  }
12418
12451
  }
12419
- var By$0 = $TS($S($EXPECT($L101, fail, 'By "by"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12452
+ var By$0 = $TS($S($EXPECT($L100, fail, 'By "by"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12420
12453
  return { $loc, token: $1 };
12421
12454
  });
12422
12455
  function By(state) {
@@ -12441,7 +12474,7 @@ ${input.slice(result.pos)}
12441
12474
  return result;
12442
12475
  }
12443
12476
  }
12444
- var Case$0 = $TS($S($EXPECT($L102, fail, 'Case "case"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12477
+ var Case$0 = $TS($S($EXPECT($L101, fail, 'Case "case"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12445
12478
  return { $loc, token: $1 };
12446
12479
  });
12447
12480
  function Case(state) {
@@ -12466,7 +12499,7 @@ ${input.slice(result.pos)}
12466
12499
  return result;
12467
12500
  }
12468
12501
  }
12469
- var Catch$0 = $TS($S($EXPECT($L103, fail, 'Catch "catch"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12502
+ var Catch$0 = $TS($S($EXPECT($L102, fail, 'Catch "catch"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12470
12503
  return { $loc, token: $1 };
12471
12504
  });
12472
12505
  function Catch(state) {
@@ -12491,7 +12524,7 @@ ${input.slice(result.pos)}
12491
12524
  return result;
12492
12525
  }
12493
12526
  }
12494
- var Class$0 = $TS($S($EXPECT($L104, fail, 'Class "class"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12527
+ var Class$0 = $TS($S($EXPECT($L103, fail, 'Class "class"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12495
12528
  return { $loc, token: $1 };
12496
12529
  });
12497
12530
  function Class(state) {
@@ -12591,7 +12624,7 @@ ${input.slice(result.pos)}
12591
12624
  return result;
12592
12625
  }
12593
12626
  }
12594
- var CoffeeSubstitutionStart$0 = $TV($EXPECT($L105, fail, 'CoffeeSubstitutionStart "#{"'), function($skip, $loc, $0, $1) {
12627
+ var CoffeeSubstitutionStart$0 = $TV($EXPECT($L104, fail, 'CoffeeSubstitutionStart "#{"'), function($skip, $loc, $0, $1) {
12595
12628
  return { $loc, token: "${" };
12596
12629
  });
12597
12630
  function CoffeeSubstitutionStart(state) {
@@ -12641,7 +12674,7 @@ ${input.slice(result.pos)}
12641
12674
  return result;
12642
12675
  }
12643
12676
  }
12644
- var Comma$0 = $TV($EXPECT($L106, fail, 'Comma ","'), function($skip, $loc, $0, $1) {
12677
+ var Comma$0 = $TV($EXPECT($L105, fail, 'Comma ","'), function($skip, $loc, $0, $1) {
12645
12678
  return { $loc, token: $1 };
12646
12679
  });
12647
12680
  function Comma(state) {
@@ -12666,7 +12699,7 @@ ${input.slice(result.pos)}
12666
12699
  return result;
12667
12700
  }
12668
12701
  }
12669
- var ConstructorShorthand$0 = $TV($EXPECT($L97, fail, 'ConstructorShorthand "@"'), function($skip, $loc, $0, $1) {
12702
+ var ConstructorShorthand$0 = $TV($EXPECT($L96, fail, 'ConstructorShorthand "@"'), function($skip, $loc, $0, $1) {
12670
12703
  return { $loc, token: "constructor" };
12671
12704
  });
12672
12705
  function ConstructorShorthand(state) {
@@ -12691,7 +12724,7 @@ ${input.slice(result.pos)}
12691
12724
  return result;
12692
12725
  }
12693
12726
  }
12694
- var Declare$0 = $TS($S($EXPECT($L107, fail, 'Declare "declare"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12727
+ var Declare$0 = $TS($S($EXPECT($L106, fail, 'Declare "declare"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12695
12728
  return { $loc, token: $1 };
12696
12729
  });
12697
12730
  function Declare(state) {
@@ -12716,7 +12749,7 @@ ${input.slice(result.pos)}
12716
12749
  return result;
12717
12750
  }
12718
12751
  }
12719
- var Default$0 = $TS($S($EXPECT($L108, fail, 'Default "default"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12752
+ var Default$0 = $TS($S($EXPECT($L107, fail, 'Default "default"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12720
12753
  return { $loc, token: $1 };
12721
12754
  });
12722
12755
  function Default(state) {
@@ -12741,7 +12774,7 @@ ${input.slice(result.pos)}
12741
12774
  return result;
12742
12775
  }
12743
12776
  }
12744
- var Delete$0 = $TS($S($EXPECT($L109, fail, 'Delete "delete"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12777
+ var Delete$0 = $TS($S($EXPECT($L108, fail, 'Delete "delete"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12745
12778
  return { $loc, token: $1 };
12746
12779
  });
12747
12780
  function Delete(state) {
@@ -12766,7 +12799,7 @@ ${input.slice(result.pos)}
12766
12799
  return result;
12767
12800
  }
12768
12801
  }
12769
- var Do$0 = $TS($S($EXPECT($L110, fail, 'Do "do"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12802
+ var Do$0 = $TS($S($EXPECT($L109, fail, 'Do "do"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12770
12803
  return { $loc, token: $1 };
12771
12804
  });
12772
12805
  function Do(state) {
@@ -12816,7 +12849,7 @@ ${input.slice(result.pos)}
12816
12849
  return result;
12817
12850
  }
12818
12851
  }
12819
- var DotDot$0 = $TV($EXPECT($L111, fail, 'DotDot ".."'), function($skip, $loc, $0, $1) {
12852
+ var DotDot$0 = $TV($EXPECT($L110, fail, 'DotDot ".."'), function($skip, $loc, $0, $1) {
12820
12853
  return { $loc, token: $1 };
12821
12854
  });
12822
12855
  function DotDot(state) {
@@ -12841,7 +12874,7 @@ ${input.slice(result.pos)}
12841
12874
  return result;
12842
12875
  }
12843
12876
  }
12844
- var DotDotDot$0 = $TV($EXPECT($L112, fail, 'DotDotDot "..."'), function($skip, $loc, $0, $1) {
12877
+ var DotDotDot$0 = $TV($EXPECT($L111, fail, 'DotDotDot "..."'), function($skip, $loc, $0, $1) {
12845
12878
  return { $loc, token: $1 };
12846
12879
  });
12847
12880
  function DotDotDot(state) {
@@ -12866,7 +12899,7 @@ ${input.slice(result.pos)}
12866
12899
  return result;
12867
12900
  }
12868
12901
  }
12869
- var DoubleColon$0 = $TV($EXPECT($L113, fail, 'DoubleColon "::"'), function($skip, $loc, $0, $1) {
12902
+ var DoubleColon$0 = $TV($EXPECT($L112, fail, 'DoubleColon "::"'), function($skip, $loc, $0, $1) {
12870
12903
  return { $loc, token: $1 };
12871
12904
  });
12872
12905
  function DoubleColon(state) {
@@ -12891,7 +12924,7 @@ ${input.slice(result.pos)}
12891
12924
  return result;
12892
12925
  }
12893
12926
  }
12894
- var DoubleQuote$0 = $TV($EXPECT($L114, fail, 'DoubleQuote "\\\\\\""'), function($skip, $loc, $0, $1) {
12927
+ var DoubleQuote$0 = $TV($EXPECT($L113, fail, 'DoubleQuote "\\\\\\""'), function($skip, $loc, $0, $1) {
12895
12928
  return { $loc, token: $1 };
12896
12929
  });
12897
12930
  function DoubleQuote(state) {
@@ -12916,7 +12949,7 @@ ${input.slice(result.pos)}
12916
12949
  return result;
12917
12950
  }
12918
12951
  }
12919
- var Else$0 = $TS($S($EXPECT($L115, fail, 'Else "else"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12952
+ var Else$0 = $TS($S($EXPECT($L114, fail, 'Else "else"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12920
12953
  return { $loc, token: $1 };
12921
12954
  });
12922
12955
  function Else(state) {
@@ -12966,7 +12999,7 @@ ${input.slice(result.pos)}
12966
12999
  return result;
12967
13000
  }
12968
13001
  }
12969
- var Export$0 = $TS($S($EXPECT($L116, fail, 'Export "export"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
13002
+ var Export$0 = $TS($S($EXPECT($L115, fail, 'Export "export"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12970
13003
  return { $loc, token: $1 };
12971
13004
  });
12972
13005
  function Export(state) {
@@ -12991,7 +13024,7 @@ ${input.slice(result.pos)}
12991
13024
  return result;
12992
13025
  }
12993
13026
  }
12994
- var Extends$0 = $TS($S($EXPECT($L117, fail, 'Extends "extends"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
13027
+ var Extends$0 = $TS($S($EXPECT($L116, fail, 'Extends "extends"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
12995
13028
  return { $loc, token: $1 };
12996
13029
  });
12997
13030
  function Extends(state) {
@@ -13016,6 +13049,31 @@ ${input.slice(result.pos)}
13016
13049
  return result;
13017
13050
  }
13018
13051
  }
13052
+ var Finally$0 = $TS($S($EXPECT($L117, fail, 'Finally "finally"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
13053
+ return { $loc, token: $1 };
13054
+ });
13055
+ function Finally(state) {
13056
+ let eventData;
13057
+ if (state.events) {
13058
+ const result = state.events.enter?.("Finally", state);
13059
+ if (result) {
13060
+ if (result.cache)
13061
+ return result.cache;
13062
+ eventData = result.data;
13063
+ }
13064
+ }
13065
+ if (state.tokenize) {
13066
+ const result = $TOKEN("Finally", state, Finally$0(state));
13067
+ if (state.events)
13068
+ state.events.exit?.("Finally", state, result, eventData);
13069
+ return result;
13070
+ } else {
13071
+ const result = Finally$0(state);
13072
+ if (state.events)
13073
+ state.events.exit?.("Finally", state, result, eventData);
13074
+ return result;
13075
+ }
13076
+ }
13019
13077
  var For$0 = $TS($S($EXPECT($L118, fail, 'For "for"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
13020
13078
  return { $loc, token: $1 };
13021
13079
  });
@@ -13366,7 +13424,7 @@ ${input.slice(result.pos)}
13366
13424
  return result;
13367
13425
  }
13368
13426
  }
13369
- var OpenBracket$0 = $TV($EXPECT($L93, fail, 'OpenBracket "["'), function($skip, $loc, $0, $1) {
13427
+ var OpenBracket$0 = $TV($EXPECT($L92, fail, 'OpenBracket "["'), function($skip, $loc, $0, $1) {
13370
13428
  return { $loc, token: $1 };
13371
13429
  });
13372
13430
  function OpenBracket(state) {
@@ -13719,7 +13777,7 @@ ${input.slice(result.pos)}
13719
13777
  var Static$0 = $TS($S($EXPECT($L139, fail, 'Static "static"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
13720
13778
  return { $loc, token: $1 };
13721
13779
  });
13722
- var Static$1 = $TS($S($EXPECT($L97, fail, 'Static "@"'), $N($C($EXPECT($L2, fail, 'Static "("'), $EXPECT($L97, fail, 'Static "@"')))), function($skip, $loc, $0, $1, $2) {
13780
+ var Static$1 = $TS($S($EXPECT($L96, fail, 'Static "@"'), $N($C($EXPECT($L2, fail, 'Static "("'), $EXPECT($L96, fail, 'Static "@"')))), function($skip, $loc, $0, $1, $2) {
13723
13781
  return { $loc, token: "static " };
13724
13782
  });
13725
13783
  function Static(state) {
@@ -16487,7 +16545,7 @@ ${input.slice(result.pos)}
16487
16545
  return result;
16488
16546
  }
16489
16547
  }
16490
- var TypeConditional$0 = $TS($S(TypeBinary, $E($S(__, $EXPECT($L117, fail, 'TypeConditional "extends"'), NonIdContinue, Type, $E($S(__, QuestionMark, Type, __, Colon, Type))))), function($skip, $loc, $0, $1, $2) {
16548
+ var TypeConditional$0 = $TS($S(TypeBinary, $E($S(__, $EXPECT($L116, fail, 'TypeConditional "extends"'), NonIdContinue, Type, $E($S(__, QuestionMark, Type, __, Colon, Type))))), function($skip, $loc, $0, $1, $2) {
16491
16549
  if ($2)
16492
16550
  return $0;
16493
16551
  return $1;
@@ -16646,7 +16704,7 @@ ${input.slice(result.pos)}
16646
16704
  return result;
16647
16705
  }
16648
16706
  }
16649
- var FunctionType$0 = $TS($S(Parameters, __, $EXPECT($L7, fail, 'FunctionType "=>"'), $E(Type)), function($skip, $loc, $0, $1, $2, $3, $4) {
16707
+ var FunctionType$0 = $TS($S(Parameters, __, TypeArrowFunction, $E(Type)), function($skip, $loc, $0, $1, $2, $3, $4) {
16650
16708
  var type = $4;
16651
16709
  if (type) {
16652
16710
  return $0;
@@ -16675,6 +16733,34 @@ ${input.slice(result.pos)}
16675
16733
  return result;
16676
16734
  }
16677
16735
  }
16736
+ var TypeArrowFunction$0 = $TV($EXPECT($L7, fail, 'TypeArrowFunction "=>"'), function($skip, $loc, $0, $1) {
16737
+ return { $loc, token: "=>" };
16738
+ });
16739
+ var TypeArrowFunction$1 = $TV($EXPECT($L20, fail, 'TypeArrowFunction "->"'), function($skip, $loc, $0, $1) {
16740
+ return { $loc, token: "=>" };
16741
+ });
16742
+ function TypeArrowFunction(state) {
16743
+ let eventData;
16744
+ if (state.events) {
16745
+ const result = state.events.enter?.("TypeArrowFunction", state);
16746
+ if (result) {
16747
+ if (result.cache)
16748
+ return result.cache;
16749
+ eventData = result.data;
16750
+ }
16751
+ }
16752
+ if (state.tokenize) {
16753
+ const result = $TOKEN("TypeArrowFunction", state, TypeArrowFunction$0(state) || TypeArrowFunction$1(state));
16754
+ if (state.events)
16755
+ state.events.exit?.("TypeArrowFunction", state, result, eventData);
16756
+ return result;
16757
+ } else {
16758
+ const result = TypeArrowFunction$0(state) || TypeArrowFunction$1(state);
16759
+ if (state.events)
16760
+ state.events.exit?.("TypeArrowFunction", state, result, eventData);
16761
+ return result;
16762
+ }
16763
+ }
16678
16764
  var TypeArguments$0 = $TS($S($EXPECT($L128, fail, 'TypeArguments "<"'), $P(TypeArgument), __, $EXPECT($L29, fail, 'TypeArguments ">"')), function($skip, $loc, $0, $1, $2, $3, $4) {
16679
16765
  return { ts: true, children: $0 };
16680
16766
  });
@@ -16800,7 +16886,7 @@ ${input.slice(result.pos)}
16800
16886
  return result;
16801
16887
  }
16802
16888
  }
16803
- var TypeConstraint$0 = $S(__, $EXPECT($L117, fail, 'TypeConstraint "extends"'), NonIdContinue, Type);
16889
+ var TypeConstraint$0 = $S(__, $EXPECT($L116, fail, 'TypeConstraint "extends"'), NonIdContinue, Type);
16804
16890
  function TypeConstraint(state) {
16805
16891
  let eventData;
16806
16892
  if (state.events) {
@@ -20254,7 +20340,7 @@ ${input.slice(result.pos)}
20254
20340
  var uncacheable;
20255
20341
  ({ parse } = import_parser.default);
20256
20342
  ({ SourceMap: SourceMap2, base64Encode: base64Encode2 } = util_exports);
20257
- uncacheable = /* @__PURE__ */ new Set(["ActualAssignment", "ApplicationStart", "Arguments", "ArgumentsWithTrailingMemberExpressions", "ArrowFunction", "ArrowFunctionTail", "AssignmentExpression", "AssignmentExpressionTail", "BinaryOpExpression", "BinaryOpRHS", "BracedBlock", "BracedObjectLiteralContent", "BracedOrEmptyBlock", "CallExpression", "CallExpressionRest", "CoffeeCommentEnabled", "CommaDelimiter", "ConditionalExpression", "Declaration", "Debugger", "ElseClause", "Expression", "ExpressionStatement", "ExpressionWithIndentedApplicationSuppressed", "ExtendedExpression", "FatArrowBody", "FunctionDeclaration", "FunctionExpression", "HoistableDeclaration", "ImplicitArguments", "ImplicitInlineObjectPropertyDelimiter", "ImplicitNestedBlock", "IndentedApplicationAllowed", "IndentedFurther", "IndentedJSXChildExpression", "InlineObjectLiteral", "InsertIndent", "JSXChild", "JSXChildren", "JSXElement", "JSXFragment", "JSXImplicitFragment", "JSXMixedChildren", "JSXNested", "JSXNestedChildren", "JSXOptionalClosingElement", "JSXOptionalClosingFragment", "JSXTag", "LeftHandSideExpression", "MemberExpression", "MemberExpressionRest", "Nested", "NestedBindingElement", "NestedBindingElements", "NestedBlockExpression", "NestedBlockExpression", "NestedBlockStatement", "NestedBlockStatements", "NestedElement", "NestedElementList", "NestedImplicitObjectLiteral", "NestedImplicitPropertyDefinition", "NestedImplicitPropertyDefinitions", "NestedInterfaceProperty", "NestedJSXChildExpression", "NestedObject", "NestedPropertyDefinitions", "NonSuppressedTrailingMemberExpressions", "ObjectLiteral", "PopIndent", "PrimaryExpression", "PushIndent", "PushJSXOpeningElement", "PushJSXOpeningFragment", "Samedent", "ShortCircuitExpression", "SingleLineAssignmentExpression", "SingleLineComment", "SingleLineStatements", "SnugNamedProperty", "Statement", "StatementListItem", "SuppressIndentedApplication", "SuppressTrailingMemberProperty", "ThinArrowFunction", "TrackIndented", "TrailingMemberExpressions", "TrailingMemberPropertyAllowed", "TypedJSXElement", "TypedJSXFragment", "UnaryExpression", "UpdateExpression"]);
20343
+ uncacheable = /* @__PURE__ */ new Set(["ActualAssignment", "ApplicationStart", "Arguments", "ArgumentsWithTrailingMemberExpressions", "ArrowFunction", "ArrowFunctionTail", "AssignmentExpression", "AssignmentExpressionTail", "BinaryOpExpression", "BinaryOpRHS", "BracedBlock", "BracedObjectLiteralContent", "BracedOrEmptyBlock", "CallExpression", "CallExpressionRest", "CoffeeCommentEnabled", "CommaDelimiter", "ConditionalExpression", "Declaration", "Debugger", "ElseClause", "Expression", "ExpressionStatement", "ExpressionWithIndentedApplicationSuppressed", "ExtendedExpression", "FatArrowBody", "FunctionDeclaration", "FunctionExpression", "HoistableDeclaration", "ImplicitArguments", "ImplicitInlineObjectPropertyDelimiter", "ImplicitNestedBlock", "IndentedApplicationAllowed", "IndentedFurther", "IndentedJSXChildExpression", "InlineObjectLiteral", "InsertIndent", "JSXChild", "JSXChildren", "JSXElement", "JSXFragment", "JSXImplicitFragment", "JSXMixedChildren", "JSXNested", "JSXNestedChildren", "JSXOptionalClosingElement", "JSXOptionalClosingFragment", "JSXTag", "LeftHandSideExpression", "MemberExpression", "MemberExpressionRest", "Nested", "NestedBindingElement", "NestedBindingElements", "NestedBlockExpression", "NestedBlockExpression", "NestedBlockStatement", "NestedBlockStatements", "NestedElement", "NestedElementList", "NestedImplicitObjectLiteral", "NestedImplicitPropertyDefinition", "NestedImplicitPropertyDefinitions", "NestedInterfaceProperty", "NestedJSXChildExpression", "NestedObject", "NestedPropertyDefinitions", "NonSuppressedTrailingMemberExpressions", "ObjectLiteral", "PopIndent", "PrimaryExpression", "PushIndent", "PushJSXOpeningElement", "PushJSXOpeningFragment", "RHS", "Samedent", "ShortCircuitExpression", "SingleLineAssignmentExpression", "SingleLineComment", "SingleLineStatements", "SnugNamedProperty", "Statement", "StatementListItem", "SuppressIndentedApplication", "SuppressTrailingMemberProperty", "ThinArrowFunction", "TrackIndented", "TrailingMemberExpressions", "TrailingMemberPropertyAllowed", "TypedJSXElement", "TypedJSXFragment", "UnaryExpression", "UpdateExpression"]);
20258
20344
  var compile = function(src, options) {
20259
20345
  var ast, code, events, filename, ref, result, sm, srcMapJSON;
20260
20346
  if (!options) {