@danielx/civet 0.4.20 → 0.4.22

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.
Files changed (4) hide show
  1. package/README.md +20 -16
  2. package/dist/browser.js +866 -571
  3. package/dist/main.js +866 -571
  4. package/package.json +1 -1
package/dist/browser.js CHANGED
@@ -401,6 +401,7 @@ ${input.slice(result.pos)}
401
401
  Expression,
402
402
  Arguments,
403
403
  ApplicationStart,
404
+ IndentedApplicationAllowed,
404
405
  ArgumentsWithTrailingCallExpressions,
405
406
  ArgumentList,
406
407
  NestedArgumentList,
@@ -439,7 +440,7 @@ ${input.slice(result.pos)}
439
440
  NestedClassElement,
440
441
  ClassElement,
441
442
  FieldDefinition,
442
- This,
443
+ ThisLiteral,
443
444
  LeftHandSideExpression,
444
445
  CallExpression,
445
446
  CallExpressionRest,
@@ -459,6 +460,7 @@ ${input.slice(result.pos)}
459
460
  ParameterElement,
460
461
  ParameterElementDelimiter,
461
462
  BindingIdentifier,
463
+ AtIdentifierRef,
462
464
  BindingPattern,
463
465
  ObjectBindingPattern,
464
466
  ObjectBindingPatternContent,
@@ -500,6 +502,7 @@ ${input.slice(result.pos)}
500
502
  Identifier,
501
503
  IdentifierName,
502
504
  IdentifierReference,
505
+ UpcomingAssignment,
503
506
  ArrayLiteral,
504
507
  RangeExpression,
505
508
  ArrayLiteralContent,
@@ -587,6 +590,8 @@ ${input.slice(result.pos)}
587
590
  Finally,
588
591
  CatchParameter,
589
592
  Condition,
593
+ ExpressionWithIndentedApplicationSuppressed,
594
+ SuppressIndentedApplication,
590
595
  ExpressionStatement,
591
596
  KeywordStatement,
592
597
  DebuggerExpression,
@@ -608,6 +613,7 @@ ${input.slice(result.pos)}
608
613
  ExportFromClause,
609
614
  NamedExports,
610
615
  ExportSpecifier,
616
+ ImplicitExportSpecifier,
611
617
  Declaration,
612
618
  HoistableDeclaration,
613
619
  LexicalDeclaration,
@@ -656,6 +662,7 @@ ${input.slice(result.pos)}
656
662
  JSMultiLineComment,
657
663
  CoffeeSingleLineComment,
658
664
  CoffeeMultiLineComment,
665
+ CoffeeHereCommentStart,
659
666
  InlineComment,
660
667
  RestOfLine,
661
668
  TrailingComment,
@@ -719,6 +726,7 @@ ${input.slice(result.pos)}
719
726
  Switch,
720
727
  Target,
721
728
  Then,
729
+ This,
722
730
  Throw,
723
731
  TripleDoubleQuote,
724
732
  TripleSingleQuote,
@@ -800,6 +808,7 @@ ${input.slice(result.pos)}
800
808
  InsertOpenParen,
801
809
  InsertCloseParen,
802
810
  InsertOpenBrace,
811
+ InsertInlineOpenBrace,
803
812
  InsertCloseBrace,
804
813
  InsertConst,
805
814
  InsertReadonly,
@@ -829,13 +838,13 @@ ${input.slice(result.pos)}
829
838
  PopIndent,
830
839
  Nested
831
840
  });
832
- var $L0 = $L("++");
833
- var $L1 = $L("--");
834
- var $L2 = $L("=>");
835
- var $L3 = $L(" ");
836
- var $L4 = $L("<");
837
- var $L5 = $L("extends");
838
- var $L6 = $L("this");
841
+ var $L0 = $L("");
842
+ var $L1 = $L("++");
843
+ var $L2 = $L("--");
844
+ var $L3 = $L("=>");
845
+ var $L4 = $L(" ");
846
+ var $L5 = $L("<");
847
+ var $L6 = $L("extends");
839
848
  var $L7 = $L("#");
840
849
  var $L8 = $L(".");
841
850
  var $L9 = $L("super");
@@ -843,37 +852,37 @@ ${input.slice(result.pos)}
843
852
  var $L11 = $L("!");
844
853
  var $L12 = $L("super[");
845
854
  var $L13 = $L("import.meta");
846
- var $L14 = $L("");
847
- var $L15 = $L(")");
848
- var $L16 = $L("->");
849
- var $L17 = $L("null");
850
- var $L18 = $L("true");
851
- var $L19 = $L("false");
852
- var $L20 = $L("yes");
853
- var $L21 = $L("on");
854
- var $L22 = $L("no");
855
- var $L23 = $L("off");
856
- var $L24 = $L(",");
857
- var $L25 = $L("]");
858
- var $L26 = $L(":");
859
- var $L27 = $L("}");
860
- var $L28 = $L("**=");
861
- var $L29 = $L("*=");
862
- var $L30 = $L("/=");
863
- var $L31 = $L("%=");
864
- var $L32 = $L("+=");
865
- var $L33 = $L("-=");
866
- var $L34 = $L("<<=");
867
- var $L35 = $L(">>>=");
868
- var $L36 = $L(">>=");
869
- var $L37 = $L("&&=");
870
- var $L38 = $L("&=");
871
- var $L39 = $L("^=");
872
- var $L40 = $L("||=");
873
- var $L41 = $L("|=");
874
- var $L42 = $L("??=");
875
- var $L43 = $L("?=");
876
- var $L44 = $L("=");
855
+ var $L14 = $L(")");
856
+ var $L15 = $L("->");
857
+ var $L16 = $L("null");
858
+ var $L17 = $L("true");
859
+ var $L18 = $L("false");
860
+ var $L19 = $L("yes");
861
+ var $L20 = $L("on");
862
+ var $L21 = $L("no");
863
+ var $L22 = $L("off");
864
+ var $L23 = $L(",");
865
+ var $L24 = $L("=");
866
+ var $L25 = $L(">");
867
+ var $L26 = $L("]");
868
+ var $L27 = $L(":");
869
+ var $L28 = $L("}");
870
+ var $L29 = $L("**=");
871
+ var $L30 = $L("*=");
872
+ var $L31 = $L("/=");
873
+ var $L32 = $L("%=");
874
+ var $L33 = $L("+=");
875
+ var $L34 = $L("-=");
876
+ var $L35 = $L("<<=");
877
+ var $L36 = $L(">>>=");
878
+ var $L37 = $L(">>=");
879
+ var $L38 = $L("&&=");
880
+ var $L39 = $L("&=");
881
+ var $L40 = $L("^=");
882
+ var $L41 = $L("||=");
883
+ var $L42 = $L("|=");
884
+ var $L43 = $L("??=");
885
+ var $L44 = $L("?=");
877
886
  var $L45 = $L("and=");
878
887
  var $L46 = $L("or=");
879
888
  var $L47 = $L("**");
@@ -887,107 +896,106 @@ ${input.slice(result.pos)}
887
896
  var $L55 = $L("<<");
888
897
  var $L56 = $L(">>>");
889
898
  var $L57 = $L(">>");
890
- var $L58 = $L(">");
891
- var $L59 = $L("!==");
892
- var $L60 = $L("!=");
893
- var $L61 = $L("isnt");
894
- var $L62 = $L("is");
895
- var $L63 = $L("===");
896
- var $L64 = $L("==");
897
- var $L65 = $L("and");
898
- var $L66 = $L("&&");
899
- var $L67 = $L("of");
900
- var $L68 = $L("or");
901
- var $L69 = $L("||");
902
- var $L70 = $L("??");
903
- var $L71 = $L("?");
904
- var $L72 = $L("instanceof");
899
+ var $L58 = $L("!==");
900
+ var $L59 = $L("!=");
901
+ var $L60 = $L("isnt");
902
+ var $L61 = $L("is");
903
+ var $L62 = $L("===");
904
+ var $L63 = $L("==");
905
+ var $L64 = $L("and");
906
+ var $L65 = $L("&&");
907
+ var $L66 = $L("of");
908
+ var $L67 = $L("or");
909
+ var $L68 = $L("||");
910
+ var $L69 = $L("??");
911
+ var $L70 = $L("?");
912
+ var $L71 = $L("instanceof");
913
+ var $L72 = $L("not");
905
914
  var $L73 = $L("in");
906
- var $L74 = $L("not");
907
- var $L75 = $L("&");
908
- var $L76 = $L("^");
909
- var $L77 = $L("|");
910
- var $L78 = $L(";");
911
- var $L79 = $L("own");
912
- var $L80 = $L("finally");
913
- var $L81 = $L("break");
914
- var $L82 = $L("continue");
915
- var $L83 = $L("debugger");
916
- var $L84 = $L("import type");
917
- var $L85 = $L("default");
918
- var $L86 = $L(":=");
919
- var $L87 = $L("/*");
920
- var $L88 = $L("*/");
921
- var $L89 = $L("###");
922
- var $L90 = $L("\\");
923
- var $L91 = $L("as");
924
- var $L92 = $L("@");
925
- var $L93 = $L("async");
926
- var $L94 = $L("await");
927
- var $L95 = $L("`");
928
- var $L96 = $L("by");
929
- var $L97 = $L("case");
930
- var $L98 = $L("catch");
931
- var $L99 = $L("class");
932
- var $L100 = $L("#{");
933
- var $L101 = $L("delete");
934
- var $L102 = $L("do");
935
- var $L103 = $L("..");
936
- var $L104 = $L("...");
937
- var $L105 = $L("::");
938
- var $L106 = $L('"');
939
- var $L107 = $L("else");
940
- var $L108 = $L("export");
941
- var $L109 = $L("for");
942
- var $L110 = $L("from");
943
- var $L111 = $L("function");
944
- var $L112 = $L("get");
945
- var $L113 = $L("set");
946
- var $L114 = $L("if");
947
- var $L115 = $L("let");
948
- var $L116 = $L("const");
949
- var $L117 = $L("loop");
950
- var $L118 = $L("new");
951
- var $L119 = $L("{");
952
- var $L120 = $L("[");
953
- var $L121 = $L("(");
954
- var $L122 = $L("return");
955
- var $L123 = $L("'");
956
- var $L124 = $L("static");
957
- var $L125 = $L("${");
958
- var $L126 = $L("switch");
959
- var $L127 = $L("target");
960
- var $L128 = $L("then");
961
- var $L129 = $L("throw");
962
- var $L130 = $L('"""');
963
- var $L131 = $L("'''");
964
- var $L132 = $L("///");
965
- var $L133 = $L("```");
966
- var $L134 = $L("try");
967
- var $L135 = $L("typeof");
968
- var $L136 = $L("unless");
969
- var $L137 = $L("until");
970
- var $L138 = $L("var");
971
- var $L139 = $L("void");
972
- var $L140 = $L("when");
973
- var $L141 = $L("while");
974
- var $L142 = $L("yield");
975
- var $L143 = $L("/>");
976
- var $L144 = $L("</");
977
- var $L145 = $L("<>");
978
- var $L146 = $L("</>");
979
- var $L147 = $L("declare");
980
- var $L148 = $L("type");
981
- var $L149 = $L("interface");
982
- var $L150 = $L("namespace");
983
- var $L151 = $L("readonly");
984
- var $L152 = $L("asserts");
985
- var $L153 = $L("keyof");
986
- var $L154 = $L("infer");
987
- var $L155 = $L("[]");
988
- var $L156 = $L("civet");
989
- var $L157 = $L(" ");
990
- var $L158 = $L(" ");
915
+ var $L74 = $L("&");
916
+ var $L75 = $L("^");
917
+ var $L76 = $L("|");
918
+ var $L77 = $L(";");
919
+ var $L78 = $L("own");
920
+ var $L79 = $L("finally");
921
+ var $L80 = $L("break");
922
+ var $L81 = $L("continue");
923
+ var $L82 = $L("debugger");
924
+ var $L83 = $L("import type");
925
+ var $L84 = $L("default");
926
+ var $L85 = $L(":=");
927
+ var $L86 = $L("/*");
928
+ var $L87 = $L("*/");
929
+ var $L88 = $L("\\");
930
+ var $L89 = $L("as");
931
+ var $L90 = $L("@");
932
+ var $L91 = $L("async");
933
+ var $L92 = $L("await");
934
+ var $L93 = $L("`");
935
+ var $L94 = $L("by");
936
+ var $L95 = $L("case");
937
+ var $L96 = $L("catch");
938
+ var $L97 = $L("class");
939
+ var $L98 = $L("#{");
940
+ var $L99 = $L("delete");
941
+ var $L100 = $L("do");
942
+ var $L101 = $L("..");
943
+ var $L102 = $L("...");
944
+ var $L103 = $L("::");
945
+ var $L104 = $L('"');
946
+ var $L105 = $L("else");
947
+ var $L106 = $L("export");
948
+ var $L107 = $L("for");
949
+ var $L108 = $L("from");
950
+ var $L109 = $L("function");
951
+ var $L110 = $L("get");
952
+ var $L111 = $L("set");
953
+ var $L112 = $L("if");
954
+ var $L113 = $L("let");
955
+ var $L114 = $L("const");
956
+ var $L115 = $L("loop");
957
+ var $L116 = $L("new");
958
+ var $L117 = $L("{");
959
+ var $L118 = $L("[");
960
+ var $L119 = $L("(");
961
+ var $L120 = $L("return");
962
+ var $L121 = $L("'");
963
+ var $L122 = $L("static");
964
+ var $L123 = $L("${");
965
+ var $L124 = $L("switch");
966
+ var $L125 = $L("target");
967
+ var $L126 = $L("then");
968
+ var $L127 = $L("this");
969
+ var $L128 = $L("throw");
970
+ var $L129 = $L('"""');
971
+ var $L130 = $L("'''");
972
+ var $L131 = $L("///");
973
+ var $L132 = $L("```");
974
+ var $L133 = $L("try");
975
+ var $L134 = $L("typeof");
976
+ var $L135 = $L("unless");
977
+ var $L136 = $L("until");
978
+ var $L137 = $L("var");
979
+ var $L138 = $L("void");
980
+ var $L139 = $L("when");
981
+ var $L140 = $L("while");
982
+ var $L141 = $L("yield");
983
+ var $L142 = $L("/>");
984
+ var $L143 = $L("</");
985
+ var $L144 = $L("<>");
986
+ var $L145 = $L("</>");
987
+ var $L146 = $L("declare");
988
+ var $L147 = $L("type");
989
+ var $L148 = $L("interface");
990
+ var $L149 = $L("namespace");
991
+ var $L150 = $L("readonly");
992
+ var $L151 = $L("asserts");
993
+ var $L152 = $L("keyof");
994
+ var $L153 = $L("infer");
995
+ var $L154 = $L("[]");
996
+ var $L155 = $L("civet");
997
+ var $L156 = $L(" ");
998
+ var $L157 = $L(" ");
991
999
  var $R0 = $R(new RegExp("(for|of|then|when)(?!\\p{ID_Continue}|[\\u200C\\u200D$])", "suy"));
992
1000
  var $R1 = $R(new RegExp("[&]", "suy"));
993
1001
  var $R2 = $R(new RegExp("[!~+-]+", "suy"));
@@ -1021,25 +1029,27 @@ ${input.slice(result.pos)}
1021
1029
  var $R30 = $R(new RegExp("(?:on|off|yes|no)(?!\\p{ID_Continue})", "suy"));
1022
1030
  var $R31 = $R(new RegExp("(?:isnt)(?!\\p{ID_Continue})", "suy"));
1023
1031
  var $R32 = $R(new RegExp("(?:by)(?!\\p{ID_Continue})", "suy"));
1024
- var $R33 = $R(new RegExp("(?:and|as|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|return|static|super|switch|this|throw|true|try|typeof|unless|until|var|void|while|with|yield)(?!\\p{ID_Continue})", "suy"));
1025
- var $R34 = $R(new RegExp("\\/\\/(?!\\/)[^\\r\\n]*", "suy"));
1026
- var $R35 = $R(new RegExp(".", "suy"));
1027
- var $R36 = $R(new RegExp("#(?!##)([^\\r\\n]*)", "suy"));
1028
- var $R37 = $R(new RegExp("[^\\r\\n]", "suy"));
1029
- var $R38 = $R(new RegExp("[ \\t]+", "suy"));
1030
- var $R39 = $R(new RegExp("(?!\\p{ID_Continue})", "suy"));
1031
- var $R40 = $R(new RegExp("\\s", "suy"));
1032
- var $R41 = $R(new RegExp("(?:\\p{ID_Start}|[_$])(?:\\p{ID_Continue}|[\\u200C\\u200D$-])*", "suy"));
1033
- var $R42 = $R(new RegExp('"[^"]*"', "suy"));
1034
- var $R43 = $R(new RegExp("'[^']*'", "suy"));
1035
- var $R44 = $R(new RegExp("[^{}<>]+", "suy"));
1036
- var $R45 = $R(new RegExp("[+-]?", "suy"));
1037
- var $R46 = $R(new RegExp("[+-]", "suy"));
1038
- var $R47 = $R(new RegExp("#![^\\r\\n]*", "suy"));
1039
- var $R48 = $R(new RegExp("[\\t ]*", "suy"));
1040
- var $R49 = $R(new RegExp("[\\s]*", "suy"));
1041
- var $R50 = $R(new RegExp("\\s+([+-]?)([a-zA-Z0-9-]+)", "suy"));
1042
- var $R51 = $R(new RegExp("\\r\\n|\\n|\\r|$", "suy"));
1032
+ var $R33 = $R(new RegExp("(?:of)(?!\\p{ID_Continue})", "suy"));
1033
+ var $R34 = $R(new RegExp("(?:and|as|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|return|static|super|switch|this|throw|true|try|typeof|unless|until|var|void|while|with|yield)(?!\\p{ID_Continue})", "suy"));
1034
+ var $R35 = $R(new RegExp("\\/\\/(?!\\/)[^\\r\\n]*", "suy"));
1035
+ var $R36 = $R(new RegExp(".", "suy"));
1036
+ var $R37 = $R(new RegExp("#(?!##(?!#))([^\\r\\n]*)", "suy"));
1037
+ var $R38 = $R(new RegExp("###(?!#)", "suy"));
1038
+ var $R39 = $R(new RegExp("[^\\r\\n]", "suy"));
1039
+ var $R40 = $R(new RegExp("[ \\t]+", "suy"));
1040
+ var $R41 = $R(new RegExp("(?!\\p{ID_Continue})", "suy"));
1041
+ var $R42 = $R(new RegExp("\\s", "suy"));
1042
+ var $R43 = $R(new RegExp("(?:\\p{ID_Start}|[_$])(?:\\p{ID_Continue}|[\\u200C\\u200D$-])*", "suy"));
1043
+ var $R44 = $R(new RegExp('"[^"]*"', "suy"));
1044
+ var $R45 = $R(new RegExp("'[^']*'", "suy"));
1045
+ var $R46 = $R(new RegExp("[^{}<>]+", "suy"));
1046
+ var $R47 = $R(new RegExp("[+-]?", "suy"));
1047
+ var $R48 = $R(new RegExp("[+-]", "suy"));
1048
+ var $R49 = $R(new RegExp("#![^\\r\\n]*", "suy"));
1049
+ var $R50 = $R(new RegExp("[\\t ]*", "suy"));
1050
+ var $R51 = $R(new RegExp("[\\s]*", "suy"));
1051
+ var $R52 = $R(new RegExp("\\s+([+-]?)([a-zA-Z0-9-]+)", "suy"));
1052
+ var $R53 = $R(new RegExp("\\r\\n|\\n|\\r|$", "suy"));
1043
1053
  var Program$0 = $TS($S(Reset, Init, __, $Q(TopLevelStatement), __), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
1044
1054
  var statements = $4;
1045
1055
  module.processProgram(statements);
@@ -1089,9 +1099,10 @@ ${input.slice(result.pos)}
1089
1099
  return $skip;
1090
1100
  });
1091
1101
  var ExtendedExpression$1 = $TS($S(__, ExpressionizedStatement), function($skip, $loc, $0, $1, $2) {
1092
- return Object.assign({}, $2, {
1102
+ return {
1103
+ ...$2,
1093
1104
  children: [...$1, ...$2.children]
1094
- });
1105
+ };
1095
1106
  });
1096
1107
  var ExtendedExpression$2 = AssignmentExpression;
1097
1108
  function ExtendedExpression(state) {
@@ -1185,7 +1196,7 @@ ${input.slice(result.pos)}
1185
1196
  return result;
1186
1197
  }
1187
1198
  }
1188
- var ApplicationStart$0 = $Y(NestedImplicitObjectLiteral);
1199
+ var ApplicationStart$0 = $S(IndentedApplicationAllowed, $Y(NestedImplicitObjectLiteral));
1189
1200
  var ApplicationStart$1 = $S($N(EOS), $Y($S($P(_), $N(AdditionalReservedWords))));
1190
1201
  function ApplicationStart(state) {
1191
1202
  if (state.events) {
@@ -1205,6 +1216,29 @@ ${input.slice(result.pos)}
1205
1216
  return result;
1206
1217
  }
1207
1218
  }
1219
+ var IndentedApplicationAllowed$0 = $TV($EXPECT($L0, fail, 'IndentedApplicationAllowed ""'), function($skip, $loc, $0, $1) {
1220
+ if (module.suppressIndentedApplication)
1221
+ return $skip;
1222
+ return;
1223
+ });
1224
+ function IndentedApplicationAllowed(state) {
1225
+ if (state.events) {
1226
+ const result = state.events.enter?.("IndentedApplicationAllowed", state);
1227
+ if (result)
1228
+ return result.cache;
1229
+ }
1230
+ if (state.tokenize) {
1231
+ const result = $TOKEN("IndentedApplicationAllowed", state, IndentedApplicationAllowed$0(state));
1232
+ if (state.events)
1233
+ state.events.exit?.("IndentedApplicationAllowed", state, result);
1234
+ return result;
1235
+ } else {
1236
+ const result = IndentedApplicationAllowed$0(state);
1237
+ if (state.events)
1238
+ state.events.exit?.("IndentedApplicationAllowed", state, result);
1239
+ return result;
1240
+ }
1241
+ }
1208
1242
  var ArgumentsWithTrailingCallExpressions$0 = $S(Arguments, $Q($S(Samedent, $N(Backtick), CallExpressionRest)));
1209
1243
  function ArgumentsWithTrailingCallExpressions(state) {
1210
1244
  if (state.events) {
@@ -1427,9 +1461,10 @@ ${input.slice(result.pos)}
1427
1461
  switch (exp.type) {
1428
1462
  case "Identifier":
1429
1463
  case "Literal":
1430
- return Object.assign({}, exp, {
1464
+ return {
1465
+ ...exp,
1431
1466
  children: [...pre, ...exp.children, post]
1432
- });
1467
+ };
1433
1468
  default:
1434
1469
  return {
1435
1470
  type: "ParenthesizedExpression",
@@ -1536,7 +1571,7 @@ ${input.slice(result.pos)}
1536
1571
  return result;
1537
1572
  }
1538
1573
  }
1539
- var UpdateExpressionSymbol$0 = $TV($C($EXPECT($L0, fail, 'UpdateExpressionSymbol "++"'), $EXPECT($L1, fail, 'UpdateExpressionSymbol "--"')), function($skip, $loc, $0, $1) {
1574
+ var UpdateExpressionSymbol$0 = $TV($C($EXPECT($L1, fail, 'UpdateExpressionSymbol "++"'), $EXPECT($L2, fail, 'UpdateExpressionSymbol "--"')), function($skip, $loc, $0, $1) {
1540
1575
  return { $loc, token: $1 };
1541
1576
  });
1542
1577
  function UpdateExpressionSymbol(state) {
@@ -1616,7 +1651,9 @@ ${input.slice(result.pos)}
1616
1651
  return {
1617
1652
  type: "AssignmentExpression",
1618
1653
  children: $0,
1619
- names: null
1654
+ names: null,
1655
+ lhs: $1,
1656
+ exp: $2
1620
1657
  };
1621
1658
  });
1622
1659
  function ActualAssignment(state) {
@@ -1678,9 +1715,10 @@ ${input.slice(result.pos)}
1678
1715
  }
1679
1716
  var ArrowFunction$0 = $TS($S($E($S(Async, __)), ArrowFunctionTail), function($skip, $loc, $0, $1, $2) {
1680
1717
  var tail = $2;
1681
- return Object.assign({}, tail, {
1718
+ return {
1719
+ ...tail,
1682
1720
  children: [...$1 || [], ...tail.children]
1683
- });
1721
+ };
1684
1722
  });
1685
1723
  function ArrowFunction(state) {
1686
1724
  if (state.events) {
@@ -1732,7 +1770,7 @@ ${input.slice(result.pos)}
1732
1770
  return result;
1733
1771
  }
1734
1772
  }
1735
- var FatArrow$0 = $TS($S(__, $EXPECT($L2, fail, 'FatArrow "=>"')), function($skip, $loc, $0, $1, $2) {
1773
+ var FatArrow$0 = $TS($S(__, $EXPECT($L3, fail, 'FatArrow "=>"')), function($skip, $loc, $0, $1, $2) {
1736
1774
  var ws = $1;
1737
1775
  if (!ws.length)
1738
1776
  return " =>";
@@ -1803,7 +1841,7 @@ ${input.slice(result.pos)}
1803
1841
  }
1804
1842
  }
1805
1843
  var TernaryRest$0 = NestedTernaryRest;
1806
- var TernaryRest$1 = $TS($S($N(CoffeeBinaryExistentialEnabled), $Y($EXPECT($L3, fail, 'TernaryRest " "')), $Q(TrailingComment), QuestionMark, ExtendedExpression, __, Colon, ExtendedExpression), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8) {
1844
+ var TernaryRest$1 = $TS($S($N(CoffeeBinaryExistentialEnabled), $Y($EXPECT($L4, fail, 'TernaryRest " "')), $Q(TrailingComment), QuestionMark, ExtendedExpression, __, Colon, ExtendedExpression), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8) {
1807
1845
  return $0.slice(2);
1808
1846
  });
1809
1847
  function TernaryRest(state) {
@@ -1866,7 +1904,7 @@ ${input.slice(result.pos)}
1866
1904
  return result;
1867
1905
  }
1868
1906
  }
1869
- var PrimaryExpression$0 = This;
1907
+ var PrimaryExpression$0 = ThisLiteral;
1870
1908
  var PrimaryExpression$1 = Literal;
1871
1909
  var PrimaryExpression$2 = ArrayLiteral;
1872
1910
  var PrimaryExpression$3 = ObjectLiteral;
@@ -1900,20 +1938,7 @@ ${input.slice(result.pos)}
1900
1938
  var exp = $2;
1901
1939
  var post = $3;
1902
1940
  if (post) {
1903
- let clause;
1904
- switch (post[1].type) {
1905
- case "IterationStatement":
1906
- case "ForStatement":
1907
- clause = module.addPostfixStatement(exp, ...post);
1908
- return {
1909
- type: "IterationExpression",
1910
- children: [clause],
1911
- block: clause.block
1912
- };
1913
- case "IfStatement":
1914
- clause = module.expressionizeIfClause(post[1], exp);
1915
- return clause;
1916
- }
1941
+ return module.attachPostfixStatementAsExpression(exp, post);
1917
1942
  }
1918
1943
  return {
1919
1944
  type: "ParenthesizedExpression",
@@ -1996,10 +2021,10 @@ ${input.slice(result.pos)}
1996
2021
  return result;
1997
2022
  }
1998
2023
  }
1999
- var ExtendsToken$0 = $TV($EXPECT($L4, fail, 'ExtendsToken "<"'), function($skip, $loc, $0, $1) {
2024
+ var ExtendsToken$0 = $TV($EXPECT($L5, fail, 'ExtendsToken "<"'), function($skip, $loc, $0, $1) {
2000
2025
  return { $loc, token: "extends" };
2001
2026
  });
2002
- var ExtendsToken$1 = $TV($EXPECT($L5, fail, 'ExtendsToken "extends"'), function($skip, $loc, $0, $1) {
2027
+ var ExtendsToken$1 = $TV($EXPECT($L6, fail, 'ExtendsToken "extends"'), function($skip, $loc, $0, $1) {
2003
2028
  return { $loc, token: $1 };
2004
2029
  });
2005
2030
  function ExtendsToken(state) {
@@ -2021,7 +2046,7 @@ ${input.slice(result.pos)}
2021
2046
  }
2022
2047
  }
2023
2048
  var ClassBody$0 = $S(__, OpenBrace, $E(NestedClassElements), __, CloseBrace);
2024
- var ClassBody$1 = $S(InsertOpenBrace, NestedClassElements, InsertNewline, InsertIndent, InsertCloseBrace);
2049
+ var ClassBody$1 = $S(InsertOpenBrace, $E(NestedClassElements), InsertNewline, InsertIndent, InsertCloseBrace);
2025
2050
  function ClassBody(state) {
2026
2051
  if (state.events) {
2027
2052
  const result = state.events.enter?.("ClassBody", state);
@@ -2144,33 +2169,31 @@ ${input.slice(result.pos)}
2144
2169
  return result;
2145
2170
  }
2146
2171
  }
2147
- var This$0 = $TV($EXPECT($L6, fail, 'This "this"'), function($skip, $loc, $0, $1) {
2148
- return { $loc, token: $1 };
2149
- });
2150
- var This$1 = $TS($S(At, $TEXT($S($E($EXPECT($L7, fail, 'This "#"')), IdentifierName))), function($skip, $loc, $0, $1, $2) {
2172
+ var ThisLiteral$0 = This;
2173
+ var ThisLiteral$1 = $TS($S(At, $TEXT($S($E($EXPECT($L7, fail, 'ThisLiteral "#"')), IdentifierName))), function($skip, $loc, $0, $1, $2) {
2151
2174
  var t = $1;
2152
2175
  var id = $2;
2153
2176
  return [{ ...t, token: "this." }, id];
2154
2177
  });
2155
- var This$2 = $TS($S(At), function($skip, $loc, $0, $1) {
2178
+ var ThisLiteral$2 = $TS($S(At), function($skip, $loc, $0, $1) {
2156
2179
  $1.token = "this";
2157
2180
  return $1;
2158
2181
  });
2159
- function This(state) {
2182
+ function ThisLiteral(state) {
2160
2183
  if (state.events) {
2161
- const result = state.events.enter?.("This", state);
2184
+ const result = state.events.enter?.("ThisLiteral", state);
2162
2185
  if (result)
2163
2186
  return result.cache;
2164
2187
  }
2165
2188
  if (state.tokenize) {
2166
- const result = $TOKEN("This", state, This$0(state) || This$1(state) || This$2(state));
2189
+ const result = $TOKEN("ThisLiteral", state, ThisLiteral$0(state) || ThisLiteral$1(state) || ThisLiteral$2(state));
2167
2190
  if (state.events)
2168
- state.events.exit?.("This", state, result);
2191
+ state.events.exit?.("ThisLiteral", state, result);
2169
2192
  return result;
2170
2193
  } else {
2171
- const result = This$0(state) || This$1(state) || This$2(state);
2194
+ const result = ThisLiteral$0(state) || ThisLiteral$1(state) || ThisLiteral$2(state);
2172
2195
  if (state.events)
2173
- state.events.exit?.("This", state, result);
2196
+ state.events.exit?.("ThisLiteral", state, result);
2174
2197
  return result;
2175
2198
  }
2176
2199
  }
@@ -2544,7 +2567,7 @@ ${input.slice(result.pos)}
2544
2567
  }
2545
2568
  }
2546
2569
  var Parameters$0 = NonEmptyParameters;
2547
- var Parameters$1 = $TV($EXPECT($L14, fail, 'Parameters ""'), function($skip, $loc, $0, $1) {
2570
+ var Parameters$1 = $TV($EXPECT($L0, fail, 'Parameters ""'), function($skip, $loc, $0, $1) {
2548
2571
  return {
2549
2572
  type: "Parameters",
2550
2573
  children: [{ $loc, token: "()" }],
@@ -2589,8 +2612,7 @@ ${input.slice(result.pos)}
2589
2612
  if (after.length) {
2590
2613
  const spliceRef = module.getSpliceRef();
2591
2614
  blockPrefix = {
2592
- type: "AssignmentExpression",
2593
- children: ["let [", module.insertTrimmingSpace(after, ""), "] = ", spliceRef, ".call(", restIdentifier, ", -", after.length.toString(), ")"],
2615
+ children: ["[", module.insertTrimmingSpace(after, ""), "] = ", spliceRef, ".call(", restIdentifier, ", -", after.length.toString(), ")"],
2594
2616
  names: after.flatMap((p) => p.names)
2595
2617
  };
2596
2618
  }
@@ -2684,7 +2706,7 @@ ${input.slice(result.pos)}
2684
2706
  }
2685
2707
  }
2686
2708
  var ParameterElementDelimiter$0 = $S($Q(_), Comma);
2687
- var ParameterElementDelimiter$1 = $Y($S(__, $EXPECT($L15, fail, 'ParameterElementDelimiter ")"')));
2709
+ var ParameterElementDelimiter$1 = $Y($S(__, $EXPECT($L14, fail, 'ParameterElementDelimiter ")"')));
2688
2710
  var ParameterElementDelimiter$2 = $TV($Y(EOS), function($skip, $loc, $0, $1) {
2689
2711
  return { $loc, token: "," };
2690
2712
  });
@@ -2706,21 +2728,18 @@ ${input.slice(result.pos)}
2706
2728
  return result;
2707
2729
  }
2708
2730
  }
2709
- var BindingIdentifier$0 = $TS($S(__, $E(At), Identifier), function($skip, $loc, $0, $1, $2, $3) {
2731
+ var BindingIdentifier$0 = $TS($S(__, At, AtIdentifierRef), function($skip, $loc, $0, $1, $2, $3) {
2710
2732
  var ws = $1;
2711
- var at = $2;
2712
- var id = $3;
2713
- if (at) {
2714
- const ref = {
2715
- type: "Ref",
2716
- base: id.name
2717
- };
2718
- return {
2719
- type: "AtBinding",
2720
- children: [...ws, ref],
2721
- ref
2722
- };
2723
- }
2733
+ var ref = $3;
2734
+ return {
2735
+ type: "AtBinding",
2736
+ children: [...ws, ref],
2737
+ ref
2738
+ };
2739
+ });
2740
+ var BindingIdentifier$1 = $TS($S(__, Identifier), function($skip, $loc, $0, $1, $2) {
2741
+ var ws = $1;
2742
+ var id = $2;
2724
2743
  return {
2725
2744
  ...id,
2726
2745
  children: [...ws, ...id.children]
@@ -2733,17 +2752,51 @@ ${input.slice(result.pos)}
2733
2752
  return result.cache;
2734
2753
  }
2735
2754
  if (state.tokenize) {
2736
- const result = $TOKEN("BindingIdentifier", state, BindingIdentifier$0(state));
2755
+ const result = $TOKEN("BindingIdentifier", state, BindingIdentifier$0(state) || BindingIdentifier$1(state));
2737
2756
  if (state.events)
2738
2757
  state.events.exit?.("BindingIdentifier", state, result);
2739
2758
  return result;
2740
2759
  } else {
2741
- const result = BindingIdentifier$0(state);
2760
+ const result = BindingIdentifier$0(state) || BindingIdentifier$1(state);
2742
2761
  if (state.events)
2743
2762
  state.events.exit?.("BindingIdentifier", state, result);
2744
2763
  return result;
2745
2764
  }
2746
2765
  }
2766
+ var AtIdentifierRef$0 = $TV(ReservedWord, function($skip, $loc, $0, $1) {
2767
+ var r = $0;
2768
+ return {
2769
+ type: "Ref",
2770
+ base: `_${r}`,
2771
+ id: r
2772
+ };
2773
+ });
2774
+ var AtIdentifierRef$1 = $TV(IdentifierName, function($skip, $loc, $0, $1) {
2775
+ var id = $0;
2776
+ return {
2777
+ type: "Ref",
2778
+ base: id.name,
2779
+ id: id.name
2780
+ };
2781
+ });
2782
+ function AtIdentifierRef(state) {
2783
+ if (state.events) {
2784
+ const result = state.events.enter?.("AtIdentifierRef", state);
2785
+ if (result)
2786
+ return result.cache;
2787
+ }
2788
+ if (state.tokenize) {
2789
+ const result = $TOKEN("AtIdentifierRef", state, AtIdentifierRef$0(state) || AtIdentifierRef$1(state));
2790
+ if (state.events)
2791
+ state.events.exit?.("AtIdentifierRef", state, result);
2792
+ return result;
2793
+ } else {
2794
+ const result = AtIdentifierRef$0(state) || AtIdentifierRef$1(state);
2795
+ if (state.events)
2796
+ state.events.exit?.("AtIdentifierRef", state, result);
2797
+ return result;
2798
+ }
2799
+ }
2747
2800
  var BindingPattern$0 = $TS($S(__, ObjectBindingPattern), function($skip, $loc, $0, $1, $2) {
2748
2801
  var p = $2;
2749
2802
  return {
@@ -2754,7 +2807,7 @@ ${input.slice(result.pos)}
2754
2807
  var BindingPattern$1 = $TS($S(__, ArrayBindingPattern), function($skip, $loc, $0, $1, $2) {
2755
2808
  var p = $2;
2756
2809
  return {
2757
- children: [...$1, p],
2810
+ children: [...$1, p.children],
2758
2811
  names: p.names
2759
2812
  };
2760
2813
  });
@@ -2779,6 +2832,7 @@ ${input.slice(result.pos)}
2779
2832
  var ObjectBindingPattern$0 = $TS($S(OpenBrace, ObjectBindingPatternContent, __, CloseBrace), function($skip, $loc, $0, $1, $2, $3, $4) {
2780
2833
  var c = $2;
2781
2834
  return {
2835
+ type: "ObjectBindingPattern",
2782
2836
  children: [$1, ...c.children, ...$3, $4],
2783
2837
  names: c.names
2784
2838
  };
@@ -2839,6 +2893,7 @@ ${input.slice(result.pos)}
2839
2893
  var ArrayBindingPattern$0 = $TS($S(OpenBracket, ArrayBindingPatternContent, __, CloseBracket), function($skip, $loc, $0, $1, $2, $3, $4) {
2840
2894
  var c = $2;
2841
2895
  return {
2896
+ type: "ArrayBindingPattern",
2842
2897
  names: c.names,
2843
2898
  children: $0
2844
2899
  };
@@ -2882,8 +2937,7 @@ ${input.slice(result.pos)}
2882
2937
  if (after.length) {
2883
2938
  const spliceRef = module.getSpliceRef();
2884
2939
  blockPrefix = {
2885
- type: "AssignmentExpression",
2886
- children: ["let [", module.insertTrimmingSpace(after, ""), "] = ", spliceRef, ".call(", restIdentifier, ", -", after.length.toString(), ")"],
2940
+ children: ["[", module.insertTrimmingSpace(after, ""), "] = ", spliceRef, ".call(", restIdentifier, ", -", after.length.toString(), ")"],
2887
2941
  names: after.flatMap((p) => p.names)
2888
2942
  };
2889
2943
  }
@@ -3116,8 +3170,7 @@ ${input.slice(result.pos)}
3116
3170
  if (after.length) {
3117
3171
  const spliceRef = module.getSpliceRef();
3118
3172
  blockPrefix = {
3119
- type: "AssignmentExpression",
3120
- children: ["let [", module.insertTrimmingSpace(after, ""), "] = ", spliceRef, ".call(", restIdentifier, ", -", after.length.toString(), ")"],
3173
+ children: ["[", module.insertTrimmingSpace(after, ""), "] = ", spliceRef, ".call(", restIdentifier, ", -", after.length.toString(), ")"],
3121
3174
  names: after.flatMap((p) => p.names)
3122
3175
  };
3123
3176
  }
@@ -3235,8 +3288,12 @@ ${input.slice(result.pos)}
3235
3288
  return result;
3236
3289
  }
3237
3290
  }
3238
- var EmptyBindingPattern$0 = $TV($EXPECT($L14, fail, 'EmptyBindingPattern ""'), function($skip, $loc, $0, $1) {
3239
- const ref = { type: "Ref", base: "ref" };
3291
+ var EmptyBindingPattern$0 = $TV($EXPECT($L0, fail, 'EmptyBindingPattern ""'), function($skip, $loc, $0, $1) {
3292
+ const ref = {
3293
+ type: "Ref",
3294
+ base: "ref",
3295
+ id: "ref"
3296
+ };
3240
3297
  return {
3241
3298
  type: "EmptyBinding",
3242
3299
  children: [ref],
@@ -3404,7 +3461,7 @@ ${input.slice(result.pos)}
3404
3461
  return result;
3405
3462
  }
3406
3463
  }
3407
- var Arrow$0 = $TV($EXPECT($L16, fail, 'Arrow "->"'), function($skip, $loc, $0, $1) {
3464
+ var Arrow$0 = $TV($EXPECT($L15, fail, 'Arrow "->"'), function($skip, $loc, $0, $1) {
3408
3465
  return { $loc, token: $1 };
3409
3466
  });
3410
3467
  function Arrow(state) {
@@ -3784,7 +3841,7 @@ ${input.slice(result.pos)}
3784
3841
  return result;
3785
3842
  }
3786
3843
  }
3787
- var NullLiteral$0 = $TV($EXPECT($L17, fail, 'NullLiteral "null"'), function($skip, $loc, $0, $1) {
3844
+ var NullLiteral$0 = $TV($EXPECT($L16, fail, 'NullLiteral "null"'), function($skip, $loc, $0, $1) {
3788
3845
  return { $loc, token: $1 };
3789
3846
  });
3790
3847
  function NullLiteral(state) {
@@ -3808,7 +3865,7 @@ ${input.slice(result.pos)}
3808
3865
  var BooleanLiteral$0 = $T($S(CoffeeBooleansEnabled, CoffeeScriptBooleanLiteral), function(value) {
3809
3866
  return value[1];
3810
3867
  });
3811
- var BooleanLiteral$1 = $TS($S($C($EXPECT($L18, fail, 'BooleanLiteral "true"'), $EXPECT($L19, fail, 'BooleanLiteral "false"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
3868
+ var BooleanLiteral$1 = $TS($S($C($EXPECT($L17, fail, 'BooleanLiteral "true"'), $EXPECT($L18, fail, 'BooleanLiteral "false"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
3812
3869
  return { $loc, token: $1 };
3813
3870
  });
3814
3871
  function BooleanLiteral(state) {
@@ -3829,10 +3886,10 @@ ${input.slice(result.pos)}
3829
3886
  return result;
3830
3887
  }
3831
3888
  }
3832
- var CoffeeScriptBooleanLiteral$0 = $TS($S($C($EXPECT($L20, fail, 'CoffeeScriptBooleanLiteral "yes"'), $EXPECT($L21, fail, 'CoffeeScriptBooleanLiteral "on"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
3889
+ var CoffeeScriptBooleanLiteral$0 = $TS($S($C($EXPECT($L19, fail, 'CoffeeScriptBooleanLiteral "yes"'), $EXPECT($L20, fail, 'CoffeeScriptBooleanLiteral "on"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
3833
3890
  return { $loc, token: "true" };
3834
3891
  });
3835
- var CoffeeScriptBooleanLiteral$1 = $TS($S($C($EXPECT($L22, fail, 'CoffeeScriptBooleanLiteral "no"'), $EXPECT($L23, fail, 'CoffeeScriptBooleanLiteral "off"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
3892
+ var CoffeeScriptBooleanLiteral$1 = $TS($S($C($EXPECT($L21, fail, 'CoffeeScriptBooleanLiteral "no"'), $EXPECT($L22, fail, 'CoffeeScriptBooleanLiteral "off"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
3836
3893
  return { $loc, token: "false" };
3837
3894
  });
3838
3895
  function CoffeeScriptBooleanLiteral(state) {
@@ -3853,7 +3910,7 @@ ${input.slice(result.pos)}
3853
3910
  return result;
3854
3911
  }
3855
3912
  }
3856
- var Comma$0 = $TV($EXPECT($L24, fail, 'Comma ","'), function($skip, $loc, $0, $1) {
3913
+ var Comma$0 = $TV($EXPECT($L23, fail, 'Comma ","'), function($skip, $loc, $0, $1) {
3857
3914
  return { $loc, token: $1 };
3858
3915
  });
3859
3916
  function Comma(state) {
@@ -3943,7 +4000,29 @@ ${input.slice(result.pos)}
3943
4000
  return result;
3944
4001
  }
3945
4002
  }
3946
- var ArrayLiteral$0 = $TS($S(OpenBracket, ArrayLiteralContent, __, CloseBracket), function($skip, $loc, $0, $1, $2, $3, $4) {
4003
+ var UpcomingAssignment$0 = $Y($S(__, $EXPECT($L24, fail, 'UpcomingAssignment "="'), $N($C($EXPECT($L24, fail, 'UpcomingAssignment "="'), $EXPECT($L25, fail, 'UpcomingAssignment ">"')))));
4004
+ function UpcomingAssignment(state) {
4005
+ if (state.events) {
4006
+ const result = state.events.enter?.("UpcomingAssignment", state);
4007
+ if (result)
4008
+ return result.cache;
4009
+ }
4010
+ if (state.tokenize) {
4011
+ const result = $TOKEN("UpcomingAssignment", state, UpcomingAssignment$0(state));
4012
+ if (state.events)
4013
+ state.events.exit?.("UpcomingAssignment", state, result);
4014
+ return result;
4015
+ } else {
4016
+ const result = UpcomingAssignment$0(state);
4017
+ if (state.events)
4018
+ state.events.exit?.("UpcomingAssignment", state, result);
4019
+ return result;
4020
+ }
4021
+ }
4022
+ var ArrayLiteral$0 = $T($S(ArrayBindingPattern, UpcomingAssignment), function(value) {
4023
+ return value[0];
4024
+ });
4025
+ var ArrayLiteral$1 = $TS($S(OpenBracket, ArrayLiteralContent, __, CloseBracket), function($skip, $loc, $0, $1, $2, $3, $4) {
3947
4026
  var content = $2;
3948
4027
  var ws = $3;
3949
4028
  if (content.type === "RangeExpression") {
@@ -3974,12 +4053,12 @@ ${input.slice(result.pos)}
3974
4053
  return result.cache;
3975
4054
  }
3976
4055
  if (state.tokenize) {
3977
- const result = $TOKEN("ArrayLiteral", state, ArrayLiteral$0(state));
4056
+ const result = $TOKEN("ArrayLiteral", state, ArrayLiteral$0(state) || ArrayLiteral$1(state));
3978
4057
  if (state.events)
3979
4058
  state.events.exit?.("ArrayLiteral", state, result);
3980
4059
  return result;
3981
4060
  } else {
3982
- const result = ArrayLiteral$0(state);
4061
+ const result = ArrayLiteral$0(state) || ArrayLiteral$1(state);
3983
4062
  if (state.events)
3984
4063
  state.events.exit?.("ArrayLiteral", state, result);
3985
4064
  return result;
@@ -4159,8 +4238,8 @@ ${input.slice(result.pos)}
4159
4238
  return result;
4160
4239
  }
4161
4240
  }
4162
- var ArrayElementDelimiter$0 = $S($Q(_), Comma);
4163
- var ArrayElementDelimiter$1 = $Y($S(__, $EXPECT($L25, fail, 'ArrayElementDelimiter "]"')));
4241
+ var ArrayElementDelimiter$0 = $S(__, Comma);
4242
+ var ArrayElementDelimiter$1 = $Y($S(__, $EXPECT($L26, fail, 'ArrayElementDelimiter "]"')));
4164
4243
  var ArrayElementDelimiter$2 = $TV($Y(EOS), function($skip, $loc, $0, $1) {
4165
4244
  return { $loc, token: "," };
4166
4245
  });
@@ -4217,7 +4296,7 @@ ${input.slice(result.pos)}
4217
4296
  return result;
4218
4297
  }
4219
4298
  }
4220
- var ElementListRest$0 = $S($S(__, Comma, __), ArrayElementExpression);
4299
+ var ElementListRest$0 = $S($S(__, Comma), ArrayElementExpression);
4221
4300
  function ElementListRest(state) {
4222
4301
  if (state.events) {
4223
4302
  const result = state.events.enter?.("ElementListRest", state);
@@ -4236,10 +4315,18 @@ ${input.slice(result.pos)}
4236
4315
  return result;
4237
4316
  }
4238
4317
  }
4239
- var ArrayElementExpression$0 = $TS($S(ExtendedExpression, __, DotDotDot), function($skip, $loc, $0, $1, $2, $3) {
4318
+ var ArrayElementExpression$0 = $TS($S($E(ExtendedExpression), __, DotDotDot, $Y(ArrayElementDelimiter)), function($skip, $loc, $0, $1, $2, $3, $4) {
4240
4319
  var exp = $1;
4241
4320
  var ws = $2;
4242
4321
  var dots = $3;
4322
+ if (!exp) {
4323
+ exp = {
4324
+ type: "Ref",
4325
+ base: "ref",
4326
+ id: "ref",
4327
+ names: []
4328
+ };
4329
+ }
4243
4330
  return {
4244
4331
  type: "SpreadElement",
4245
4332
  children: [...ws, dots, exp],
@@ -4287,9 +4374,12 @@ ${input.slice(result.pos)}
4287
4374
  return result;
4288
4375
  }
4289
4376
  }
4290
- var ObjectLiteral$0 = BracedObjectLiteral;
4291
- var ObjectLiteral$1 = NestedImplicitObjectLiteral;
4292
- var ObjectLiteral$2 = InlineObjectLiteral;
4377
+ var ObjectLiteral$0 = $T($S(ObjectBindingPattern, UpcomingAssignment), function(value) {
4378
+ return value[0];
4379
+ });
4380
+ var ObjectLiteral$1 = BracedObjectLiteral;
4381
+ var ObjectLiteral$2 = NestedImplicitObjectLiteral;
4382
+ var ObjectLiteral$3 = InlineObjectLiteral;
4293
4383
  function ObjectLiteral(state) {
4294
4384
  if (state.events) {
4295
4385
  const result = state.events.enter?.("ObjectLiteral", state);
@@ -4297,12 +4387,12 @@ ${input.slice(result.pos)}
4297
4387
  return result.cache;
4298
4388
  }
4299
4389
  if (state.tokenize) {
4300
- const result = $TOKEN("ObjectLiteral", state, ObjectLiteral$0(state) || ObjectLiteral$1(state) || ObjectLiteral$2(state));
4390
+ const result = $TOKEN("ObjectLiteral", state, ObjectLiteral$0(state) || ObjectLiteral$1(state) || ObjectLiteral$2(state) || ObjectLiteral$3(state));
4301
4391
  if (state.events)
4302
4392
  state.events.exit?.("ObjectLiteral", state, result);
4303
4393
  return result;
4304
4394
  } else {
4305
- const result = ObjectLiteral$0(state) || ObjectLiteral$1(state) || ObjectLiteral$2(state);
4395
+ const result = ObjectLiteral$0(state) || ObjectLiteral$1(state) || ObjectLiteral$2(state) || ObjectLiteral$3(state);
4306
4396
  if (state.events)
4307
4397
  state.events.exit?.("ObjectLiteral", state, result);
4308
4398
  return result;
@@ -4465,14 +4555,13 @@ ${input.slice(result.pos)}
4465
4555
  return result;
4466
4556
  }
4467
4557
  }
4468
- var NestedPropertyDefinition$0 = $TS($S(Nested, PropertyDefinition, ObjectPropertyDelimiter), function($skip, $loc, $0, $1, $2, $3) {
4558
+ var NestedPropertyDefinition$0 = $TS($S(Nested, $P($S(PropertyDefinition, ObjectPropertyDelimiter))), function($skip, $loc, $0, $1, $2) {
4469
4559
  var ws = $1;
4470
- var prop = $2;
4471
- var delimiter = $3;
4472
- return {
4560
+ var inlineProps = $2;
4561
+ return inlineProps.map(([prop, delimiter], i) => ({
4473
4562
  ...prop,
4474
- children: [...ws, ...prop.children, delimiter]
4475
- };
4563
+ children: [...i === 0 ? ws : [], ...prop.children, delimiter]
4564
+ }));
4476
4565
  });
4477
4566
  function NestedPropertyDefinition(state) {
4478
4567
  if (state.events) {
@@ -4492,10 +4581,10 @@ ${input.slice(result.pos)}
4492
4581
  return result;
4493
4582
  }
4494
4583
  }
4495
- var InlineObjectLiteral$0 = $TS($S(InsertOpenBrace, SnugNamedProperty, ImplicitInlineObjectPropertyDelimiter, $Q($S(NamedProperty, ImplicitInlineObjectPropertyDelimiter)), InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
4584
+ var InlineObjectLiteral$0 = $TS($S(InsertInlineOpenBrace, SnugNamedProperty, ImplicitInlineObjectPropertyDelimiter, $Q($S(NamedProperty, ImplicitInlineObjectPropertyDelimiter)), InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4, $5) {
4496
4585
  var open = $1;
4497
4586
  var close = $5;
4498
- return [open[1], $2, $3, ...$4, close];
4587
+ return [open, $2, $3, ...$4, close];
4499
4588
  });
4500
4589
  function InlineObjectLiteral(state) {
4501
4590
  if (state.events) {
@@ -4515,13 +4604,14 @@ ${input.slice(result.pos)}
4515
4604
  return result;
4516
4605
  }
4517
4606
  }
4518
- var ImplicitInlineObjectPropertyDelimiter$0 = $T($Y($S(EOS, NamedProperty)), function(value) {
4607
+ var ImplicitInlineObjectPropertyDelimiter$0 = $S($Q(TrailingComment), $EXPECT($L23, fail, 'ImplicitInlineObjectPropertyDelimiter ","'));
4608
+ var ImplicitInlineObjectPropertyDelimiter$1 = $T($Y($S(EOS, NamedProperty)), function(value) {
4519
4609
  return ",";
4520
4610
  });
4521
- var ImplicitInlineObjectPropertyDelimiter$1 = $T($Y($S(__, $EXPECT($L26, fail, 'ImplicitInlineObjectPropertyDelimiter ":"'))), function(value) {
4611
+ var ImplicitInlineObjectPropertyDelimiter$2 = $T($Y($S(__, $C($EXPECT($L27, fail, 'ImplicitInlineObjectPropertyDelimiter ":"'), $EXPECT($L14, fail, 'ImplicitInlineObjectPropertyDelimiter ")"'), $EXPECT($L26, fail, 'ImplicitInlineObjectPropertyDelimiter "]"'), $EXPECT($L28, fail, 'ImplicitInlineObjectPropertyDelimiter "}"'), ReservedWord))), function(value) {
4522
4612
  return "";
4523
4613
  });
4524
- var ImplicitInlineObjectPropertyDelimiter$2 = $T($Y(EOS), function(value) {
4614
+ var ImplicitInlineObjectPropertyDelimiter$3 = $T($Y(EOS), function(value) {
4525
4615
  return "";
4526
4616
  });
4527
4617
  function ImplicitInlineObjectPropertyDelimiter(state) {
@@ -4531,19 +4621,19 @@ ${input.slice(result.pos)}
4531
4621
  return result.cache;
4532
4622
  }
4533
4623
  if (state.tokenize) {
4534
- const result = $TOKEN("ImplicitInlineObjectPropertyDelimiter", state, ImplicitInlineObjectPropertyDelimiter$0(state) || ImplicitInlineObjectPropertyDelimiter$1(state) || ImplicitInlineObjectPropertyDelimiter$2(state));
4624
+ const result = $TOKEN("ImplicitInlineObjectPropertyDelimiter", state, ImplicitInlineObjectPropertyDelimiter$0(state) || ImplicitInlineObjectPropertyDelimiter$1(state) || ImplicitInlineObjectPropertyDelimiter$2(state) || ImplicitInlineObjectPropertyDelimiter$3(state));
4535
4625
  if (state.events)
4536
4626
  state.events.exit?.("ImplicitInlineObjectPropertyDelimiter", state, result);
4537
4627
  return result;
4538
4628
  } else {
4539
- const result = ImplicitInlineObjectPropertyDelimiter$0(state) || ImplicitInlineObjectPropertyDelimiter$1(state) || ImplicitInlineObjectPropertyDelimiter$2(state);
4629
+ const result = ImplicitInlineObjectPropertyDelimiter$0(state) || ImplicitInlineObjectPropertyDelimiter$1(state) || ImplicitInlineObjectPropertyDelimiter$2(state) || ImplicitInlineObjectPropertyDelimiter$3(state);
4540
4630
  if (state.events)
4541
4631
  state.events.exit?.("ImplicitInlineObjectPropertyDelimiter", state, result);
4542
4632
  return result;
4543
4633
  }
4544
4634
  }
4545
4635
  var ObjectPropertyDelimiter$0 = $S($Q(_), Comma);
4546
- var ObjectPropertyDelimiter$1 = $Y($S(__, $EXPECT($L27, fail, 'ObjectPropertyDelimiter "}"')));
4636
+ var ObjectPropertyDelimiter$1 = $Y($S(__, $EXPECT($L28, fail, 'ObjectPropertyDelimiter "}"')));
4547
4637
  var ObjectPropertyDelimiter$2 = $TV($Y(EOS), function($skip, $loc, $0, $1) {
4548
4638
  return { $loc, token: "," };
4549
4639
  });
@@ -4876,25 +4966,25 @@ ${input.slice(result.pos)}
4876
4966
  return result;
4877
4967
  }
4878
4968
  }
4879
- var AssignmentOpSymbol$0 = $EXPECT($L28, fail, 'AssignmentOpSymbol "**="');
4880
- var AssignmentOpSymbol$1 = $EXPECT($L29, fail, 'AssignmentOpSymbol "*="');
4881
- var AssignmentOpSymbol$2 = $EXPECT($L30, fail, 'AssignmentOpSymbol "/="');
4882
- var AssignmentOpSymbol$3 = $EXPECT($L31, fail, 'AssignmentOpSymbol "%="');
4883
- var AssignmentOpSymbol$4 = $EXPECT($L32, fail, 'AssignmentOpSymbol "+="');
4884
- var AssignmentOpSymbol$5 = $EXPECT($L33, fail, 'AssignmentOpSymbol "-="');
4885
- var AssignmentOpSymbol$6 = $EXPECT($L34, fail, 'AssignmentOpSymbol "<<="');
4886
- var AssignmentOpSymbol$7 = $EXPECT($L35, fail, 'AssignmentOpSymbol ">>>="');
4887
- var AssignmentOpSymbol$8 = $EXPECT($L36, fail, 'AssignmentOpSymbol ">>="');
4888
- var AssignmentOpSymbol$9 = $EXPECT($L37, fail, 'AssignmentOpSymbol "&&="');
4889
- var AssignmentOpSymbol$10 = $EXPECT($L38, fail, 'AssignmentOpSymbol "&="');
4890
- var AssignmentOpSymbol$11 = $EXPECT($L39, fail, 'AssignmentOpSymbol "^="');
4891
- var AssignmentOpSymbol$12 = $EXPECT($L40, fail, 'AssignmentOpSymbol "||="');
4892
- var AssignmentOpSymbol$13 = $EXPECT($L41, fail, 'AssignmentOpSymbol "|="');
4893
- var AssignmentOpSymbol$14 = $EXPECT($L42, fail, 'AssignmentOpSymbol "??="');
4894
- var AssignmentOpSymbol$15 = $T($EXPECT($L43, fail, 'AssignmentOpSymbol "?="'), function(value) {
4969
+ var AssignmentOpSymbol$0 = $EXPECT($L29, fail, 'AssignmentOpSymbol "**="');
4970
+ var AssignmentOpSymbol$1 = $EXPECT($L30, fail, 'AssignmentOpSymbol "*="');
4971
+ var AssignmentOpSymbol$2 = $EXPECT($L31, fail, 'AssignmentOpSymbol "/="');
4972
+ var AssignmentOpSymbol$3 = $EXPECT($L32, fail, 'AssignmentOpSymbol "%="');
4973
+ var AssignmentOpSymbol$4 = $EXPECT($L33, fail, 'AssignmentOpSymbol "+="');
4974
+ var AssignmentOpSymbol$5 = $EXPECT($L34, fail, 'AssignmentOpSymbol "-="');
4975
+ var AssignmentOpSymbol$6 = $EXPECT($L35, fail, 'AssignmentOpSymbol "<<="');
4976
+ var AssignmentOpSymbol$7 = $EXPECT($L36, fail, 'AssignmentOpSymbol ">>>="');
4977
+ var AssignmentOpSymbol$8 = $EXPECT($L37, fail, 'AssignmentOpSymbol ">>="');
4978
+ var AssignmentOpSymbol$9 = $EXPECT($L38, fail, 'AssignmentOpSymbol "&&="');
4979
+ var AssignmentOpSymbol$10 = $EXPECT($L39, fail, 'AssignmentOpSymbol "&="');
4980
+ var AssignmentOpSymbol$11 = $EXPECT($L40, fail, 'AssignmentOpSymbol "^="');
4981
+ var AssignmentOpSymbol$12 = $EXPECT($L41, fail, 'AssignmentOpSymbol "||="');
4982
+ var AssignmentOpSymbol$13 = $EXPECT($L42, fail, 'AssignmentOpSymbol "|="');
4983
+ var AssignmentOpSymbol$14 = $EXPECT($L43, fail, 'AssignmentOpSymbol "??="');
4984
+ var AssignmentOpSymbol$15 = $T($EXPECT($L44, fail, 'AssignmentOpSymbol "?="'), function(value) {
4895
4985
  return "??=";
4896
4986
  });
4897
- var AssignmentOpSymbol$16 = $EXPECT($L44, fail, 'AssignmentOpSymbol "="');
4987
+ var AssignmentOpSymbol$16 = $EXPECT($L24, fail, 'AssignmentOpSymbol "="');
4898
4988
  var AssignmentOpSymbol$17 = $T($S(CoffeeWordAssignmentOp), function(value) {
4899
4989
  return value[0];
4900
4990
  });
@@ -4972,66 +5062,82 @@ ${input.slice(result.pos)}
4972
5062
  var BinaryOpSymbol$6 = $EXPECT($L53, fail, 'BinaryOpSymbol "<="');
4973
5063
  var BinaryOpSymbol$7 = $EXPECT($L54, fail, 'BinaryOpSymbol ">="');
4974
5064
  var BinaryOpSymbol$8 = $EXPECT($L55, fail, 'BinaryOpSymbol "<<"');
4975
- var BinaryOpSymbol$9 = $EXPECT($L4, fail, 'BinaryOpSymbol "<"');
5065
+ var BinaryOpSymbol$9 = $EXPECT($L5, fail, 'BinaryOpSymbol "<"');
4976
5066
  var BinaryOpSymbol$10 = $EXPECT($L56, fail, 'BinaryOpSymbol ">>>"');
4977
5067
  var BinaryOpSymbol$11 = $EXPECT($L57, fail, 'BinaryOpSymbol ">>"');
4978
- var BinaryOpSymbol$12 = $EXPECT($L58, fail, 'BinaryOpSymbol ">"');
4979
- var BinaryOpSymbol$13 = $EXPECT($L59, fail, 'BinaryOpSymbol "!=="');
4980
- var BinaryOpSymbol$14 = $TV($EXPECT($L60, fail, 'BinaryOpSymbol "!="'), function($skip, $loc, $0, $1) {
5068
+ var BinaryOpSymbol$12 = $EXPECT($L25, fail, 'BinaryOpSymbol ">"');
5069
+ var BinaryOpSymbol$13 = $EXPECT($L58, fail, 'BinaryOpSymbol "!=="');
5070
+ var BinaryOpSymbol$14 = $TV($EXPECT($L59, fail, 'BinaryOpSymbol "!="'), function($skip, $loc, $0, $1) {
4981
5071
  if (module.config.coffeeEq)
4982
5072
  return "!==";
4983
5073
  return $1;
4984
5074
  });
4985
- var BinaryOpSymbol$15 = $TS($S($EXPECT($L61, fail, 'BinaryOpSymbol "isnt"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
5075
+ var BinaryOpSymbol$15 = $TS($S($EXPECT($L60, fail, 'BinaryOpSymbol "isnt"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
4986
5076
  if (module.config.coffeeIsnt)
4987
5077
  return "!==";
4988
5078
  return $skip;
4989
5079
  });
4990
- var BinaryOpSymbol$16 = $T($S($EXPECT($L62, fail, 'BinaryOpSymbol "is"'), NonIdContinue), function(value) {
5080
+ var BinaryOpSymbol$16 = $T($S($EXPECT($L61, fail, 'BinaryOpSymbol "is"'), NonIdContinue), function(value) {
4991
5081
  return "===";
4992
5082
  });
4993
- var BinaryOpSymbol$17 = $EXPECT($L63, fail, 'BinaryOpSymbol "==="');
4994
- var BinaryOpSymbol$18 = $TV($EXPECT($L64, fail, 'BinaryOpSymbol "=="'), function($skip, $loc, $0, $1) {
5083
+ var BinaryOpSymbol$17 = $EXPECT($L62, fail, 'BinaryOpSymbol "==="');
5084
+ var BinaryOpSymbol$18 = $TV($EXPECT($L63, fail, 'BinaryOpSymbol "=="'), function($skip, $loc, $0, $1) {
4995
5085
  if (module.config.coffeeEq)
4996
5086
  return "===";
4997
5087
  return $1;
4998
5088
  });
4999
- var BinaryOpSymbol$19 = $T($S($EXPECT($L65, fail, 'BinaryOpSymbol "and"'), NonIdContinue), function(value) {
5089
+ var BinaryOpSymbol$19 = $T($S($EXPECT($L64, fail, 'BinaryOpSymbol "and"'), NonIdContinue), function(value) {
5000
5090
  return "&&";
5001
5091
  });
5002
- var BinaryOpSymbol$20 = $EXPECT($L66, fail, 'BinaryOpSymbol "&&"');
5003
- var BinaryOpSymbol$21 = $T($S(CoffeeOfEnabled, $EXPECT($L67, fail, 'BinaryOpSymbol "of"'), NonIdContinue), function(value) {
5092
+ var BinaryOpSymbol$20 = $EXPECT($L65, fail, 'BinaryOpSymbol "&&"');
5093
+ var BinaryOpSymbol$21 = $T($S(CoffeeOfEnabled, $EXPECT($L66, fail, 'BinaryOpSymbol "of"'), NonIdContinue), function(value) {
5004
5094
  return "in";
5005
5095
  });
5006
- var BinaryOpSymbol$22 = $T($S($EXPECT($L68, fail, 'BinaryOpSymbol "or"'), NonIdContinue), function(value) {
5096
+ var BinaryOpSymbol$22 = $T($S($EXPECT($L67, fail, 'BinaryOpSymbol "or"'), NonIdContinue), function(value) {
5007
5097
  return "||";
5008
5098
  });
5009
- var BinaryOpSymbol$23 = $EXPECT($L69, fail, 'BinaryOpSymbol "||"');
5010
- var BinaryOpSymbol$24 = $EXPECT($L70, fail, 'BinaryOpSymbol "??"');
5011
- var BinaryOpSymbol$25 = $T($S(CoffeeBinaryExistentialEnabled, $EXPECT($L71, fail, 'BinaryOpSymbol "?"')), function(value) {
5099
+ var BinaryOpSymbol$23 = $EXPECT($L68, fail, 'BinaryOpSymbol "||"');
5100
+ var BinaryOpSymbol$24 = $EXPECT($L69, fail, 'BinaryOpSymbol "??"');
5101
+ var BinaryOpSymbol$25 = $T($S(CoffeeBinaryExistentialEnabled, $EXPECT($L70, fail, 'BinaryOpSymbol "?"')), function(value) {
5012
5102
  return "??";
5013
5103
  });
5014
- var BinaryOpSymbol$26 = $TS($S($EXPECT($L72, fail, 'BinaryOpSymbol "instanceof"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
5104
+ var BinaryOpSymbol$26 = $TS($S($EXPECT($L71, fail, 'BinaryOpSymbol "instanceof"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
5015
5105
  return $1;
5016
5106
  });
5017
- var BinaryOpSymbol$27 = $TS($S(CoffeeOfEnabled, $EXPECT($L73, fail, 'BinaryOpSymbol "in"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3) {
5107
+ var BinaryOpSymbol$27 = $TS($S(CoffeeNotEnabled, $EXPECT($L72, fail, 'BinaryOpSymbol "not"'), NonIdContinue, __, $EXPECT($L71, fail, 'BinaryOpSymbol "instanceof"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
5108
+ return {
5109
+ $loc,
5110
+ token: "instanceof",
5111
+ special: true
5112
+ };
5113
+ });
5114
+ var BinaryOpSymbol$28 = $TS($S(CoffeeNotEnabled, $EXPECT($L72, fail, 'BinaryOpSymbol "not"'), NonIdContinue, __, $EXPECT($L66, fail, 'BinaryOpSymbol "of"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
5115
+ return {
5116
+ $loc,
5117
+ token: "in",
5118
+ special: true
5119
+ };
5120
+ });
5121
+ var BinaryOpSymbol$29 = $TS($S(CoffeeOfEnabled, $EXPECT($L73, fail, 'BinaryOpSymbol "in"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3) {
5018
5122
  return {
5019
5123
  ref: module.getIndexOfRef(),
5020
- suffix: " >= 0"
5124
+ suffix: " >= 0",
5125
+ special: true
5021
5126
  };
5022
5127
  });
5023
- var BinaryOpSymbol$28 = $TS($S(CoffeeOfEnabled, $EXPECT($L74, fail, 'BinaryOpSymbol "not"'), NonIdContinue, __, $EXPECT($L73, fail, 'BinaryOpSymbol "in"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
5128
+ var BinaryOpSymbol$30 = $TS($S(CoffeeOfEnabled, $EXPECT($L72, fail, 'BinaryOpSymbol "not"'), NonIdContinue, __, $EXPECT($L73, fail, 'BinaryOpSymbol "in"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
5024
5129
  return {
5025
5130
  ref: module.getIndexOfRef(),
5026
- suffix: " < 0"
5131
+ suffix: " < 0",
5132
+ special: true
5027
5133
  };
5028
5134
  });
5029
- var BinaryOpSymbol$29 = $TS($S($EXPECT($L73, fail, 'BinaryOpSymbol "in"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
5135
+ var BinaryOpSymbol$31 = $TS($S($EXPECT($L73, fail, 'BinaryOpSymbol "in"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
5030
5136
  return $1;
5031
5137
  });
5032
- var BinaryOpSymbol$30 = $EXPECT($L75, fail, 'BinaryOpSymbol "&"');
5033
- var BinaryOpSymbol$31 = $EXPECT($L76, fail, 'BinaryOpSymbol "^"');
5034
- var BinaryOpSymbol$32 = $EXPECT($L77, fail, 'BinaryOpSymbol "|"');
5138
+ var BinaryOpSymbol$32 = $EXPECT($L74, fail, 'BinaryOpSymbol "&"');
5139
+ var BinaryOpSymbol$33 = $EXPECT($L75, fail, 'BinaryOpSymbol "^"');
5140
+ var BinaryOpSymbol$34 = $EXPECT($L76, fail, 'BinaryOpSymbol "|"');
5035
5141
  function BinaryOpSymbol(state) {
5036
5142
  if (state.events) {
5037
5143
  const result = state.events.enter?.("BinaryOpSymbol", state);
@@ -5039,12 +5145,12 @@ ${input.slice(result.pos)}
5039
5145
  return result.cache;
5040
5146
  }
5041
5147
  if (state.tokenize) {
5042
- const result = $TOKEN("BinaryOpSymbol", state, BinaryOpSymbol$0(state) || BinaryOpSymbol$1(state) || BinaryOpSymbol$2(state) || BinaryOpSymbol$3(state) || BinaryOpSymbol$4(state) || BinaryOpSymbol$5(state) || BinaryOpSymbol$6(state) || BinaryOpSymbol$7(state) || BinaryOpSymbol$8(state) || BinaryOpSymbol$9(state) || BinaryOpSymbol$10(state) || BinaryOpSymbol$11(state) || BinaryOpSymbol$12(state) || BinaryOpSymbol$13(state) || BinaryOpSymbol$14(state) || BinaryOpSymbol$15(state) || BinaryOpSymbol$16(state) || BinaryOpSymbol$17(state) || BinaryOpSymbol$18(state) || BinaryOpSymbol$19(state) || BinaryOpSymbol$20(state) || BinaryOpSymbol$21(state) || BinaryOpSymbol$22(state) || BinaryOpSymbol$23(state) || BinaryOpSymbol$24(state) || BinaryOpSymbol$25(state) || BinaryOpSymbol$26(state) || BinaryOpSymbol$27(state) || BinaryOpSymbol$28(state) || BinaryOpSymbol$29(state) || BinaryOpSymbol$30(state) || BinaryOpSymbol$31(state) || BinaryOpSymbol$32(state));
5148
+ const result = $TOKEN("BinaryOpSymbol", state, BinaryOpSymbol$0(state) || BinaryOpSymbol$1(state) || BinaryOpSymbol$2(state) || BinaryOpSymbol$3(state) || BinaryOpSymbol$4(state) || BinaryOpSymbol$5(state) || BinaryOpSymbol$6(state) || BinaryOpSymbol$7(state) || BinaryOpSymbol$8(state) || BinaryOpSymbol$9(state) || BinaryOpSymbol$10(state) || BinaryOpSymbol$11(state) || BinaryOpSymbol$12(state) || BinaryOpSymbol$13(state) || BinaryOpSymbol$14(state) || BinaryOpSymbol$15(state) || BinaryOpSymbol$16(state) || BinaryOpSymbol$17(state) || BinaryOpSymbol$18(state) || BinaryOpSymbol$19(state) || BinaryOpSymbol$20(state) || BinaryOpSymbol$21(state) || BinaryOpSymbol$22(state) || BinaryOpSymbol$23(state) || BinaryOpSymbol$24(state) || BinaryOpSymbol$25(state) || BinaryOpSymbol$26(state) || BinaryOpSymbol$27(state) || BinaryOpSymbol$28(state) || BinaryOpSymbol$29(state) || BinaryOpSymbol$30(state) || BinaryOpSymbol$31(state) || BinaryOpSymbol$32(state) || BinaryOpSymbol$33(state) || BinaryOpSymbol$34(state));
5043
5149
  if (state.events)
5044
5150
  state.events.exit?.("BinaryOpSymbol", state, result);
5045
5151
  return result;
5046
5152
  } else {
5047
- const result = BinaryOpSymbol$0(state) || BinaryOpSymbol$1(state) || BinaryOpSymbol$2(state) || BinaryOpSymbol$3(state) || BinaryOpSymbol$4(state) || BinaryOpSymbol$5(state) || BinaryOpSymbol$6(state) || BinaryOpSymbol$7(state) || BinaryOpSymbol$8(state) || BinaryOpSymbol$9(state) || BinaryOpSymbol$10(state) || BinaryOpSymbol$11(state) || BinaryOpSymbol$12(state) || BinaryOpSymbol$13(state) || BinaryOpSymbol$14(state) || BinaryOpSymbol$15(state) || BinaryOpSymbol$16(state) || BinaryOpSymbol$17(state) || BinaryOpSymbol$18(state) || BinaryOpSymbol$19(state) || BinaryOpSymbol$20(state) || BinaryOpSymbol$21(state) || BinaryOpSymbol$22(state) || BinaryOpSymbol$23(state) || BinaryOpSymbol$24(state) || BinaryOpSymbol$25(state) || BinaryOpSymbol$26(state) || BinaryOpSymbol$27(state) || BinaryOpSymbol$28(state) || BinaryOpSymbol$29(state) || BinaryOpSymbol$30(state) || BinaryOpSymbol$31(state) || BinaryOpSymbol$32(state);
5153
+ const result = BinaryOpSymbol$0(state) || BinaryOpSymbol$1(state) || BinaryOpSymbol$2(state) || BinaryOpSymbol$3(state) || BinaryOpSymbol$4(state) || BinaryOpSymbol$5(state) || BinaryOpSymbol$6(state) || BinaryOpSymbol$7(state) || BinaryOpSymbol$8(state) || BinaryOpSymbol$9(state) || BinaryOpSymbol$10(state) || BinaryOpSymbol$11(state) || BinaryOpSymbol$12(state) || BinaryOpSymbol$13(state) || BinaryOpSymbol$14(state) || BinaryOpSymbol$15(state) || BinaryOpSymbol$16(state) || BinaryOpSymbol$17(state) || BinaryOpSymbol$18(state) || BinaryOpSymbol$19(state) || BinaryOpSymbol$20(state) || BinaryOpSymbol$21(state) || BinaryOpSymbol$22(state) || BinaryOpSymbol$23(state) || BinaryOpSymbol$24(state) || BinaryOpSymbol$25(state) || BinaryOpSymbol$26(state) || BinaryOpSymbol$27(state) || BinaryOpSymbol$28(state) || BinaryOpSymbol$29(state) || BinaryOpSymbol$30(state) || BinaryOpSymbol$31(state) || BinaryOpSymbol$32(state) || BinaryOpSymbol$33(state) || BinaryOpSymbol$34(state);
5048
5154
  if (state.events)
5049
5155
  state.events.exit?.("BinaryOpSymbol", state, result);
5050
5156
  return result;
@@ -5170,7 +5276,7 @@ ${input.slice(result.pos)}
5170
5276
  return result;
5171
5277
  }
5172
5278
  }
5173
- var EmptyStatement$0 = $T($S($Q(TrailingComment), $Y($EXPECT($L78, fail, 'EmptyStatement ";"'))), function(value) {
5279
+ var EmptyStatement$0 = $T($S($Q(TrailingComment), $Y($EXPECT($L77, fail, 'EmptyStatement ";"'))), function(value) {
5174
5280
  return { "type": "EmptyStatement", "children": value[0] };
5175
5281
  });
5176
5282
  function EmptyStatement(state) {
@@ -5191,7 +5297,7 @@ ${input.slice(result.pos)}
5191
5297
  return result;
5192
5298
  }
5193
5299
  }
5194
- var BlockStatement$0 = $T($S(ExplicitBlock, $N($S(__, $EXPECT($L44, fail, 'BlockStatement "="')))), function(value) {
5300
+ var BlockStatement$0 = $T($S(ExplicitBlock, $N($S(__, $EXPECT($L24, fail, 'BlockStatement "="')))), function(value) {
5195
5301
  return value[0];
5196
5302
  });
5197
5303
  function BlockStatement(state) {
@@ -5489,7 +5595,16 @@ ${input.slice(result.pos)}
5489
5595
  return result;
5490
5596
  }
5491
5597
  }
5492
- var NestedBlockExpression$0 = $S(Nested, ExtendedExpression, ExpressionDelimiter);
5598
+ var NestedBlockExpression$0 = $TS($S(Nested, ExtendedExpression, $E($S($Q(TrailingComment), PostfixStatement)), ExpressionDelimiter), function($skip, $loc, $0, $1, $2, $3, $4) {
5599
+ var ws = $1;
5600
+ var exp = $2;
5601
+ var post = $3;
5602
+ var d = $4;
5603
+ if (post) {
5604
+ return [ws, module.attachPostfixStatementAsExpression(exp, post), d];
5605
+ }
5606
+ return [ws, exp, d];
5607
+ });
5493
5608
  function NestedBlockExpression(state) {
5494
5609
  if (state.events) {
5495
5610
  const result = state.events.enter?.("NestedBlockExpression", state);
@@ -5830,11 +5945,13 @@ ${input.slice(result.pos)}
5830
5945
  } else if (kind.token === "in") {
5831
5946
  const counterRef = {
5832
5947
  type: "Ref",
5833
- base: "i"
5948
+ base: "i",
5949
+ id: "i"
5834
5950
  };
5835
5951
  const lenRef = {
5836
5952
  type: "Ref",
5837
- base: "len"
5953
+ base: "len",
5954
+ id: "len"
5838
5955
  };
5839
5956
  let expRef;
5840
5957
  switch (exp.type) {
@@ -5852,7 +5969,8 @@ ${input.slice(result.pos)}
5852
5969
  } else {
5853
5970
  stepRef = {
5854
5971
  type: "Ref",
5855
- base: "step"
5972
+ base: "step",
5973
+ id: "step"
5856
5974
  };
5857
5975
  }
5858
5976
  }
@@ -5864,7 +5982,8 @@ ${input.slice(result.pos)}
5864
5982
  } else {
5865
5983
  startRef = {
5866
5984
  type: "Ref",
5867
- base: "ref"
5985
+ base: "ref",
5986
+ id: "ref"
5868
5987
  };
5869
5988
  }
5870
5989
  if (end.type === "Literal") {
@@ -5874,7 +5993,8 @@ ${input.slice(result.pos)}
5874
5993
  } else {
5875
5994
  endRef = {
5876
5995
  type: "Ref",
5877
- base: "ref"
5996
+ base: "ref",
5997
+ id: "ref"
5878
5998
  };
5879
5999
  }
5880
6000
  const startRefDec = startRef !== start ? [startRef, " = ", start, ", "] : [];
@@ -5892,45 +6012,65 @@ ${input.slice(result.pos)}
5892
6012
  names: varRef2.names
5893
6013
  }]);
5894
6014
  const counterPart = inclusive ? [counterRef, " <= ", endRef, " : ", counterRef, " >= ", endRef] : [counterRef, " < ", endRef, " : ", counterRef, " > ", endRef];
5895
- const condition = stepRef ? [stepRef, " !== 0 && (", stepRef, " > 0 ? ", ...counterPart, ")"] : ["asc ? ", ...counterPart];
5896
- const increment = stepRef ? [varRef2, " = ", counterRef, " += ", stepRef] : [varRef2, " = asc ? ++", counterRef, " : --", counterRef];
6015
+ const condition2 = stepRef ? [stepRef, " !== 0 && (", stepRef, " > 0 ? ", ...counterPart, ")"] : ["asc ? ", ...counterPart];
6016
+ const increment2 = stepRef ? [varRef2, " = ", counterRef, " += ", stepRef] : [varRef2, " = asc ? ++", counterRef, " : --", counterRef];
5897
6017
  return {
5898
6018
  declaration,
5899
- children: [$1, open, declaration, "; ", ...condition, "; ", ...increment, close],
6019
+ children: [$1, open, declaration, "; ", ...condition2, "; ", ...increment2, close],
5900
6020
  blockPrefix
5901
6021
  };
5902
6022
  }
5903
6023
  default:
5904
6024
  expRef = {
5905
6025
  type: "Ref",
5906
- base: "ref"
6026
+ base: "ref",
6027
+ id: "ref"
5907
6028
  };
5908
6029
  }
5909
- if (step) {
5910
- throw new Error("by clause not yet implement in non-range for in loops");
5911
- }
5912
6030
  const varRef = declaration;
5913
- const expRefDec = expRef !== exp ? [expRef, " = ", module.insertTrimmingSpace(exp, ""), ", "] : [];
5914
- declaration = {
5915
- type: "Declaration",
5916
- children: ["let ", ...expRefDec, counterRef, " = 0, ", lenRef, " = ", expRef, ".length"],
5917
- names: []
5918
- };
5919
- let indexAssignment;
5920
- let assignmentNames = [...varRef.names];
6031
+ let increment = "++", indexAssignment, assignmentNames = [...varRef.names];
5921
6032
  if (index) {
5922
6033
  index = module.insertTrimmingSpace(index, "");
5923
6034
  indexAssignment = [index, "="];
5924
6035
  assignmentNames.push(...index.names);
5925
6036
  }
6037
+ const expRefDec = expRef !== exp ? [expRef, " = ", module.insertTrimmingSpace(exp, ""), ", "] : [];
5926
6038
  blockPrefix.push([indent, {
5927
6039
  type: "AssignmentExpression",
5928
6040
  children: [varRef, " = ", expRef, "[", indexAssignment, counterRef, "]\n"],
5929
6041
  names: assignmentNames
5930
6042
  }]);
6043
+ declaration = {
6044
+ type: "Declaration",
6045
+ children: ["let ", ...expRefDec, counterRef, " = 0, ", lenRef, " = ", expRef, ".length"],
6046
+ names: []
6047
+ };
6048
+ let condition = [counterRef, " < ", lenRef, "; "];
6049
+ if (step) {
6050
+ let [stepWs, , stepExp] = step;
6051
+ stepWs = module.insertTrimmingSpace(stepWs, "");
6052
+ if (stepExp.type === "Literal") {
6053
+ increment = [" +=", ...stepWs, stepExp];
6054
+ if (stepExp.raw[0] === "-") {
6055
+ declaration = {
6056
+ type: "Declaration",
6057
+ children: ["let ", ...expRefDec, counterRef, " = ", expRef, ".length - 1"],
6058
+ names: []
6059
+ };
6060
+ condition = [counterRef, " >= 0; "];
6061
+ }
6062
+ } else {
6063
+ throw new Error("TODO: Support non-literal step in CoffeeScript for loops");
6064
+ }
6065
+ return {
6066
+ declaration,
6067
+ children: [$1, open, declaration, "; ", ...condition, counterRef, increment, close],
6068
+ blockPrefix
6069
+ };
6070
+ }
5931
6071
  return {
5932
6072
  declaration,
5933
- children: [$1, open, declaration, "; ", counterRef, " < ", lenRef, "; ", counterRef, "++", close],
6073
+ children: [$1, open, declaration, "; ", ...condition, counterRef, increment, close],
5934
6074
  blockPrefix
5935
6075
  };
5936
6076
  }
@@ -5984,7 +6124,7 @@ ${input.slice(result.pos)}
5984
6124
  return result;
5985
6125
  }
5986
6126
  }
5987
- var CoffeeForDeclaration$0 = $TS($S($E($S(__, $EXPECT($L79, fail, 'CoffeeForDeclaration "own"'))), ForBinding), function($skip, $loc, $0, $1, $2) {
6127
+ var CoffeeForDeclaration$0 = $TS($S($E($S(__, $EXPECT($L78, fail, 'CoffeeForDeclaration "own"'))), ForBinding), function($skip, $loc, $0, $1, $2) {
5988
6128
  var own = $1;
5989
6129
  var binding = $2;
5990
6130
  if (own) {
@@ -6025,14 +6165,14 @@ ${input.slice(result.pos)}
6025
6165
  children: $0
6026
6166
  };
6027
6167
  });
6028
- var ForStatementParameters$2 = $TS($S($E($S(Await, __)), OpenParen, __, ForInOfDeclaration, __, $C(In, Of), ExtendedExpression, __, CloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
6168
+ var ForStatementParameters$2 = $TS($S($E($S(Await, __)), OpenParen, __, ForInOfDeclaration, __, $C(In, Of), ExpressionWithIndentedApplicationSuppressed, __, CloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
6029
6169
  var declaration = $4;
6030
6170
  return {
6031
6171
  declaration,
6032
6172
  children: $0
6033
6173
  };
6034
6174
  });
6035
- var ForStatementParameters$3 = $TS($S($E($S(Await, __)), InsertOpenParen, ForInOfDeclaration, __, $C(In, Of), ExtendedExpression, InsertCloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7) {
6175
+ var ForStatementParameters$3 = $TS($S($E($S(Await, __)), InsertOpenParen, ForInOfDeclaration, __, $C(In, Of), ExpressionWithIndentedApplicationSuppressed, InsertCloseParen), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7) {
6036
6176
  var declaration = $3;
6037
6177
  return {
6038
6178
  declaration,
@@ -6377,7 +6517,7 @@ ${input.slice(result.pos)}
6377
6517
  return result;
6378
6518
  }
6379
6519
  }
6380
- var CaseExpressionList$0 = $TS($S($S($Q(_), ExtendedExpression, ImpliedColon), $Q($S(__, Comma, ExtendedExpression, ImpliedColon))), function($skip, $loc, $0, $1, $2) {
6520
+ var CaseExpressionList$0 = $TS($S($S($Q(_), ExpressionWithIndentedApplicationSuppressed, ImpliedColon), $Q($S(__, Comma, ExpressionWithIndentedApplicationSuppressed, ImpliedColon))), function($skip, $loc, $0, $1, $2) {
6381
6521
  const result = $2.map(([ws, _comma, exp, col]) => {
6382
6522
  exp = module.insertTrimmingSpace(exp, "");
6383
6523
  if (ws.length)
@@ -6405,7 +6545,7 @@ ${input.slice(result.pos)}
6405
6545
  return result;
6406
6546
  }
6407
6547
  }
6408
- var NoExpressions$0 = $T($EXPECT($L14, fail, 'NoExpressions ""'), function(value) {
6548
+ var NoExpressions$0 = $T($EXPECT($L0, fail, 'NoExpressions ""'), function(value) {
6409
6549
  return [];
6410
6550
  });
6411
6551
  function NoExpressions(state) {
@@ -6427,7 +6567,7 @@ ${input.slice(result.pos)}
6427
6567
  }
6428
6568
  }
6429
6569
  var ImpliedColon$0 = $S(__, Colon);
6430
- var ImpliedColon$1 = $TV($EXPECT($L14, fail, 'ImpliedColon ""'), function($skip, $loc, $0, $1) {
6570
+ var ImpliedColon$1 = $TV($EXPECT($L0, fail, 'ImpliedColon ""'), function($skip, $loc, $0, $1) {
6431
6571
  return { $loc, token: ":" };
6432
6572
  });
6433
6573
  function ImpliedColon(state) {
@@ -6521,7 +6661,7 @@ ${input.slice(result.pos)}
6521
6661
  return result;
6522
6662
  }
6523
6663
  }
6524
- var Finally$0 = $S(__, $EXPECT($L80, fail, 'Finally "finally"'), BracedBlock);
6664
+ var Finally$0 = $S(__, $EXPECT($L79, fail, 'Finally "finally"'), BracedBlock);
6525
6665
  function Finally(state) {
6526
6666
  if (state.events) {
6527
6667
  const result = state.events.enter?.("Finally", state);
@@ -6560,10 +6700,10 @@ ${input.slice(result.pos)}
6560
6700
  return result;
6561
6701
  }
6562
6702
  }
6563
- var Condition$0 = $T($S(ParenthesizedExpression, $N($S($Q(TrailingComment), $C(BinaryOp, AssignmentOp)))), function(value) {
6703
+ var Condition$0 = $T($S(ParenthesizedExpression, $N($S($Q(TrailingComment), $C(BinaryOp, AssignmentOp, Dot, QuestionMark)))), function(value) {
6564
6704
  return value[0];
6565
6705
  });
6566
- var Condition$1 = $TS($S(InsertOpenParen, ExtendedExpression, InsertCloseParen), function($skip, $loc, $0, $1, $2, $3) {
6706
+ var Condition$1 = $TS($S(InsertOpenParen, ExpressionWithIndentedApplicationSuppressed, InsertCloseParen), function($skip, $loc, $0, $1, $2, $3) {
6567
6707
  var open = $1;
6568
6708
  var exp = $2;
6569
6709
  var close = $3;
@@ -6592,6 +6732,52 @@ ${input.slice(result.pos)}
6592
6732
  return result;
6593
6733
  }
6594
6734
  }
6735
+ var ExpressionWithIndentedApplicationSuppressed$0 = $TS($S(SuppressIndentedApplication, $E(ExtendedExpression)), function($skip, $loc, $0, $1, $2) {
6736
+ var exp = $2;
6737
+ module.suppressIndentedApplication = false;
6738
+ if (exp)
6739
+ return exp;
6740
+ return $skip;
6741
+ });
6742
+ function ExpressionWithIndentedApplicationSuppressed(state) {
6743
+ if (state.events) {
6744
+ const result = state.events.enter?.("ExpressionWithIndentedApplicationSuppressed", state);
6745
+ if (result)
6746
+ return result.cache;
6747
+ }
6748
+ if (state.tokenize) {
6749
+ const result = $TOKEN("ExpressionWithIndentedApplicationSuppressed", state, ExpressionWithIndentedApplicationSuppressed$0(state));
6750
+ if (state.events)
6751
+ state.events.exit?.("ExpressionWithIndentedApplicationSuppressed", state, result);
6752
+ return result;
6753
+ } else {
6754
+ const result = ExpressionWithIndentedApplicationSuppressed$0(state);
6755
+ if (state.events)
6756
+ state.events.exit?.("ExpressionWithIndentedApplicationSuppressed", state, result);
6757
+ return result;
6758
+ }
6759
+ }
6760
+ var SuppressIndentedApplication$0 = $TV($EXPECT($L0, fail, 'SuppressIndentedApplication ""'), function($skip, $loc, $0, $1) {
6761
+ module.suppressIndentedApplication = true;
6762
+ });
6763
+ function SuppressIndentedApplication(state) {
6764
+ if (state.events) {
6765
+ const result = state.events.enter?.("SuppressIndentedApplication", state);
6766
+ if (result)
6767
+ return result.cache;
6768
+ }
6769
+ if (state.tokenize) {
6770
+ const result = $TOKEN("SuppressIndentedApplication", state, SuppressIndentedApplication$0(state));
6771
+ if (state.events)
6772
+ state.events.exit?.("SuppressIndentedApplication", state, result);
6773
+ return result;
6774
+ } else {
6775
+ const result = SuppressIndentedApplication$0(state);
6776
+ if (state.events)
6777
+ state.events.exit?.("SuppressIndentedApplication", state, result);
6778
+ return result;
6779
+ }
6780
+ }
6595
6781
  var ExpressionStatement$0 = Expression;
6596
6782
  function ExpressionStatement(state) {
6597
6783
  if (state.events) {
@@ -6611,13 +6797,13 @@ ${input.slice(result.pos)}
6611
6797
  return result;
6612
6798
  }
6613
6799
  }
6614
- var KeywordStatement$0 = $T($S($EXPECT($L81, fail, 'KeywordStatement "break"'), NonIdContinue), function(value) {
6800
+ var KeywordStatement$0 = $T($S($EXPECT($L80, fail, 'KeywordStatement "break"'), NonIdContinue), function(value) {
6615
6801
  return { "type": "BreakStatement", "children": value };
6616
6802
  });
6617
- var KeywordStatement$1 = $T($S($EXPECT($L82, fail, 'KeywordStatement "continue"'), NonIdContinue), function(value) {
6803
+ var KeywordStatement$1 = $T($S($EXPECT($L81, fail, 'KeywordStatement "continue"'), NonIdContinue), function(value) {
6618
6804
  return { "type": "ContinueStatement", "children": value };
6619
6805
  });
6620
- var KeywordStatement$2 = $T($S($EXPECT($L83, fail, 'KeywordStatement "debugger"'), NonIdContinue), function(value) {
6806
+ var KeywordStatement$2 = $T($S($EXPECT($L82, fail, 'KeywordStatement "debugger"'), NonIdContinue), function(value) {
6621
6807
  return { "type": "DebuggerStatement", "children": value };
6622
6808
  });
6623
6809
  var KeywordStatement$3 = $T($S(Return, $E(MaybeNestedExpression)), function(value) {
@@ -6644,7 +6830,7 @@ ${input.slice(result.pos)}
6644
6830
  return result;
6645
6831
  }
6646
6832
  }
6647
- var DebuggerExpression$0 = $TS($S($EXPECT($L83, fail, 'DebuggerExpression "debugger"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
6833
+ var DebuggerExpression$0 = $TS($S($EXPECT($L82, fail, 'DebuggerExpression "debugger"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
6648
6834
  return {
6649
6835
  type: "DebuggerExpression",
6650
6836
  children: ["(()=>{", $1, "})()"]
@@ -6692,7 +6878,7 @@ ${input.slice(result.pos)}
6692
6878
  return result;
6693
6879
  }
6694
6880
  }
6695
- var MaybeNestedExpression$0 = $TS($S($N(EOS), AssignmentExpression), function($skip, $loc, $0, $1, $2) {
6881
+ var MaybeNestedExpression$0 = $TS($S($N(EOS), ExtendedExpression), function($skip, $loc, $0, $1, $2) {
6696
6882
  return $2;
6697
6883
  });
6698
6884
  var MaybeNestedExpression$1 = $T($S($Y(EOS), ObjectLiteral), function(value) {
@@ -6716,7 +6902,7 @@ ${input.slice(result.pos)}
6716
6902
  return result;
6717
6903
  }
6718
6904
  }
6719
- var ImportDeclaration$0 = $T($S($EXPECT($L84, fail, 'ImportDeclaration "import type"'), NonIdContinue, __, ImportClause, __, FromClause), function(value) {
6905
+ var ImportDeclaration$0 = $T($S($EXPECT($L83, fail, 'ImportDeclaration "import type"'), NonIdContinue, __, ImportClause, __, FromClause), function(value) {
6720
6906
  return { "ts": true, "children": value };
6721
6907
  });
6722
6908
  var ImportDeclaration$1 = $S(Import, __, ImportClause, __, FromClause);
@@ -6750,7 +6936,7 @@ ${input.slice(result.pos)}
6750
6936
  return result;
6751
6937
  }
6752
6938
  }
6753
- var ImpliedImport$0 = $TV($EXPECT($L14, fail, 'ImpliedImport ""'), function($skip, $loc, $0, $1) {
6939
+ var ImpliedImport$0 = $TV($EXPECT($L0, fail, 'ImpliedImport ""'), function($skip, $loc, $0, $1) {
6754
6940
  return { $loc, token: "import " };
6755
6941
  });
6756
6942
  function ImpliedImport(state) {
@@ -7016,9 +7202,9 @@ ${input.slice(result.pos)}
7016
7202
  return result;
7017
7203
  }
7018
7204
  }
7019
- var ExportDeclaration$0 = $S(Export, __, $EXPECT($L85, fail, 'ExportDeclaration "default"'), NonIdContinue, __, $C(HoistableDeclaration, ClassDeclaration, ExtendedExpression));
7205
+ var ExportDeclaration$0 = $S(Export, __, $EXPECT($L84, fail, 'ExportDeclaration "default"'), NonIdContinue, __, $C(HoistableDeclaration, ClassDeclaration, ExtendedExpression));
7020
7206
  var ExportDeclaration$1 = $S(Export, __, ExportFromClause, __, FromClause);
7021
- var ExportDeclaration$2 = $S(Export, __, $C(NamedExports, VariableStatement, Declaration));
7207
+ var ExportDeclaration$2 = $S(Export, __, $C(Declaration, NamedExports, VariableStatement));
7022
7208
  function ExportDeclaration(state) {
7023
7209
  if (state.events) {
7024
7210
  const result = state.events.enter?.("ExportDeclaration", state);
@@ -7058,6 +7244,11 @@ ${input.slice(result.pos)}
7058
7244
  }
7059
7245
  }
7060
7246
  var NamedExports$0 = $S(OpenBrace, $Q(ExportSpecifier), $E($S(__, Comma)), __, CloseBrace);
7247
+ var NamedExports$1 = $TS($S(InsertInlineOpenBrace, ImplicitExportSpecifier, $Q($S(_, ImplicitExportSpecifier)), InsertCloseBrace), function($skip, $loc, $0, $1, $2, $3, $4) {
7248
+ var open = $1;
7249
+ var close = $4;
7250
+ return [open, $2, ...$3, close];
7251
+ });
7061
7252
  function NamedExports(state) {
7062
7253
  if (state.events) {
7063
7254
  const result = state.events.enter?.("NamedExports", state);
@@ -7065,12 +7256,12 @@ ${input.slice(result.pos)}
7065
7256
  return result.cache;
7066
7257
  }
7067
7258
  if (state.tokenize) {
7068
- const result = $TOKEN("NamedExports", state, NamedExports$0(state));
7259
+ const result = $TOKEN("NamedExports", state, NamedExports$0(state) || NamedExports$1(state));
7069
7260
  if (state.events)
7070
7261
  state.events.exit?.("NamedExports", state, result);
7071
7262
  return result;
7072
7263
  } else {
7073
- const result = NamedExports$0(state);
7264
+ const result = NamedExports$0(state) || NamedExports$1(state);
7074
7265
  if (state.events)
7075
7266
  state.events.exit?.("NamedExports", state, result);
7076
7267
  return result;
@@ -7095,6 +7286,25 @@ ${input.slice(result.pos)}
7095
7286
  return result;
7096
7287
  }
7097
7288
  }
7289
+ var ImplicitExportSpecifier$0 = $S($N($EXPECT($L84, fail, 'ImplicitExportSpecifier "default"')), ModuleExportName, $E($S(__, As, __, ModuleExportName)), ImplicitInlineObjectPropertyDelimiter);
7290
+ function ImplicitExportSpecifier(state) {
7291
+ if (state.events) {
7292
+ const result = state.events.enter?.("ImplicitExportSpecifier", state);
7293
+ if (result)
7294
+ return result.cache;
7295
+ }
7296
+ if (state.tokenize) {
7297
+ const result = $TOKEN("ImplicitExportSpecifier", state, ImplicitExportSpecifier$0(state));
7298
+ if (state.events)
7299
+ state.events.exit?.("ImplicitExportSpecifier", state, result);
7300
+ return result;
7301
+ } else {
7302
+ const result = ImplicitExportSpecifier$0(state);
7303
+ if (state.events)
7304
+ state.events.exit?.("ImplicitExportSpecifier", state, result);
7305
+ return result;
7306
+ }
7307
+ }
7098
7308
  var Declaration$0 = HoistableDeclaration;
7099
7309
  var Declaration$1 = ClassDeclaration;
7100
7310
  var Declaration$2 = LexicalDeclaration;
@@ -7148,6 +7358,8 @@ ${input.slice(result.pos)}
7148
7358
  var LexicalDeclaration$1 = $TS($S(InsertConst, $C(BindingPattern, BindingIdentifier), $E(TypeSuffix), __, ConstAssignment, ExtendedExpression), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6) {
7149
7359
  var c = $1;
7150
7360
  var id = $2;
7361
+ var suffix = $3;
7362
+ var ws = $4;
7151
7363
  var ca = $5;
7152
7364
  var e = $6;
7153
7365
  c = {
@@ -7177,10 +7389,14 @@ ${input.slice(result.pos)}
7177
7389
  names: id.names
7178
7390
  };
7179
7391
  }
7392
+ let [splices, thisAssignments] = module.gatherBindingCode(id);
7393
+ splices = splices.map((s) => [", ", s]);
7394
+ thisAssignments = thisAssignments.map((a) => [";", a]);
7395
+ const children = [c, id, suffix, ...ws, ca, e, ...splices, ...thisAssignments];
7180
7396
  return {
7181
7397
  type: "Declaration",
7182
7398
  names: id.names,
7183
- children: $0
7399
+ children
7184
7400
  };
7185
7401
  });
7186
7402
  function LexicalDeclaration(state) {
@@ -7201,7 +7417,7 @@ ${input.slice(result.pos)}
7201
7417
  return result;
7202
7418
  }
7203
7419
  }
7204
- var ConstAssignment$0 = $TV($EXPECT($L86, fail, 'ConstAssignment ":="'), function($skip, $loc, $0, $1) {
7420
+ var ConstAssignment$0 = $TV($EXPECT($L85, fail, 'ConstAssignment ":="'), function($skip, $loc, $0, $1) {
7205
7421
  return { $loc, token: "=" };
7206
7422
  });
7207
7423
  function ConstAssignment(state) {
@@ -8105,7 +8321,8 @@ ${input.slice(result.pos)}
8105
8321
  var ReservedWord$0 = $S(CoffeeBooleansEnabled, $R$0($EXPECT($R30, fail, "ReservedWord /(?:on|off|yes|no)(?!\\p{ID_Continue})/")));
8106
8322
  var ReservedWord$1 = $S(CoffeeIsntEnabled, $R$0($EXPECT($R31, fail, "ReservedWord /(?:isnt)(?!\\p{ID_Continue})/")));
8107
8323
  var ReservedWord$2 = $S(CoffeeForLoopsEnabled, $R$0($EXPECT($R32, fail, "ReservedWord /(?:by)(?!\\p{ID_Continue})/")));
8108
- var ReservedWord$3 = $R$0($EXPECT($R33, fail, "ReservedWord /(?:and|as|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|return|static|super|switch|this|throw|true|try|typeof|unless|until|var|void|while|with|yield)(?!\\p{ID_Continue})/"));
8324
+ var ReservedWord$3 = $S(CoffeeOfEnabled, $R$0($EXPECT($R33, fail, "ReservedWord /(?:of)(?!\\p{ID_Continue})/")));
8325
+ var ReservedWord$4 = $R$0($EXPECT($R34, fail, "ReservedWord /(?:and|as|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|return|static|super|switch|this|throw|true|try|typeof|unless|until|var|void|while|with|yield)(?!\\p{ID_Continue})/"));
8109
8326
  function ReservedWord(state) {
8110
8327
  if (state.events) {
8111
8328
  const result = state.events.enter?.("ReservedWord", state);
@@ -8113,12 +8330,12 @@ ${input.slice(result.pos)}
8113
8330
  return result.cache;
8114
8331
  }
8115
8332
  if (state.tokenize) {
8116
- const result = $TOKEN("ReservedWord", state, ReservedWord$0(state) || ReservedWord$1(state) || ReservedWord$2(state) || ReservedWord$3(state));
8333
+ const result = $TOKEN("ReservedWord", state, ReservedWord$0(state) || ReservedWord$1(state) || ReservedWord$2(state) || ReservedWord$3(state) || ReservedWord$4(state));
8117
8334
  if (state.events)
8118
8335
  state.events.exit?.("ReservedWord", state, result);
8119
8336
  return result;
8120
8337
  } else {
8121
- const result = ReservedWord$0(state) || ReservedWord$1(state) || ReservedWord$2(state) || ReservedWord$3(state);
8338
+ const result = ReservedWord$0(state) || ReservedWord$1(state) || ReservedWord$2(state) || ReservedWord$3(state) || ReservedWord$4(state);
8122
8339
  if (state.events)
8123
8340
  state.events.exit?.("ReservedWord", state, result);
8124
8341
  return result;
@@ -8164,7 +8381,7 @@ ${input.slice(result.pos)}
8164
8381
  return result;
8165
8382
  }
8166
8383
  }
8167
- var JSSingleLineComment$0 = $TR($EXPECT($R34, fail, "JSSingleLineComment /\\/\\/(?!\\/)[^\\r\\n]*/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
8384
+ var JSSingleLineComment$0 = $TR($EXPECT($R35, fail, "JSSingleLineComment /\\/\\/(?!\\/)[^\\r\\n]*/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
8168
8385
  return { $loc, token: $0 };
8169
8386
  });
8170
8387
  function JSSingleLineComment(state) {
@@ -8205,7 +8422,7 @@ ${input.slice(result.pos)}
8205
8422
  return result;
8206
8423
  }
8207
8424
  }
8208
- var JSMultiLineComment$0 = $TV($TEXT($S($EXPECT($L87, fail, 'JSMultiLineComment "/*"'), $Q($S($N($EXPECT($L88, fail, 'JSMultiLineComment "*/"')), $EXPECT($R35, fail, "JSMultiLineComment /./"))), $EXPECT($L88, fail, 'JSMultiLineComment "*/"'))), function($skip, $loc, $0, $1) {
8425
+ var JSMultiLineComment$0 = $TV($TEXT($S($EXPECT($L86, fail, 'JSMultiLineComment "/*"'), $Q($S($N($EXPECT($L87, fail, 'JSMultiLineComment "*/"')), $EXPECT($R36, fail, "JSMultiLineComment /./"))), $EXPECT($L87, fail, 'JSMultiLineComment "*/"'))), function($skip, $loc, $0, $1) {
8209
8426
  return { $loc, token: $1 };
8210
8427
  });
8211
8428
  function JSMultiLineComment(state) {
@@ -8226,7 +8443,7 @@ ${input.slice(result.pos)}
8226
8443
  return result;
8227
8444
  }
8228
8445
  }
8229
- var CoffeeSingleLineComment$0 = $TR($EXPECT($R36, fail, "CoffeeSingleLineComment /#(?!##)([^\\r\\n]*)/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
8446
+ var CoffeeSingleLineComment$0 = $TR($EXPECT($R37, fail, "CoffeeSingleLineComment /#(?!##(?!#))([^\\r\\n]*)/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
8230
8447
  return { $loc, token: `//${$1}` };
8231
8448
  });
8232
8449
  function CoffeeSingleLineComment(state) {
@@ -8247,7 +8464,7 @@ ${input.slice(result.pos)}
8247
8464
  return result;
8248
8465
  }
8249
8466
  }
8250
- var CoffeeMultiLineComment$0 = $TS($S($EXPECT($L89, fail, 'CoffeeMultiLineComment "###"'), $TEXT($Q($S($N($C($EXPECT($L89, fail, 'CoffeeMultiLineComment "###"'), $EXPECT($L88, fail, 'CoffeeMultiLineComment "*/"'))), $EXPECT($R35, fail, "CoffeeMultiLineComment /./")))), $EXPECT($L89, fail, 'CoffeeMultiLineComment "###"')), function($skip, $loc, $0, $1, $2, $3) {
8467
+ var CoffeeMultiLineComment$0 = $TS($S(CoffeeHereCommentStart, $TEXT($Q($S($N($C(CoffeeHereCommentStart, $EXPECT($L87, fail, 'CoffeeMultiLineComment "*/"'))), $EXPECT($R36, fail, "CoffeeMultiLineComment /./")))), CoffeeHereCommentStart), function($skip, $loc, $0, $1, $2, $3) {
8251
8468
  return { $loc, token: `/*${$2}*/` };
8252
8469
  });
8253
8470
  function CoffeeMultiLineComment(state) {
@@ -8268,7 +8485,26 @@ ${input.slice(result.pos)}
8268
8485
  return result;
8269
8486
  }
8270
8487
  }
8271
- var InlineComment$0 = $TV($TEXT($S($EXPECT($L87, fail, 'InlineComment "/*"'), $TEXT($Q($S($N($EXPECT($L88, fail, 'InlineComment "*/"')), $EXPECT($R37, fail, "InlineComment /[^\\r\\n]/")))), $EXPECT($L88, fail, 'InlineComment "*/"'))), function($skip, $loc, $0, $1) {
8488
+ var CoffeeHereCommentStart$0 = $R$0($EXPECT($R38, fail, "CoffeeHereCommentStart /###(?!#)/"));
8489
+ function CoffeeHereCommentStart(state) {
8490
+ if (state.events) {
8491
+ const result = state.events.enter?.("CoffeeHereCommentStart", state);
8492
+ if (result)
8493
+ return result.cache;
8494
+ }
8495
+ if (state.tokenize) {
8496
+ const result = $TOKEN("CoffeeHereCommentStart", state, CoffeeHereCommentStart$0(state));
8497
+ if (state.events)
8498
+ state.events.exit?.("CoffeeHereCommentStart", state, result);
8499
+ return result;
8500
+ } else {
8501
+ const result = CoffeeHereCommentStart$0(state);
8502
+ if (state.events)
8503
+ state.events.exit?.("CoffeeHereCommentStart", state, result);
8504
+ return result;
8505
+ }
8506
+ }
8507
+ var InlineComment$0 = $TV($TEXT($S($EXPECT($L86, fail, 'InlineComment "/*"'), $TEXT($Q($S($N($EXPECT($L87, fail, 'InlineComment "*/"')), $EXPECT($R39, fail, "InlineComment /[^\\r\\n]/")))), $EXPECT($L87, fail, 'InlineComment "*/"'))), function($skip, $loc, $0, $1) {
8272
8508
  return { $loc, token: $1 };
8273
8509
  });
8274
8510
  function InlineComment(state) {
@@ -8348,10 +8584,10 @@ ${input.slice(result.pos)}
8348
8584
  return result;
8349
8585
  }
8350
8586
  }
8351
- var NonNewlineWhitespace$0 = $TR($EXPECT($R38, fail, "NonNewlineWhitespace /[ \\t]+/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
8587
+ var NonNewlineWhitespace$0 = $TR($EXPECT($R40, fail, "NonNewlineWhitespace /[ \\t]+/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
8352
8588
  return { $loc, token: $0 };
8353
8589
  });
8354
- var NonNewlineWhitespace$1 = $T($S(CoffeeLineContinuationEnabled, $EXPECT($L90, fail, 'NonNewlineWhitespace "\\\\\\\\"'), EOL), function(value) {
8590
+ var NonNewlineWhitespace$1 = $T($S(CoffeeLineContinuationEnabled, $EXPECT($L88, fail, 'NonNewlineWhitespace "\\\\\\\\"'), EOL), function(value) {
8355
8591
  return "";
8356
8592
  });
8357
8593
  function NonNewlineWhitespace(state) {
@@ -8457,7 +8693,7 @@ ${input.slice(result.pos)}
8457
8693
  return result;
8458
8694
  }
8459
8695
  }
8460
- var NonIdContinue$0 = $R$0($EXPECT($R39, fail, "NonIdContinue /(?!\\p{ID_Continue})/"));
8696
+ var NonIdContinue$0 = $R$0($EXPECT($R41, fail, "NonIdContinue /(?!\\p{ID_Continue})/"));
8461
8697
  function NonIdContinue(state) {
8462
8698
  if (state.events) {
8463
8699
  const result = state.events.enter?.("NonIdContinue", state);
@@ -8476,7 +8712,7 @@ ${input.slice(result.pos)}
8476
8712
  return result;
8477
8713
  }
8478
8714
  }
8479
- var Loc$0 = $TV($EXPECT($L14, fail, 'Loc ""'), function($skip, $loc, $0, $1) {
8715
+ var Loc$0 = $TV($EXPECT($L0, fail, 'Loc ""'), function($skip, $loc, $0, $1) {
8480
8716
  return { $loc, token: "" };
8481
8717
  });
8482
8718
  function Loc(state) {
@@ -8497,7 +8733,7 @@ ${input.slice(result.pos)}
8497
8733
  return result;
8498
8734
  }
8499
8735
  }
8500
- var Ampersand$0 = $TV($EXPECT($L75, fail, 'Ampersand "&"'), function($skip, $loc, $0, $1) {
8736
+ var Ampersand$0 = $TV($EXPECT($L74, fail, 'Ampersand "&"'), function($skip, $loc, $0, $1) {
8501
8737
  return { $loc, token: $1 };
8502
8738
  });
8503
8739
  function Ampersand(state) {
@@ -8518,7 +8754,7 @@ ${input.slice(result.pos)}
8518
8754
  return result;
8519
8755
  }
8520
8756
  }
8521
- var As$0 = $TS($S($EXPECT($L91, fail, 'As "as"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8757
+ var As$0 = $TS($S($EXPECT($L89, fail, 'As "as"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8522
8758
  return { $loc, token: $1 };
8523
8759
  });
8524
8760
  function As(state) {
@@ -8539,7 +8775,7 @@ ${input.slice(result.pos)}
8539
8775
  return result;
8540
8776
  }
8541
8777
  }
8542
- var At$0 = $TV($EXPECT($L92, fail, 'At "@"'), function($skip, $loc, $0, $1) {
8778
+ var At$0 = $TV($EXPECT($L90, fail, 'At "@"'), function($skip, $loc, $0, $1) {
8543
8779
  return { $loc, token: $1 };
8544
8780
  });
8545
8781
  function At(state) {
@@ -8560,7 +8796,7 @@ ${input.slice(result.pos)}
8560
8796
  return result;
8561
8797
  }
8562
8798
  }
8563
- var Async$0 = $TV($EXPECT($L93, fail, 'Async "async"'), function($skip, $loc, $0, $1) {
8799
+ var Async$0 = $TV($EXPECT($L91, fail, 'Async "async"'), function($skip, $loc, $0, $1) {
8564
8800
  return { $loc, token: $1 };
8565
8801
  });
8566
8802
  function Async(state) {
@@ -8581,7 +8817,7 @@ ${input.slice(result.pos)}
8581
8817
  return result;
8582
8818
  }
8583
8819
  }
8584
- var Await$0 = $TS($S($EXPECT($L94, fail, 'Await "await"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8820
+ var Await$0 = $TS($S($EXPECT($L92, fail, 'Await "await"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8585
8821
  return { $loc, token: $1 };
8586
8822
  });
8587
8823
  function Await(state) {
@@ -8602,7 +8838,7 @@ ${input.slice(result.pos)}
8602
8838
  return result;
8603
8839
  }
8604
8840
  }
8605
- var Backtick$0 = $TV($EXPECT($L95, fail, 'Backtick "`"'), function($skip, $loc, $0, $1) {
8841
+ var Backtick$0 = $TV($EXPECT($L93, fail, 'Backtick "`"'), function($skip, $loc, $0, $1) {
8606
8842
  return { $loc, token: $1 };
8607
8843
  });
8608
8844
  function Backtick(state) {
@@ -8623,7 +8859,7 @@ ${input.slice(result.pos)}
8623
8859
  return result;
8624
8860
  }
8625
8861
  }
8626
- var By$0 = $TS($S($EXPECT($L96, fail, 'By "by"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8862
+ var By$0 = $TS($S($EXPECT($L94, fail, 'By "by"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8627
8863
  return { $loc, token: $1 };
8628
8864
  });
8629
8865
  function By(state) {
@@ -8644,7 +8880,7 @@ ${input.slice(result.pos)}
8644
8880
  return result;
8645
8881
  }
8646
8882
  }
8647
- var Case$0 = $TS($S($EXPECT($L97, fail, 'Case "case"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8883
+ var Case$0 = $TS($S($EXPECT($L95, fail, 'Case "case"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8648
8884
  return { $loc, token: $1 };
8649
8885
  });
8650
8886
  function Case(state) {
@@ -8665,7 +8901,7 @@ ${input.slice(result.pos)}
8665
8901
  return result;
8666
8902
  }
8667
8903
  }
8668
- var Catch$0 = $TV($EXPECT($L98, fail, 'Catch "catch"'), function($skip, $loc, $0, $1) {
8904
+ var Catch$0 = $TV($EXPECT($L96, fail, 'Catch "catch"'), function($skip, $loc, $0, $1) {
8669
8905
  return { $loc, token: $1 };
8670
8906
  });
8671
8907
  function Catch(state) {
@@ -8686,7 +8922,7 @@ ${input.slice(result.pos)}
8686
8922
  return result;
8687
8923
  }
8688
8924
  }
8689
- var Class$0 = $TV($EXPECT($L99, fail, 'Class "class"'), function($skip, $loc, $0, $1) {
8925
+ var Class$0 = $TV($EXPECT($L97, fail, 'Class "class"'), function($skip, $loc, $0, $1) {
8690
8926
  return { $loc, token: $1 };
8691
8927
  });
8692
8928
  function Class(state) {
@@ -8707,7 +8943,7 @@ ${input.slice(result.pos)}
8707
8943
  return result;
8708
8944
  }
8709
8945
  }
8710
- var CloseBrace$0 = $TV($EXPECT($L27, fail, 'CloseBrace "}"'), function($skip, $loc, $0, $1) {
8946
+ var CloseBrace$0 = $TV($EXPECT($L28, fail, 'CloseBrace "}"'), function($skip, $loc, $0, $1) {
8711
8947
  return { $loc, token: $1 };
8712
8948
  });
8713
8949
  function CloseBrace(state) {
@@ -8728,7 +8964,7 @@ ${input.slice(result.pos)}
8728
8964
  return result;
8729
8965
  }
8730
8966
  }
8731
- var CloseBracket$0 = $TV($EXPECT($L25, fail, 'CloseBracket "]"'), function($skip, $loc, $0, $1) {
8967
+ var CloseBracket$0 = $TV($EXPECT($L26, fail, 'CloseBracket "]"'), function($skip, $loc, $0, $1) {
8732
8968
  return { $loc, token: $1 };
8733
8969
  });
8734
8970
  function CloseBracket(state) {
@@ -8749,7 +8985,7 @@ ${input.slice(result.pos)}
8749
8985
  return result;
8750
8986
  }
8751
8987
  }
8752
- var CloseParen$0 = $TV($EXPECT($L15, fail, 'CloseParen ")"'), function($skip, $loc, $0, $1) {
8988
+ var CloseParen$0 = $TV($EXPECT($L14, fail, 'CloseParen ")"'), function($skip, $loc, $0, $1) {
8753
8989
  return { $loc, token: $1 };
8754
8990
  });
8755
8991
  function CloseParen(state) {
@@ -8770,7 +9006,7 @@ ${input.slice(result.pos)}
8770
9006
  return result;
8771
9007
  }
8772
9008
  }
8773
- var CoffeeSubstitutionStart$0 = $TV($EXPECT($L100, fail, 'CoffeeSubstitutionStart "#{"'), function($skip, $loc, $0, $1) {
9009
+ var CoffeeSubstitutionStart$0 = $TV($EXPECT($L98, fail, 'CoffeeSubstitutionStart "#{"'), function($skip, $loc, $0, $1) {
8774
9010
  return { $loc, token: "${" };
8775
9011
  });
8776
9012
  function CoffeeSubstitutionStart(state) {
@@ -8791,7 +9027,7 @@ ${input.slice(result.pos)}
8791
9027
  return result;
8792
9028
  }
8793
9029
  }
8794
- var Colon$0 = $TV($EXPECT($L26, fail, 'Colon ":"'), function($skip, $loc, $0, $1) {
9030
+ var Colon$0 = $TV($EXPECT($L27, fail, 'Colon ":"'), function($skip, $loc, $0, $1) {
8795
9031
  return { $loc, token: $1 };
8796
9032
  });
8797
9033
  function Colon(state) {
@@ -8812,7 +9048,7 @@ ${input.slice(result.pos)}
8812
9048
  return result;
8813
9049
  }
8814
9050
  }
8815
- var ConstructorShorthand$0 = $TV($EXPECT($L92, fail, 'ConstructorShorthand "@"'), function($skip, $loc, $0, $1) {
9051
+ var ConstructorShorthand$0 = $TV($EXPECT($L90, fail, 'ConstructorShorthand "@"'), function($skip, $loc, $0, $1) {
8816
9052
  return { $loc, token: "constructor" };
8817
9053
  });
8818
9054
  function ConstructorShorthand(state) {
@@ -8833,7 +9069,7 @@ ${input.slice(result.pos)}
8833
9069
  return result;
8834
9070
  }
8835
9071
  }
8836
- var Default$0 = $TS($S($EXPECT($L85, fail, 'Default "default"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9072
+ var Default$0 = $TS($S($EXPECT($L84, fail, 'Default "default"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8837
9073
  return { $loc, token: $1 };
8838
9074
  });
8839
9075
  function Default(state) {
@@ -8854,7 +9090,7 @@ ${input.slice(result.pos)}
8854
9090
  return result;
8855
9091
  }
8856
9092
  }
8857
- var Delete$0 = $TS($S($EXPECT($L101, fail, 'Delete "delete"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9093
+ var Delete$0 = $TS($S($EXPECT($L99, fail, 'Delete "delete"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8858
9094
  return { $loc, token: $1 };
8859
9095
  });
8860
9096
  function Delete(state) {
@@ -8875,7 +9111,7 @@ ${input.slice(result.pos)}
8875
9111
  return result;
8876
9112
  }
8877
9113
  }
8878
- var Do$0 = $TS($S($EXPECT($L102, fail, 'Do "do"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9114
+ var Do$0 = $TS($S($EXPECT($L100, fail, 'Do "do"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
8879
9115
  return { $loc, token: $1 };
8880
9116
  });
8881
9117
  function Do(state) {
@@ -8917,7 +9153,7 @@ ${input.slice(result.pos)}
8917
9153
  return result;
8918
9154
  }
8919
9155
  }
8920
- var DotDot$0 = $TV($EXPECT($L103, fail, 'DotDot ".."'), function($skip, $loc, $0, $1) {
9156
+ var DotDot$0 = $TV($EXPECT($L101, fail, 'DotDot ".."'), function($skip, $loc, $0, $1) {
8921
9157
  return { $loc, token: $1 };
8922
9158
  });
8923
9159
  function DotDot(state) {
@@ -8938,7 +9174,7 @@ ${input.slice(result.pos)}
8938
9174
  return result;
8939
9175
  }
8940
9176
  }
8941
- var DotDotDot$0 = $TV($EXPECT($L104, fail, 'DotDotDot "..."'), function($skip, $loc, $0, $1) {
9177
+ var DotDotDot$0 = $TV($EXPECT($L102, fail, 'DotDotDot "..."'), function($skip, $loc, $0, $1) {
8942
9178
  return { $loc, token: $1 };
8943
9179
  });
8944
9180
  function DotDotDot(state) {
@@ -8959,7 +9195,7 @@ ${input.slice(result.pos)}
8959
9195
  return result;
8960
9196
  }
8961
9197
  }
8962
- var DoubleColon$0 = $TV($EXPECT($L105, fail, 'DoubleColon "::"'), function($skip, $loc, $0, $1) {
9198
+ var DoubleColon$0 = $TV($EXPECT($L103, fail, 'DoubleColon "::"'), function($skip, $loc, $0, $1) {
8963
9199
  return { $loc, token: $1 };
8964
9200
  });
8965
9201
  function DoubleColon(state) {
@@ -8980,7 +9216,7 @@ ${input.slice(result.pos)}
8980
9216
  return result;
8981
9217
  }
8982
9218
  }
8983
- var DoubleQuote$0 = $TV($EXPECT($L106, fail, 'DoubleQuote "\\\\\\""'), function($skip, $loc, $0, $1) {
9219
+ var DoubleQuote$0 = $TV($EXPECT($L104, fail, 'DoubleQuote "\\\\\\""'), function($skip, $loc, $0, $1) {
8984
9220
  return { $loc, token: $1 };
8985
9221
  });
8986
9222
  function DoubleQuote(state) {
@@ -9001,7 +9237,7 @@ ${input.slice(result.pos)}
9001
9237
  return result;
9002
9238
  }
9003
9239
  }
9004
- var Else$0 = $TV($EXPECT($L107, fail, 'Else "else"'), function($skip, $loc, $0, $1) {
9240
+ var Else$0 = $TV($EXPECT($L105, fail, 'Else "else"'), function($skip, $loc, $0, $1) {
9005
9241
  return { $loc, token: $1 };
9006
9242
  });
9007
9243
  function Else(state) {
@@ -9022,7 +9258,7 @@ ${input.slice(result.pos)}
9022
9258
  return result;
9023
9259
  }
9024
9260
  }
9025
- var Equals$0 = $TV($EXPECT($L44, fail, 'Equals "="'), function($skip, $loc, $0, $1) {
9261
+ var Equals$0 = $TV($EXPECT($L24, fail, 'Equals "="'), function($skip, $loc, $0, $1) {
9026
9262
  return { $loc, token: $1 };
9027
9263
  });
9028
9264
  function Equals(state) {
@@ -9043,7 +9279,7 @@ ${input.slice(result.pos)}
9043
9279
  return result;
9044
9280
  }
9045
9281
  }
9046
- var Export$0 = $TS($S($EXPECT($L108, fail, 'Export "export"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9282
+ var Export$0 = $TS($S($EXPECT($L106, fail, 'Export "export"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9047
9283
  return { $loc, token: $1 };
9048
9284
  });
9049
9285
  function Export(state) {
@@ -9064,7 +9300,7 @@ ${input.slice(result.pos)}
9064
9300
  return result;
9065
9301
  }
9066
9302
  }
9067
- var For$0 = $TS($S($EXPECT($L109, fail, 'For "for"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9303
+ var For$0 = $TS($S($EXPECT($L107, fail, 'For "for"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9068
9304
  return { $loc, token: $1 };
9069
9305
  });
9070
9306
  function For(state) {
@@ -9085,7 +9321,7 @@ ${input.slice(result.pos)}
9085
9321
  return result;
9086
9322
  }
9087
9323
  }
9088
- var From$0 = $TS($S($EXPECT($L110, fail, 'From "from"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9324
+ var From$0 = $TS($S($EXPECT($L108, fail, 'From "from"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9089
9325
  return { $loc, token: $1 };
9090
9326
  });
9091
9327
  function From(state) {
@@ -9106,7 +9342,7 @@ ${input.slice(result.pos)}
9106
9342
  return result;
9107
9343
  }
9108
9344
  }
9109
- var Function$0 = $TV($EXPECT($L111, fail, 'Function "function"'), function($skip, $loc, $0, $1) {
9345
+ var Function$0 = $TV($EXPECT($L109, fail, 'Function "function"'), function($skip, $loc, $0, $1) {
9110
9346
  return { $loc, token: $1 };
9111
9347
  });
9112
9348
  function Function(state) {
@@ -9127,7 +9363,7 @@ ${input.slice(result.pos)}
9127
9363
  return result;
9128
9364
  }
9129
9365
  }
9130
- var GetOrSet$0 = $TS($S($C($EXPECT($L112, fail, 'GetOrSet "get"'), $EXPECT($L113, fail, 'GetOrSet "set"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9366
+ var GetOrSet$0 = $TS($S($C($EXPECT($L110, fail, 'GetOrSet "get"'), $EXPECT($L111, fail, 'GetOrSet "set"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9131
9367
  return { $loc, token: $1 };
9132
9368
  });
9133
9369
  function GetOrSet(state) {
@@ -9148,7 +9384,7 @@ ${input.slice(result.pos)}
9148
9384
  return result;
9149
9385
  }
9150
9386
  }
9151
- var If$0 = $TV($TEXT($S($EXPECT($L114, fail, 'If "if"'), $E($EXPECT($L3, fail, 'If " "')))), function($skip, $loc, $0, $1) {
9387
+ var If$0 = $TV($TEXT($S($EXPECT($L112, fail, 'If "if"'), $E($EXPECT($L4, fail, 'If " "')))), function($skip, $loc, $0, $1) {
9152
9388
  return { $loc, token: $1 };
9153
9389
  });
9154
9390
  function If(state) {
@@ -9169,7 +9405,7 @@ ${input.slice(result.pos)}
9169
9405
  return result;
9170
9406
  }
9171
9407
  }
9172
- var Import$0 = $TS($S($EXPECT($L10, fail, 'Import "import"'), $Y($EXPECT($R40, fail, "Import /\\s/"))), function($skip, $loc, $0, $1, $2) {
9408
+ var Import$0 = $TS($S($EXPECT($L10, fail, 'Import "import"'), $Y($EXPECT($R42, fail, "Import /\\s/"))), function($skip, $loc, $0, $1, $2) {
9173
9409
  return { $loc, token: $1 };
9174
9410
  });
9175
9411
  function Import(state) {
@@ -9211,7 +9447,7 @@ ${input.slice(result.pos)}
9211
9447
  return result;
9212
9448
  }
9213
9449
  }
9214
- var LetOrConst$0 = $TV($C($EXPECT($L115, fail, 'LetOrConst "let"'), $EXPECT($L116, fail, 'LetOrConst "const"')), function($skip, $loc, $0, $1) {
9450
+ var LetOrConst$0 = $TS($S($C($EXPECT($L113, fail, 'LetOrConst "let"'), $EXPECT($L114, fail, 'LetOrConst "const"')), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9215
9451
  return { $loc, token: $1 };
9216
9452
  });
9217
9453
  function LetOrConst(state) {
@@ -9232,7 +9468,7 @@ ${input.slice(result.pos)}
9232
9468
  return result;
9233
9469
  }
9234
9470
  }
9235
- var Loop$0 = $TS($S($EXPECT($L117, fail, 'Loop "loop"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9471
+ var Loop$0 = $TS($S($EXPECT($L115, fail, 'Loop "loop"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9236
9472
  return { $loc, token: "while(true)" };
9237
9473
  });
9238
9474
  function Loop(state) {
@@ -9253,7 +9489,7 @@ ${input.slice(result.pos)}
9253
9489
  return result;
9254
9490
  }
9255
9491
  }
9256
- var New$0 = $TV($EXPECT($L118, fail, 'New "new"'), function($skip, $loc, $0, $1) {
9492
+ var New$0 = $TS($S($EXPECT($L116, fail, 'New "new"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9257
9493
  return { $loc, token: $1 };
9258
9494
  });
9259
9495
  function New(state) {
@@ -9274,7 +9510,7 @@ ${input.slice(result.pos)}
9274
9510
  return result;
9275
9511
  }
9276
9512
  }
9277
- var Not$0 = $TS($S(CoffeeNotEnabled, $EXPECT($L74, fail, 'Not "not"'), NonIdContinue, $E($EXPECT($L3, fail, 'Not " "'))), function($skip, $loc, $0, $1, $2, $3, $4) {
9513
+ var Not$0 = $TS($S(CoffeeNotEnabled, $EXPECT($L72, fail, 'Not "not"'), NonIdContinue, $E($EXPECT($L4, fail, 'Not " "'))), function($skip, $loc, $0, $1, $2, $3, $4) {
9278
9514
  return { $loc, token: "!" };
9279
9515
  });
9280
9516
  function Not(state) {
@@ -9295,7 +9531,7 @@ ${input.slice(result.pos)}
9295
9531
  return result;
9296
9532
  }
9297
9533
  }
9298
- var Of$0 = $TV($EXPECT($L67, fail, 'Of "of"'), function($skip, $loc, $0, $1) {
9534
+ var Of$0 = $TV($EXPECT($L66, fail, 'Of "of"'), function($skip, $loc, $0, $1) {
9299
9535
  return { $loc, token: $1 };
9300
9536
  });
9301
9537
  function Of(state) {
@@ -9316,7 +9552,7 @@ ${input.slice(result.pos)}
9316
9552
  return result;
9317
9553
  }
9318
9554
  }
9319
- var OpenBrace$0 = $TV($EXPECT($L119, fail, 'OpenBrace "{"'), function($skip, $loc, $0, $1) {
9555
+ var OpenBrace$0 = $TV($EXPECT($L117, fail, 'OpenBrace "{"'), function($skip, $loc, $0, $1) {
9320
9556
  return { $loc, token: $1 };
9321
9557
  });
9322
9558
  function OpenBrace(state) {
@@ -9337,7 +9573,7 @@ ${input.slice(result.pos)}
9337
9573
  return result;
9338
9574
  }
9339
9575
  }
9340
- var OpenBracket$0 = $TV($EXPECT($L120, fail, 'OpenBracket "["'), function($skip, $loc, $0, $1) {
9576
+ var OpenBracket$0 = $TV($EXPECT($L118, fail, 'OpenBracket "["'), function($skip, $loc, $0, $1) {
9341
9577
  return { $loc, token: $1 };
9342
9578
  });
9343
9579
  function OpenBracket(state) {
@@ -9358,7 +9594,7 @@ ${input.slice(result.pos)}
9358
9594
  return result;
9359
9595
  }
9360
9596
  }
9361
- var OpenParen$0 = $TV($EXPECT($L121, fail, 'OpenParen "("'), function($skip, $loc, $0, $1) {
9597
+ var OpenParen$0 = $TV($EXPECT($L119, fail, 'OpenParen "("'), function($skip, $loc, $0, $1) {
9362
9598
  return { $loc, token: $1 };
9363
9599
  });
9364
9600
  function OpenParen(state) {
@@ -9379,7 +9615,7 @@ ${input.slice(result.pos)}
9379
9615
  return result;
9380
9616
  }
9381
9617
  }
9382
- var QuestionMark$0 = $TV($EXPECT($L71, fail, 'QuestionMark "?"'), function($skip, $loc, $0, $1) {
9618
+ var QuestionMark$0 = $TV($EXPECT($L70, fail, 'QuestionMark "?"'), function($skip, $loc, $0, $1) {
9383
9619
  return { $loc, token: $1 };
9384
9620
  });
9385
9621
  function QuestionMark(state) {
@@ -9400,7 +9636,7 @@ ${input.slice(result.pos)}
9400
9636
  return result;
9401
9637
  }
9402
9638
  }
9403
- var Return$0 = $TS($S($EXPECT($L122, fail, 'Return "return"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9639
+ var Return$0 = $TS($S($EXPECT($L120, fail, 'Return "return"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9404
9640
  return { $loc, token: $1 };
9405
9641
  });
9406
9642
  function Return(state) {
@@ -9421,7 +9657,7 @@ ${input.slice(result.pos)}
9421
9657
  return result;
9422
9658
  }
9423
9659
  }
9424
- var Semicolon$0 = $TV($EXPECT($L78, fail, 'Semicolon ";"'), function($skip, $loc, $0, $1) {
9660
+ var Semicolon$0 = $TV($EXPECT($L77, fail, 'Semicolon ";"'), function($skip, $loc, $0, $1) {
9425
9661
  return { $loc, token: $1 };
9426
9662
  });
9427
9663
  function Semicolon(state) {
@@ -9442,7 +9678,7 @@ ${input.slice(result.pos)}
9442
9678
  return result;
9443
9679
  }
9444
9680
  }
9445
- var SingleQuote$0 = $TV($EXPECT($L123, fail, `SingleQuote "'"`), function($skip, $loc, $0, $1) {
9681
+ var SingleQuote$0 = $TV($EXPECT($L121, fail, `SingleQuote "'"`), function($skip, $loc, $0, $1) {
9446
9682
  return { $loc, token: $1 };
9447
9683
  });
9448
9684
  function SingleQuote(state) {
@@ -9484,10 +9720,10 @@ ${input.slice(result.pos)}
9484
9720
  return result;
9485
9721
  }
9486
9722
  }
9487
- var Static$0 = $TV($EXPECT($L124, fail, 'Static "static"'), function($skip, $loc, $0, $1) {
9723
+ var Static$0 = $TV($EXPECT($L122, fail, 'Static "static"'), function($skip, $loc, $0, $1) {
9488
9724
  return { $loc, token: $1 };
9489
9725
  });
9490
- var Static$1 = $TS($S($EXPECT($L92, fail, 'Static "@"'), $N($EXPECT($L121, fail, 'Static "("'))), function($skip, $loc, $0, $1, $2) {
9726
+ var Static$1 = $TS($S($EXPECT($L90, fail, 'Static "@"'), $N($EXPECT($L119, fail, 'Static "("'))), function($skip, $loc, $0, $1, $2) {
9491
9727
  return { $loc, token: "static " };
9492
9728
  });
9493
9729
  function Static(state) {
@@ -9508,7 +9744,7 @@ ${input.slice(result.pos)}
9508
9744
  return result;
9509
9745
  }
9510
9746
  }
9511
- var SubstitutionStart$0 = $TV($EXPECT($L125, fail, 'SubstitutionStart "${"'), function($skip, $loc, $0, $1) {
9747
+ var SubstitutionStart$0 = $TV($EXPECT($L123, fail, 'SubstitutionStart "${"'), function($skip, $loc, $0, $1) {
9512
9748
  return { $loc, token: $1 };
9513
9749
  });
9514
9750
  function SubstitutionStart(state) {
@@ -9529,7 +9765,7 @@ ${input.slice(result.pos)}
9529
9765
  return result;
9530
9766
  }
9531
9767
  }
9532
- var Switch$0 = $TS($S($EXPECT($L126, fail, 'Switch "switch"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9768
+ var Switch$0 = $TS($S($EXPECT($L124, fail, 'Switch "switch"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9533
9769
  return { $loc, token: $1 };
9534
9770
  });
9535
9771
  function Switch(state) {
@@ -9550,7 +9786,7 @@ ${input.slice(result.pos)}
9550
9786
  return result;
9551
9787
  }
9552
9788
  }
9553
- var Target$0 = $TV($EXPECT($L127, fail, 'Target "target"'), function($skip, $loc, $0, $1) {
9789
+ var Target$0 = $TS($S($EXPECT($L125, fail, 'Target "target"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9554
9790
  return { $loc, token: $1 };
9555
9791
  });
9556
9792
  function Target(state) {
@@ -9571,7 +9807,7 @@ ${input.slice(result.pos)}
9571
9807
  return result;
9572
9808
  }
9573
9809
  }
9574
- var Then$0 = $TS($S(__, $EXPECT($L128, fail, 'Then "then"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3) {
9810
+ var Then$0 = $TS($S(__, $EXPECT($L126, fail, 'Then "then"'), NonIdContinue), function($skip, $loc, $0, $1, $2, $3) {
9575
9811
  return { $loc, token: "" };
9576
9812
  });
9577
9813
  function Then(state) {
@@ -9592,7 +9828,28 @@ ${input.slice(result.pos)}
9592
9828
  return result;
9593
9829
  }
9594
9830
  }
9595
- var Throw$0 = $TS($S($EXPECT($L129, fail, 'Throw "throw"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9831
+ var This$0 = $TS($S($EXPECT($L127, fail, 'This "this"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9832
+ return { $loc, token: $1 };
9833
+ });
9834
+ function This(state) {
9835
+ if (state.events) {
9836
+ const result = state.events.enter?.("This", state);
9837
+ if (result)
9838
+ return result.cache;
9839
+ }
9840
+ if (state.tokenize) {
9841
+ const result = $TOKEN("This", state, This$0(state));
9842
+ if (state.events)
9843
+ state.events.exit?.("This", state, result);
9844
+ return result;
9845
+ } else {
9846
+ const result = This$0(state);
9847
+ if (state.events)
9848
+ state.events.exit?.("This", state, result);
9849
+ return result;
9850
+ }
9851
+ }
9852
+ var Throw$0 = $TS($S($EXPECT($L128, fail, 'Throw "throw"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9596
9853
  return { $loc, token: $1 };
9597
9854
  });
9598
9855
  function Throw(state) {
@@ -9613,7 +9870,7 @@ ${input.slice(result.pos)}
9613
9870
  return result;
9614
9871
  }
9615
9872
  }
9616
- var TripleDoubleQuote$0 = $TV($EXPECT($L130, fail, 'TripleDoubleQuote "\\\\\\"\\\\\\"\\\\\\""'), function($skip, $loc, $0, $1) {
9873
+ var TripleDoubleQuote$0 = $TV($EXPECT($L129, fail, 'TripleDoubleQuote "\\\\\\"\\\\\\"\\\\\\""'), function($skip, $loc, $0, $1) {
9617
9874
  return { $loc, token: "`" };
9618
9875
  });
9619
9876
  function TripleDoubleQuote(state) {
@@ -9634,7 +9891,7 @@ ${input.slice(result.pos)}
9634
9891
  return result;
9635
9892
  }
9636
9893
  }
9637
- var TripleSingleQuote$0 = $TV($EXPECT($L131, fail, `TripleSingleQuote "'''"`), function($skip, $loc, $0, $1) {
9894
+ var TripleSingleQuote$0 = $TV($EXPECT($L130, fail, `TripleSingleQuote "'''"`), function($skip, $loc, $0, $1) {
9638
9895
  return { $loc, token: "`" };
9639
9896
  });
9640
9897
  function TripleSingleQuote(state) {
@@ -9655,7 +9912,7 @@ ${input.slice(result.pos)}
9655
9912
  return result;
9656
9913
  }
9657
9914
  }
9658
- var TripleSlash$0 = $TV($EXPECT($L132, fail, 'TripleSlash "///"'), function($skip, $loc, $0, $1) {
9915
+ var TripleSlash$0 = $TV($EXPECT($L131, fail, 'TripleSlash "///"'), function($skip, $loc, $0, $1) {
9659
9916
  return { $loc, token: "/" };
9660
9917
  });
9661
9918
  function TripleSlash(state) {
@@ -9676,7 +9933,7 @@ ${input.slice(result.pos)}
9676
9933
  return result;
9677
9934
  }
9678
9935
  }
9679
- var TripleTick$0 = $TV($EXPECT($L133, fail, 'TripleTick "```"'), function($skip, $loc, $0, $1) {
9936
+ var TripleTick$0 = $TV($EXPECT($L132, fail, 'TripleTick "```"'), function($skip, $loc, $0, $1) {
9680
9937
  return { $loc, token: "`" };
9681
9938
  });
9682
9939
  function TripleTick(state) {
@@ -9697,7 +9954,7 @@ ${input.slice(result.pos)}
9697
9954
  return result;
9698
9955
  }
9699
9956
  }
9700
- var Try$0 = $TV($EXPECT($L134, fail, 'Try "try"'), function($skip, $loc, $0, $1) {
9957
+ var Try$0 = $TS($S($EXPECT($L133, fail, 'Try "try"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9701
9958
  return { $loc, token: $1 };
9702
9959
  });
9703
9960
  function Try(state) {
@@ -9718,7 +9975,7 @@ ${input.slice(result.pos)}
9718
9975
  return result;
9719
9976
  }
9720
9977
  }
9721
- var Typeof$0 = $TS($S($EXPECT($L135, fail, 'Typeof "typeof"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9978
+ var Typeof$0 = $TS($S($EXPECT($L134, fail, 'Typeof "typeof"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9722
9979
  return { $loc, token: $1 };
9723
9980
  });
9724
9981
  function Typeof(state) {
@@ -9739,7 +9996,7 @@ ${input.slice(result.pos)}
9739
9996
  return result;
9740
9997
  }
9741
9998
  }
9742
- var Unless$0 = $TV($EXPECT($L136, fail, 'Unless "unless"'), function($skip, $loc, $0, $1) {
9999
+ var Unless$0 = $TS($S($EXPECT($L135, fail, 'Unless "unless"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9743
10000
  return { $loc, token: $1 };
9744
10001
  });
9745
10002
  function Unless(state) {
@@ -9760,7 +10017,7 @@ ${input.slice(result.pos)}
9760
10017
  return result;
9761
10018
  }
9762
10019
  }
9763
- var Until$0 = $TS($S($EXPECT($L137, fail, 'Until "until"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
10020
+ var Until$0 = $TS($S($EXPECT($L136, fail, 'Until "until"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9764
10021
  return { $loc, token: $1 };
9765
10022
  });
9766
10023
  function Until(state) {
@@ -9781,7 +10038,7 @@ ${input.slice(result.pos)}
9781
10038
  return result;
9782
10039
  }
9783
10040
  }
9784
- var Var$0 = $TV($EXPECT($L138, fail, 'Var "var"'), function($skip, $loc, $0, $1) {
10041
+ var Var$0 = $TS($S($EXPECT($L137, fail, 'Var "var"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9785
10042
  return { $loc, token: $1 };
9786
10043
  });
9787
10044
  function Var(state) {
@@ -9802,7 +10059,7 @@ ${input.slice(result.pos)}
9802
10059
  return result;
9803
10060
  }
9804
10061
  }
9805
- var Void$0 = $TS($S($EXPECT($L139, fail, 'Void "void"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
10062
+ var Void$0 = $TS($S($EXPECT($L138, fail, 'Void "void"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9806
10063
  return { $loc, token: $1 };
9807
10064
  });
9808
10065
  function Void(state) {
@@ -9823,7 +10080,7 @@ ${input.slice(result.pos)}
9823
10080
  return result;
9824
10081
  }
9825
10082
  }
9826
- var When$0 = $TS($S($EXPECT($L140, fail, 'When "when"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
10083
+ var When$0 = $TS($S($EXPECT($L139, fail, 'When "when"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9827
10084
  return { $loc, token: "case" };
9828
10085
  });
9829
10086
  function When(state) {
@@ -9844,7 +10101,7 @@ ${input.slice(result.pos)}
9844
10101
  return result;
9845
10102
  }
9846
10103
  }
9847
- var While$0 = $TS($S($EXPECT($L141, fail, 'While "while"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
10104
+ var While$0 = $TS($S($EXPECT($L140, fail, 'While "while"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9848
10105
  return { $loc, token: $1 };
9849
10106
  });
9850
10107
  function While(state) {
@@ -9865,7 +10122,7 @@ ${input.slice(result.pos)}
9865
10122
  return result;
9866
10123
  }
9867
10124
  }
9868
- var Yield$0 = $TS($S($EXPECT($L142, fail, 'Yield "yield"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
10125
+ var Yield$0 = $TS($S($EXPECT($L141, fail, 'Yield "yield"'), NonIdContinue), function($skip, $loc, $0, $1, $2) {
9869
10126
  return { $loc, token: $1 };
9870
10127
  });
9871
10128
  function Yield(state) {
@@ -9911,7 +10168,7 @@ ${input.slice(result.pos)}
9911
10168
  return result;
9912
10169
  }
9913
10170
  }
9914
- var JSXSelfClosingElement$0 = $S($EXPECT($L4, fail, 'JSXSelfClosingElement "<"'), $TEXT(JSXElementName), $E(JSXAttributes), __, $EXPECT($L143, fail, 'JSXSelfClosingElement "/>"'));
10171
+ var JSXSelfClosingElement$0 = $S($EXPECT($L5, fail, 'JSXSelfClosingElement "<"'), $TEXT(JSXElementName), $E(JSXAttributes), __, $EXPECT($L142, fail, 'JSXSelfClosingElement "/>"'));
9915
10172
  function JSXSelfClosingElement(state) {
9916
10173
  if (state.events) {
9917
10174
  const result = state.events.enter?.("JSXSelfClosingElement", state);
@@ -9930,7 +10187,7 @@ ${input.slice(result.pos)}
9930
10187
  return result;
9931
10188
  }
9932
10189
  }
9933
- var JSXOpeningElement$0 = $S($EXPECT($L4, fail, 'JSXOpeningElement "<"'), $TEXT(JSXElementName), $E(JSXAttributes), __, $EXPECT($L58, fail, 'JSXOpeningElement ">"'));
10190
+ var JSXOpeningElement$0 = $S($EXPECT($L5, fail, 'JSXOpeningElement "<"'), $TEXT(JSXElementName), $E(JSXAttributes), __, $EXPECT($L25, fail, 'JSXOpeningElement ">"'));
9934
10191
  function JSXOpeningElement(state) {
9935
10192
  if (state.events) {
9936
10193
  const result = state.events.enter?.("JSXOpeningElement", state);
@@ -9949,7 +10206,7 @@ ${input.slice(result.pos)}
9949
10206
  return result;
9950
10207
  }
9951
10208
  }
9952
- var JSXClosingElement$0 = $S($EXPECT($L144, fail, 'JSXClosingElement "</"'), __, $TEXT(JSXElementName), __, $EXPECT($L58, fail, 'JSXClosingElement ">"'));
10209
+ var JSXClosingElement$0 = $S($EXPECT($L143, fail, 'JSXClosingElement "</"'), __, $TEXT(JSXElementName), __, $EXPECT($L25, fail, 'JSXClosingElement ">"'));
9953
10210
  function JSXClosingElement(state) {
9954
10211
  if (state.events) {
9955
10212
  const result = state.events.enter?.("JSXClosingElement", state);
@@ -9968,7 +10225,7 @@ ${input.slice(result.pos)}
9968
10225
  return result;
9969
10226
  }
9970
10227
  }
9971
- var JSXFragment$0 = $S($EXPECT($L145, fail, 'JSXFragment "<>"'), $E(JSXChildren), $EXPECT($L146, fail, 'JSXFragment "</>"'));
10228
+ var JSXFragment$0 = $S($EXPECT($L144, fail, 'JSXFragment "<>"'), $E(JSXChildren), $EXPECT($L145, fail, 'JSXFragment "</>"'));
9972
10229
  function JSXFragment(state) {
9973
10230
  if (state.events) {
9974
10231
  const result = state.events.enter?.("JSXFragment", state);
@@ -10006,7 +10263,7 @@ ${input.slice(result.pos)}
10006
10263
  return result;
10007
10264
  }
10008
10265
  }
10009
- var JSXIdentifierName$0 = $R$0($EXPECT($R41, fail, "JSXIdentifierName /(?:\\p{ID_Start}|[_$])(?:\\p{ID_Continue}|[\\u200C\\u200D$-])*/"));
10266
+ var JSXIdentifierName$0 = $R$0($EXPECT($R43, fail, "JSXIdentifierName /(?:\\p{ID_Start}|[_$])(?:\\p{ID_Continue}|[\\u200C\\u200D$-])*/"));
10010
10267
  function JSXIdentifierName(state) {
10011
10268
  if (state.events) {
10012
10269
  const result = state.events.enter?.("JSXIdentifierName", state);
@@ -10102,8 +10359,8 @@ ${input.slice(result.pos)}
10102
10359
  return result;
10103
10360
  }
10104
10361
  }
10105
- var JSXAttributeValue$0 = $R$0($EXPECT($R42, fail, 'JSXAttributeValue /"[^"]*"/'));
10106
- var JSXAttributeValue$1 = $R$0($EXPECT($R43, fail, "JSXAttributeValue /'[^']*'/"));
10362
+ var JSXAttributeValue$0 = $R$0($EXPECT($R44, fail, 'JSXAttributeValue /"[^"]*"/'));
10363
+ var JSXAttributeValue$1 = $R$0($EXPECT($R45, fail, "JSXAttributeValue /'[^']*'/"));
10107
10364
  var JSXAttributeValue$2 = $S(OpenBrace, ExtendedExpression, __, CloseBrace);
10108
10365
  var JSXAttributeValue$3 = JSXElement;
10109
10366
  var JSXAttributeValue$4 = JSXFragment;
@@ -10166,7 +10423,7 @@ ${input.slice(result.pos)}
10166
10423
  return result;
10167
10424
  }
10168
10425
  }
10169
- var JSXText$0 = $R$0($EXPECT($R44, fail, "JSXText /[^{}<>]+/"));
10426
+ var JSXText$0 = $R$0($EXPECT($R46, fail, "JSXText /[^{}<>]+/"));
10170
10427
  function JSXText(state) {
10171
10428
  if (state.events) {
10172
10429
  const result = state.events.enter?.("JSXText", state);
@@ -10225,7 +10482,7 @@ ${input.slice(result.pos)}
10225
10482
  return result;
10226
10483
  }
10227
10484
  }
10228
- var TypeDeclarationModifier$0 = $S($EXPECT($L147, fail, 'TypeDeclarationModifier "declare"'), NonIdContinue);
10485
+ var TypeDeclarationModifier$0 = $S($EXPECT($L146, fail, 'TypeDeclarationModifier "declare"'), NonIdContinue);
10229
10486
  var TypeDeclarationModifier$1 = Export;
10230
10487
  function TypeDeclarationModifier(state) {
10231
10488
  if (state.events) {
@@ -10267,7 +10524,7 @@ ${input.slice(result.pos)}
10267
10524
  return result;
10268
10525
  }
10269
10526
  }
10270
- var TypeKeyword$0 = $S($EXPECT($L148, fail, 'TypeKeyword "type"'), NonIdContinue);
10527
+ var TypeKeyword$0 = $S($EXPECT($L147, fail, 'TypeKeyword "type"'), NonIdContinue);
10271
10528
  function TypeKeyword(state) {
10272
10529
  if (state.events) {
10273
10530
  const result = state.events.enter?.("TypeKeyword", state);
@@ -10286,7 +10543,7 @@ ${input.slice(result.pos)}
10286
10543
  return result;
10287
10544
  }
10288
10545
  }
10289
- var Interface$0 = $S($EXPECT($L149, fail, 'Interface "interface"'), NonIdContinue);
10546
+ var Interface$0 = $S($EXPECT($L148, fail, 'Interface "interface"'), NonIdContinue);
10290
10547
  function Interface(state) {
10291
10548
  if (state.events) {
10292
10549
  const result = state.events.enter?.("Interface", state);
@@ -10305,7 +10562,7 @@ ${input.slice(result.pos)}
10305
10562
  return result;
10306
10563
  }
10307
10564
  }
10308
- var Namespace$0 = $S($EXPECT($L150, fail, 'Namespace "namespace"'), NonIdContinue);
10565
+ var Namespace$0 = $S($EXPECT($L149, fail, 'Namespace "namespace"'), NonIdContinue);
10309
10566
  function Namespace(state) {
10310
10567
  if (state.events) {
10311
10568
  const result = state.events.enter?.("Namespace", state);
@@ -10494,7 +10751,7 @@ ${input.slice(result.pos)}
10494
10751
  return result;
10495
10752
  }
10496
10753
  }
10497
- var TypeIndexSignature$0 = $S($E($S($R$0($EXPECT($R45, fail, "TypeIndexSignature /[+-]?/")), $EXPECT($L151, fail, 'TypeIndexSignature "readonly"'), __)), OpenBracket, TypeIndex, CloseBracket, $E($S(__, $R$0($EXPECT($R46, fail, "TypeIndexSignature /[+-]/")), QuestionMark)));
10754
+ var TypeIndexSignature$0 = $S($E($S($R$0($EXPECT($R47, fail, "TypeIndexSignature /[+-]?/")), $EXPECT($L150, fail, 'TypeIndexSignature "readonly"'), __)), OpenBracket, TypeIndex, CloseBracket, $E($S(__, $R$0($EXPECT($R48, fail, "TypeIndexSignature /[+-]/")), QuestionMark)));
10498
10755
  function TypeIndexSignature(state) {
10499
10756
  if (state.events) {
10500
10757
  const result = state.events.enter?.("TypeIndexSignature", state);
@@ -10554,7 +10811,7 @@ ${input.slice(result.pos)}
10554
10811
  return result;
10555
10812
  }
10556
10813
  }
10557
- var ReturnTypeSuffix$0 = $TS($S(__, Colon, $E($S(__, $EXPECT($L152, fail, 'ReturnTypeSuffix "asserts"'), NonIdContinue)), TypePredicate), function($skip, $loc, $0, $1, $2, $3, $4) {
10814
+ var ReturnTypeSuffix$0 = $TS($S(__, Colon, $E($S(__, $EXPECT($L151, fail, 'ReturnTypeSuffix "asserts"'), NonIdContinue)), TypePredicate), function($skip, $loc, $0, $1, $2, $3, $4) {
10558
10815
  const children = [...$1, $2];
10559
10816
  if ($3)
10560
10817
  children.push($3);
@@ -10583,7 +10840,7 @@ ${input.slice(result.pos)}
10583
10840
  return result;
10584
10841
  }
10585
10842
  }
10586
- var TypePredicate$0 = $TS($S(Type, $E($S(__, $EXPECT($L62, fail, 'TypePredicate "is"'), NonIdContinue, Type))), function($skip, $loc, $0, $1, $2) {
10843
+ var TypePredicate$0 = $TS($S(Type, $E($S(__, $EXPECT($L61, fail, 'TypePredicate "is"'), NonIdContinue, Type))), function($skip, $loc, $0, $1, $2) {
10587
10844
  if (!$2)
10588
10845
  return $1;
10589
10846
  return $0;
@@ -10689,9 +10946,9 @@ ${input.slice(result.pos)}
10689
10946
  return result;
10690
10947
  }
10691
10948
  }
10692
- var TypeUnaryOp$0 = $EXPECT($L153, fail, 'TypeUnaryOp "keyof"');
10693
- var TypeUnaryOp$1 = $EXPECT($L135, fail, 'TypeUnaryOp "typeof"');
10694
- var TypeUnaryOp$2 = $EXPECT($L154, fail, 'TypeUnaryOp "infer"');
10949
+ var TypeUnaryOp$0 = $EXPECT($L152, fail, 'TypeUnaryOp "keyof"');
10950
+ var TypeUnaryOp$1 = $EXPECT($L134, fail, 'TypeUnaryOp "typeof"');
10951
+ var TypeUnaryOp$2 = $EXPECT($L153, fail, 'TypeUnaryOp "infer"');
10695
10952
  function TypeUnaryOp(state) {
10696
10953
  if (state.events) {
10697
10954
  const result = state.events.enter?.("TypeUnaryOp", state);
@@ -10835,7 +11092,7 @@ ${input.slice(result.pos)}
10835
11092
  return result;
10836
11093
  }
10837
11094
  }
10838
- var TypeConditional$0 = $TS($S(TypeBinary, $E($S(__, $EXPECT($L5, fail, 'TypeConditional "extends"'), Type, $E($S(__, QuestionMark, Type, __, Colon, Type))))), function($skip, $loc, $0, $1, $2) {
11095
+ var TypeConditional$0 = $TS($S(TypeBinary, $E($S(__, $EXPECT($L6, fail, 'TypeConditional "extends"'), Type, $E($S(__, QuestionMark, Type, __, Colon, Type))))), function($skip, $loc, $0, $1, $2) {
10839
11096
  if ($2)
10840
11097
  return $0;
10841
11098
  return $1;
@@ -10859,10 +11116,10 @@ ${input.slice(result.pos)}
10859
11116
  }
10860
11117
  }
10861
11118
  var TypeLiteral$0 = Literal;
10862
- var TypeLiteral$1 = $TV($EXPECT($L139, fail, 'TypeLiteral "void"'), function($skip, $loc, $0, $1) {
11119
+ var TypeLiteral$1 = $TV($EXPECT($L138, fail, 'TypeLiteral "void"'), function($skip, $loc, $0, $1) {
10863
11120
  return { $loc, token: "void" };
10864
11121
  });
10865
- var TypeLiteral$2 = $TV($EXPECT($L155, fail, 'TypeLiteral "[]"'), function($skip, $loc, $0, $1) {
11122
+ var TypeLiteral$2 = $TV($EXPECT($L154, fail, 'TypeLiteral "[]"'), function($skip, $loc, $0, $1) {
10866
11123
  return { $loc, token: "[]" };
10867
11124
  });
10868
11125
  function TypeLiteral(state) {
@@ -10883,10 +11140,10 @@ ${input.slice(result.pos)}
10883
11140
  return result;
10884
11141
  }
10885
11142
  }
10886
- var TypeBinaryOp$0 = $TV($EXPECT($L77, fail, 'TypeBinaryOp "|"'), function($skip, $loc, $0, $1) {
11143
+ var TypeBinaryOp$0 = $TV($EXPECT($L76, fail, 'TypeBinaryOp "|"'), function($skip, $loc, $0, $1) {
10887
11144
  return { $loc, token: "|" };
10888
11145
  });
10889
- var TypeBinaryOp$1 = $TV($EXPECT($L75, fail, 'TypeBinaryOp "&"'), function($skip, $loc, $0, $1) {
11146
+ var TypeBinaryOp$1 = $TV($EXPECT($L74, fail, 'TypeBinaryOp "&"'), function($skip, $loc, $0, $1) {
10890
11147
  return { $loc, token: "&" };
10891
11148
  });
10892
11149
  function TypeBinaryOp(state) {
@@ -10907,7 +11164,7 @@ ${input.slice(result.pos)}
10907
11164
  return result;
10908
11165
  }
10909
11166
  }
10910
- var FunctionType$0 = $S(Parameters, __, $EXPECT($L2, fail, 'FunctionType "=>"'), Type);
11167
+ var FunctionType$0 = $S(Parameters, __, $EXPECT($L3, fail, 'FunctionType "=>"'), Type);
10911
11168
  function FunctionType(state) {
10912
11169
  if (state.events) {
10913
11170
  const result = state.events.enter?.("FunctionType", state);
@@ -10926,7 +11183,7 @@ ${input.slice(result.pos)}
10926
11183
  return result;
10927
11184
  }
10928
11185
  }
10929
- var TypeArguments$0 = $S(__, $EXPECT($L4, fail, 'TypeArguments "<"'), __, Type, $Q($S(__, Comma, __, Type)), $E($S(__, Comma)), __, $EXPECT($L58, fail, 'TypeArguments ">"'));
11186
+ var TypeArguments$0 = $S(__, $EXPECT($L5, fail, 'TypeArguments "<"'), __, Type, $Q($S(__, Comma, __, Type)), $E($S(__, Comma)), __, $EXPECT($L25, fail, 'TypeArguments ">"'));
10930
11187
  function TypeArguments(state) {
10931
11188
  if (state.events) {
10932
11189
  const result = state.events.enter?.("TypeArguments", state);
@@ -10945,7 +11202,7 @@ ${input.slice(result.pos)}
10945
11202
  return result;
10946
11203
  }
10947
11204
  }
10948
- var TypeParameters$0 = $TS($S(__, $EXPECT($L4, fail, 'TypeParameters "<"'), __, Type, $Q($S(__, Comma, __, Type)), $E($S(__, Comma)), __, $EXPECT($L58, fail, 'TypeParameters ">"')), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8) {
11205
+ var TypeParameters$0 = $TS($S(__, $EXPECT($L5, fail, 'TypeParameters "<"'), __, Type, $Q($S(__, Comma, __, Type)), $E($S(__, Comma)), __, $EXPECT($L25, fail, 'TypeParameters ">"')), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8) {
10949
11206
  return { ts: true, children: $0 };
10950
11207
  });
10951
11208
  function TypeParameters(state) {
@@ -10985,7 +11242,7 @@ ${input.slice(result.pos)}
10985
11242
  return result;
10986
11243
  }
10987
11244
  }
10988
- var TypeConstraint$0 = $S(__, $EXPECT($L5, fail, 'TypeConstraint "extends"'), Type);
11245
+ var TypeConstraint$0 = $S(__, $EXPECT($L6, fail, 'TypeConstraint "extends"'), Type);
10989
11246
  function TypeConstraint(state) {
10990
11247
  if (state.events) {
10991
11248
  const result = state.events.enter?.("TypeConstraint", state);
@@ -11005,8 +11262,8 @@ ${input.slice(result.pos)}
11005
11262
  }
11006
11263
  }
11007
11264
  var TypeParameterDelimiter$0 = $S($Q(_), Comma);
11008
- var TypeParameterDelimiter$1 = $Y($S($Q(_), $EXPECT($L58, fail, 'TypeParameterDelimiter ">"')));
11009
- var TypeParameterDelimiter$2 = $TV($Y($S(__, $EXPECT($L58, fail, 'TypeParameterDelimiter ">"'))), function($skip, $loc, $0, $1) {
11265
+ var TypeParameterDelimiter$1 = $Y($S($Q(_), $EXPECT($L25, fail, 'TypeParameterDelimiter ">"')));
11266
+ var TypeParameterDelimiter$2 = $TV($Y($S(__, $EXPECT($L25, fail, 'TypeParameterDelimiter ">"'))), function($skip, $loc, $0, $1) {
11010
11267
  return { $loc, token: "," };
11011
11268
  });
11012
11269
  var TypeParameterDelimiter$3 = $TV($Y(EOS), function($skip, $loc, $0, $1) {
@@ -11030,7 +11287,7 @@ ${input.slice(result.pos)}
11030
11287
  return result;
11031
11288
  }
11032
11289
  }
11033
- var Shebang$0 = $S($R$0($EXPECT($R47, fail, "Shebang /#![^\\r\\n]*/")), EOL);
11290
+ var Shebang$0 = $S($R$0($EXPECT($R49, fail, "Shebang /#![^\\r\\n]*/")), EOL);
11034
11291
  function Shebang(state) {
11035
11292
  if (state.events) {
11036
11293
  const result = state.events.enter?.("Shebang", state);
@@ -11049,11 +11306,11 @@ ${input.slice(result.pos)}
11049
11306
  return result;
11050
11307
  }
11051
11308
  }
11052
- var CivetPrologue$0 = $T($S($EXPECT($R48, fail, "CivetPrologue /[\\t ]*/"), DoubleQuote, CivetPrologueContent, DoubleQuote, $TEXT(StatementDelimiter), EOS), function(value) {
11309
+ var CivetPrologue$0 = $T($S($EXPECT($R50, fail, "CivetPrologue /[\\t ]*/"), DoubleQuote, CivetPrologueContent, DoubleQuote, $TEXT(StatementDelimiter), EOS), function(value) {
11053
11310
  var content = value[2];
11054
11311
  return content;
11055
11312
  });
11056
- var CivetPrologue$1 = $T($S($EXPECT($R48, fail, "CivetPrologue /[\\t ]*/"), SingleQuote, CivetPrologueContent, SingleQuote, $TEXT(StatementDelimiter), EOS), function(value) {
11313
+ var CivetPrologue$1 = $T($S($EXPECT($R50, fail, "CivetPrologue /[\\t ]*/"), SingleQuote, CivetPrologueContent, SingleQuote, $TEXT(StatementDelimiter), EOS), function(value) {
11057
11314
  var content = value[2];
11058
11315
  return content;
11059
11316
  });
@@ -11075,7 +11332,7 @@ ${input.slice(result.pos)}
11075
11332
  return result;
11076
11333
  }
11077
11334
  }
11078
- var CivetPrologueContent$0 = $TS($S($EXPECT($L156, fail, 'CivetPrologueContent "civet"'), $Q(CivetOption), $EXPECT($R49, fail, "CivetPrologueContent /[\\s]*/")), function($skip, $loc, $0, $1, $2, $3) {
11335
+ var CivetPrologueContent$0 = $TS($S($EXPECT($L155, fail, 'CivetPrologueContent "civet"'), $Q(CivetOption), $EXPECT($R51, fail, "CivetPrologueContent /[\\s]*/")), function($skip, $loc, $0, $1, $2, $3) {
11079
11336
  var options = $2;
11080
11337
  return {
11081
11338
  type: "CivetPrologue",
@@ -11101,7 +11358,7 @@ ${input.slice(result.pos)}
11101
11358
  return result;
11102
11359
  }
11103
11360
  }
11104
- var CivetOption$0 = $TR($EXPECT($R50, fail, "CivetOption /\\s+([+-]?)([a-zA-Z0-9-]+)/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
11361
+ var CivetOption$0 = $TR($EXPECT($R52, fail, "CivetOption /\\s+([+-]?)([a-zA-Z0-9-]+)/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
11105
11362
  const optionName = $2.replace(/-+([a-z]?)/g, (_2, l) => {
11106
11363
  if (l)
11107
11364
  return l.toUpperCase();
@@ -11128,7 +11385,7 @@ ${input.slice(result.pos)}
11128
11385
  return result;
11129
11386
  }
11130
11387
  }
11131
- var UnknownPrologue$0 = $S($R$0($EXPECT($R48, fail, "UnknownPrologue /[\\t ]*/")), BasicStringLiteral, $TEXT(StatementDelimiter), EOS);
11388
+ var UnknownPrologue$0 = $S($R$0($EXPECT($R50, fail, "UnknownPrologue /[\\t ]*/")), BasicStringLiteral, $TEXT(StatementDelimiter), EOS);
11132
11389
  function UnknownPrologue(state) {
11133
11390
  if (state.events) {
11134
11391
  const result = state.events.enter?.("UnknownPrologue", state);
@@ -11186,7 +11443,7 @@ ${input.slice(result.pos)}
11186
11443
  return result;
11187
11444
  }
11188
11445
  }
11189
- var EOL$0 = $TR($EXPECT($R51, fail, "EOL /\\r\\n|\\n|\\r|$/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
11446
+ var EOL$0 = $TR($EXPECT($R53, fail, "EOL /\\r\\n|\\n|\\r|$/"), function($skip, $loc, $0, $1, $2, $3, $4, $5, $6, $7, $8, $9) {
11190
11447
  return { $loc, token: $0 };
11191
11448
  });
11192
11449
  function EOL(state) {
@@ -11207,7 +11464,7 @@ ${input.slice(result.pos)}
11207
11464
  return result;
11208
11465
  }
11209
11466
  }
11210
- var Debugger$0 = $TV($EXPECT($L14, fail, 'Debugger ""'), function($skip, $loc, $0, $1) {
11467
+ var Debugger$0 = $TV($EXPECT($L0, fail, 'Debugger ""'), function($skip, $loc, $0, $1) {
11211
11468
  debugger;
11212
11469
  });
11213
11470
  function Debugger(state) {
@@ -11228,7 +11485,7 @@ ${input.slice(result.pos)}
11228
11485
  return result;
11229
11486
  }
11230
11487
  }
11231
- var InsertOpenParen$0 = $TV($EXPECT($L14, fail, 'InsertOpenParen ""'), function($skip, $loc, $0, $1) {
11488
+ var InsertOpenParen$0 = $TV($EXPECT($L0, fail, 'InsertOpenParen ""'), function($skip, $loc, $0, $1) {
11232
11489
  return { $loc, token: "(" };
11233
11490
  });
11234
11491
  function InsertOpenParen(state) {
@@ -11249,7 +11506,7 @@ ${input.slice(result.pos)}
11249
11506
  return result;
11250
11507
  }
11251
11508
  }
11252
- var InsertCloseParen$0 = $TV($EXPECT($L14, fail, 'InsertCloseParen ""'), function($skip, $loc, $0, $1) {
11509
+ var InsertCloseParen$0 = $TV($EXPECT($L0, fail, 'InsertCloseParen ""'), function($skip, $loc, $0, $1) {
11253
11510
  return { $loc, token: ")" };
11254
11511
  });
11255
11512
  function InsertCloseParen(state) {
@@ -11270,7 +11527,7 @@ ${input.slice(result.pos)}
11270
11527
  return result;
11271
11528
  }
11272
11529
  }
11273
- var InsertOpenBrace$0 = $TV($EXPECT($L14, fail, 'InsertOpenBrace ""'), function($skip, $loc, $0, $1) {
11530
+ var InsertOpenBrace$0 = $TV($EXPECT($L0, fail, 'InsertOpenBrace ""'), function($skip, $loc, $0, $1) {
11274
11531
  return [{ $loc, token: " " }, { $loc, token: "{" }];
11275
11532
  });
11276
11533
  function InsertOpenBrace(state) {
@@ -11291,7 +11548,28 @@ ${input.slice(result.pos)}
11291
11548
  return result;
11292
11549
  }
11293
11550
  }
11294
- var InsertCloseBrace$0 = $TV($EXPECT($L14, fail, 'InsertCloseBrace ""'), function($skip, $loc, $0, $1) {
11551
+ var InsertInlineOpenBrace$0 = $TV($EXPECT($L0, fail, 'InsertInlineOpenBrace ""'), function($skip, $loc, $0, $1) {
11552
+ return [{ $loc, token: "{" }];
11553
+ });
11554
+ function InsertInlineOpenBrace(state) {
11555
+ if (state.events) {
11556
+ const result = state.events.enter?.("InsertInlineOpenBrace", state);
11557
+ if (result)
11558
+ return result.cache;
11559
+ }
11560
+ if (state.tokenize) {
11561
+ const result = $TOKEN("InsertInlineOpenBrace", state, InsertInlineOpenBrace$0(state));
11562
+ if (state.events)
11563
+ state.events.exit?.("InsertInlineOpenBrace", state, result);
11564
+ return result;
11565
+ } else {
11566
+ const result = InsertInlineOpenBrace$0(state);
11567
+ if (state.events)
11568
+ state.events.exit?.("InsertInlineOpenBrace", state, result);
11569
+ return result;
11570
+ }
11571
+ }
11572
+ var InsertCloseBrace$0 = $TV($EXPECT($L0, fail, 'InsertCloseBrace ""'), function($skip, $loc, $0, $1) {
11295
11573
  return { $loc, token: "}" };
11296
11574
  });
11297
11575
  function InsertCloseBrace(state) {
@@ -11312,7 +11590,7 @@ ${input.slice(result.pos)}
11312
11590
  return result;
11313
11591
  }
11314
11592
  }
11315
- var InsertConst$0 = $TV($EXPECT($L14, fail, 'InsertConst ""'), function($skip, $loc, $0, $1) {
11593
+ var InsertConst$0 = $TV($EXPECT($L0, fail, 'InsertConst ""'), function($skip, $loc, $0, $1) {
11316
11594
  return { $loc, token: "const " };
11317
11595
  });
11318
11596
  function InsertConst(state) {
@@ -11333,7 +11611,7 @@ ${input.slice(result.pos)}
11333
11611
  return result;
11334
11612
  }
11335
11613
  }
11336
- var InsertReadonly$0 = $TV($EXPECT($L14, fail, 'InsertReadonly ""'), function($skip, $loc, $0, $1) {
11614
+ var InsertReadonly$0 = $TV($EXPECT($L0, fail, 'InsertReadonly ""'), function($skip, $loc, $0, $1) {
11337
11615
  return { ts: true, children: [{ $loc, token: "readonly " }] };
11338
11616
  });
11339
11617
  function InsertReadonly(state) {
@@ -11354,7 +11632,7 @@ ${input.slice(result.pos)}
11354
11632
  return result;
11355
11633
  }
11356
11634
  }
11357
- var InsertNewline$0 = $TV($EXPECT($L14, fail, 'InsertNewline ""'), function($skip, $loc, $0, $1) {
11635
+ var InsertNewline$0 = $TV($EXPECT($L0, fail, 'InsertNewline ""'), function($skip, $loc, $0, $1) {
11358
11636
  return "\n";
11359
11637
  });
11360
11638
  function InsertNewline(state) {
@@ -11375,7 +11653,7 @@ ${input.slice(result.pos)}
11375
11653
  return result;
11376
11654
  }
11377
11655
  }
11378
- var InsertIndent$0 = $TV($EXPECT($L14, fail, 'InsertIndent ""'), function($skip, $loc, $0, $1) {
11656
+ var InsertIndent$0 = $TV($EXPECT($L0, fail, 'InsertIndent ""'), function($skip, $loc, $0, $1) {
11379
11657
  return module.currentIndent.token;
11380
11658
  });
11381
11659
  function InsertIndent(state) {
@@ -11396,7 +11674,7 @@ ${input.slice(result.pos)}
11396
11674
  return result;
11397
11675
  }
11398
11676
  }
11399
- var InsertSpace$0 = $TV($EXPECT($L14, fail, 'InsertSpace ""'), function($skip, $loc, $0, $1) {
11677
+ var InsertSpace$0 = $TV($EXPECT($L0, fail, 'InsertSpace ""'), function($skip, $loc, $0, $1) {
11400
11678
  return { $loc, token: " " };
11401
11679
  });
11402
11680
  function InsertSpace(state) {
@@ -11417,7 +11695,7 @@ ${input.slice(result.pos)}
11417
11695
  return result;
11418
11696
  }
11419
11697
  }
11420
- var InsertDot$0 = $TV($EXPECT($L14, fail, 'InsertDot ""'), function($skip, $loc, $0, $1) {
11698
+ var InsertDot$0 = $TV($EXPECT($L0, fail, 'InsertDot ""'), function($skip, $loc, $0, $1) {
11421
11699
  return { $loc, token: "." };
11422
11700
  });
11423
11701
  function InsertDot(state) {
@@ -11438,7 +11716,7 @@ ${input.slice(result.pos)}
11438
11716
  return result;
11439
11717
  }
11440
11718
  }
11441
- var InsertBreak$0 = $TV($EXPECT($L14, fail, 'InsertBreak ""'), function($skip, $loc, $0, $1) {
11719
+ var InsertBreak$0 = $TV($EXPECT($L0, fail, 'InsertBreak ""'), function($skip, $loc, $0, $1) {
11442
11720
  return { $loc, token: ";break;" };
11443
11721
  });
11444
11722
  function InsertBreak(state) {
@@ -11459,7 +11737,7 @@ ${input.slice(result.pos)}
11459
11737
  return result;
11460
11738
  }
11461
11739
  }
11462
- var CoffeeBinaryExistentialEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeBinaryExistentialEnabled ""'), function($skip, $loc, $0, $1) {
11740
+ var CoffeeBinaryExistentialEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeBinaryExistentialEnabled ""'), function($skip, $loc, $0, $1) {
11463
11741
  if (module.config.coffeeBinaryExistential)
11464
11742
  return;
11465
11743
  return $skip;
@@ -11482,7 +11760,7 @@ ${input.slice(result.pos)}
11482
11760
  return result;
11483
11761
  }
11484
11762
  }
11485
- var CoffeeBooleansEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeBooleansEnabled ""'), function($skip, $loc, $0, $1) {
11763
+ var CoffeeBooleansEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeBooleansEnabled ""'), function($skip, $loc, $0, $1) {
11486
11764
  if (module.config.coffeeBooleans)
11487
11765
  return;
11488
11766
  return $skip;
@@ -11505,7 +11783,7 @@ ${input.slice(result.pos)}
11505
11783
  return result;
11506
11784
  }
11507
11785
  }
11508
- var CoffeeClassesEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeClassesEnabled ""'), function($skip, $loc, $0, $1) {
11786
+ var CoffeeClassesEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeClassesEnabled ""'), function($skip, $loc, $0, $1) {
11509
11787
  if (module.config.coffeeClasses)
11510
11788
  return;
11511
11789
  return $skip;
@@ -11528,7 +11806,7 @@ ${input.slice(result.pos)}
11528
11806
  return result;
11529
11807
  }
11530
11808
  }
11531
- var CoffeeCommentEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeCommentEnabled ""'), function($skip, $loc, $0, $1) {
11809
+ var CoffeeCommentEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeCommentEnabled ""'), function($skip, $loc, $0, $1) {
11532
11810
  if (module.config.coffeeComment)
11533
11811
  return;
11534
11812
  return $skip;
@@ -11551,7 +11829,7 @@ ${input.slice(result.pos)}
11551
11829
  return result;
11552
11830
  }
11553
11831
  }
11554
- var CoffeeDoEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeDoEnabled ""'), function($skip, $loc, $0, $1) {
11832
+ var CoffeeDoEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeDoEnabled ""'), function($skip, $loc, $0, $1) {
11555
11833
  if (module.config.coffeeDo)
11556
11834
  return;
11557
11835
  return $skip;
@@ -11574,7 +11852,7 @@ ${input.slice(result.pos)}
11574
11852
  return result;
11575
11853
  }
11576
11854
  }
11577
- var CoffeeForLoopsEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeForLoopsEnabled ""'), function($skip, $loc, $0, $1) {
11855
+ var CoffeeForLoopsEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeForLoopsEnabled ""'), function($skip, $loc, $0, $1) {
11578
11856
  if (module.config.coffeeForLoops)
11579
11857
  return;
11580
11858
  return $skip;
@@ -11597,7 +11875,7 @@ ${input.slice(result.pos)}
11597
11875
  return result;
11598
11876
  }
11599
11877
  }
11600
- var CoffeeInterpolationEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeInterpolationEnabled ""'), function($skip, $loc, $0, $1) {
11878
+ var CoffeeInterpolationEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeInterpolationEnabled ""'), function($skip, $loc, $0, $1) {
11601
11879
  if (module.config.coffeeInterpolation)
11602
11880
  return;
11603
11881
  return $skip;
@@ -11620,7 +11898,7 @@ ${input.slice(result.pos)}
11620
11898
  return result;
11621
11899
  }
11622
11900
  }
11623
- var CoffeeIsntEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeIsntEnabled ""'), function($skip, $loc, $0, $1) {
11901
+ var CoffeeIsntEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeIsntEnabled ""'), function($skip, $loc, $0, $1) {
11624
11902
  if (module.config.coffeeIsnt)
11625
11903
  return;
11626
11904
  return $skip;
@@ -11643,7 +11921,7 @@ ${input.slice(result.pos)}
11643
11921
  return result;
11644
11922
  }
11645
11923
  }
11646
- var CoffeeLineContinuationEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeLineContinuationEnabled ""'), function($skip, $loc, $0, $1) {
11924
+ var CoffeeLineContinuationEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeLineContinuationEnabled ""'), function($skip, $loc, $0, $1) {
11647
11925
  if (module.config.coffeeLineContinuation)
11648
11926
  return;
11649
11927
  return $skip;
@@ -11666,7 +11944,7 @@ ${input.slice(result.pos)}
11666
11944
  return result;
11667
11945
  }
11668
11946
  }
11669
- var CoffeeNotEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeNotEnabled ""'), function($skip, $loc, $0, $1) {
11947
+ var CoffeeNotEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeNotEnabled ""'), function($skip, $loc, $0, $1) {
11670
11948
  if (module.config.coffeeNot)
11671
11949
  return;
11672
11950
  return $skip;
@@ -11689,7 +11967,7 @@ ${input.slice(result.pos)}
11689
11967
  return result;
11690
11968
  }
11691
11969
  }
11692
- var CoffeeOfEnabled$0 = $TV($EXPECT($L14, fail, 'CoffeeOfEnabled ""'), function($skip, $loc, $0, $1) {
11970
+ var CoffeeOfEnabled$0 = $TV($EXPECT($L0, fail, 'CoffeeOfEnabled ""'), function($skip, $loc, $0, $1) {
11693
11971
  if (module.config.coffeeOf)
11694
11972
  return;
11695
11973
  return $skip;
@@ -11712,7 +11990,7 @@ ${input.slice(result.pos)}
11712
11990
  return result;
11713
11991
  }
11714
11992
  }
11715
- var Reset$0 = $TV($EXPECT($L14, fail, 'Reset ""'), function($skip, $loc, $0, $1) {
11993
+ var Reset$0 = $TV($EXPECT($L0, fail, 'Reset ""'), function($skip, $loc, $0, $1) {
11716
11994
  module.indentLevels = [{
11717
11995
  level: 0,
11718
11996
  token: ""
@@ -11755,7 +12033,8 @@ ${input.slice(result.pos)}
11755
12033
  return spliceRef;
11756
12034
  spliceRef = {
11757
12035
  type: "Ref",
11758
- base: "splice"
12036
+ base: "splice",
12037
+ id: "splice"
11759
12038
  };
11760
12039
  return spliceRef;
11761
12040
  };
@@ -11764,7 +12043,8 @@ ${input.slice(result.pos)}
11764
12043
  return indexOfRef;
11765
12044
  indexOfRef = {
11766
12045
  type: "Ref",
11767
- base: "indexOf"
12046
+ base: "indexOf",
12047
+ id: "indexOf"
11768
12048
  };
11769
12049
  const typeSuffix = {
11770
12050
  ts: true,
@@ -11778,7 +12058,8 @@ ${input.slice(result.pos)}
11778
12058
  return hasPropRef;
11779
12059
  hasPropRef = {
11780
12060
  type: "Ref",
11781
- base: "hasProp"
12061
+ base: "hasProp",
12062
+ id: "hasProp"
11782
12063
  };
11783
12064
  const typeSuffix = {
11784
12065
  ts: true,
@@ -11842,7 +12123,7 @@ ${input.slice(result.pos)}
11842
12123
  return result;
11843
12124
  }
11844
12125
  }
11845
- var Init$0 = $TS($S($E(Shebang), $Q(DirectivePrologue), $EXPECT($L14, fail, 'Init ""')), function($skip, $loc, $0, $1, $2, $3) {
12126
+ var Init$0 = $TS($S($E(Shebang), $Q(DirectivePrologue), $EXPECT($L0, fail, 'Init ""')), function($skip, $loc, $0, $1, $2, $3) {
11846
12127
  var directives = $2;
11847
12128
  directives.forEach((directive) => {
11848
12129
  if (directive.type === "CivetPrologue") {
@@ -11889,7 +12170,8 @@ ${input.slice(result.pos)}
11889
12170
  function expressionizeIteration(exp) {
11890
12171
  const resultsRef = {
11891
12172
  type: "Ref",
11892
- base: "results"
12173
+ base: "results",
12174
+ id: "results"
11893
12175
  };
11894
12176
  insertPush(exp.block, resultsRef);
11895
12177
  exp.children = ["(", resultsRef, "=>{", ...exp.children, "; return ", resultsRef, "})([])"];
@@ -11897,7 +12179,8 @@ ${input.slice(result.pos)}
11897
12179
  function wrapIterationReturningResults(statement, outerRef) {
11898
12180
  const resultsRef = {
11899
12181
  type: "Ref",
11900
- base: "results"
12182
+ base: "results",
12183
+ id: "results"
11901
12184
  };
11902
12185
  const declaration = {
11903
12186
  type: "Declaration",
@@ -11926,6 +12209,7 @@ ${input.slice(result.pos)}
11926
12209
  case "BlockStatement":
11927
12210
  insertPush(node.expressions[node.expressions.length - 1], ref);
11928
12211
  return;
12212
+ case "ObjectBindingPattern":
11929
12213
  case "ObjectExpression":
11930
12214
  module.insertTrimmingSpace(node.children[0], "");
11931
12215
  node.children.unshift(ref, ".push(");
@@ -11981,7 +12265,8 @@ ${input.slice(result.pos)}
11981
12265
  return;
11982
12266
  case "TryStatement":
11983
12267
  insertPush(exp.children[1], ref);
11984
- insertPush(exp.children[2][3], ref);
12268
+ if (exp.children[2])
12269
+ insertPush(exp.children[2][2], ref);
11985
12270
  return;
11986
12271
  }
11987
12272
  node.splice(1, 0, ref, ".push(");
@@ -12000,6 +12285,7 @@ ${input.slice(result.pos)}
12000
12285
  case "BlockStatement":
12001
12286
  insertReturn(node.expressions[node.expressions.length - 1]);
12002
12287
  return;
12288
+ case "ObjectBindingPattern":
12003
12289
  case "ObjectExpression":
12004
12290
  module.insertTrimmingSpace(node.children[0], "");
12005
12291
  node.children.unshift("return ");
@@ -12055,7 +12341,8 @@ ${input.slice(result.pos)}
12055
12341
  return;
12056
12342
  case "TryStatement":
12057
12343
  insertReturn(exp.children[1]);
12058
- insertReturn(exp.children[2][3]);
12344
+ if (exp.children[2])
12345
+ insertReturn(exp.children[2][3]);
12059
12346
  return;
12060
12347
  }
12061
12348
  node.splice(1, 0, "return ");
@@ -12075,13 +12362,20 @@ ${input.slice(result.pos)}
12075
12362
  let i = 2;
12076
12363
  while (i < expandedOps.length) {
12077
12364
  const op = expandedOps[i];
12078
- if (op.ref) {
12365
+ if (op.special) {
12079
12366
  let [a, wsOp, op2, wsB, b] = expandedOps.slice(i - 2, i + 3);
12080
- wsOp = module.insertTrimmingSpace(wsOp, "");
12081
- wsB = module.insertTrimmingSpace(wsB, "");
12367
+ let children;
12368
+ if (op2.ref) {
12369
+ wsOp = module.insertTrimmingSpace(wsOp, "");
12370
+ wsB = module.insertTrimmingSpace(wsB, "");
12371
+ children = [wsOp, op2.ref, ".call(", wsB, b, ", ", a, ")", op2.suffix];
12372
+ } else if (op2.token === "instanceof" || op2.token === "in") {
12373
+ children = ["!(", a, wsOp, op2, wsB, b, ")"];
12374
+ } else {
12375
+ throw new Error("Unknown operator: " + JSON.stringify(op2));
12376
+ }
12082
12377
  expandedOps.splice(i - 2, 5, {
12083
- type: "Call",
12084
- children: [wsOp, op2.ref, ".call(", wsB, b, ", ", a, ")", op2.suffix]
12378
+ children
12085
12379
  });
12086
12380
  } else {
12087
12381
  i += 4;
@@ -12288,7 +12582,6 @@ ${input.slice(result.pos)}
12288
12582
  return nodes;
12289
12583
  }
12290
12584
  function processParams(f) {
12291
- processAtParams(f);
12292
12585
  const { parameters, block } = f;
12293
12586
  if (!block)
12294
12587
  return;
@@ -12302,44 +12595,22 @@ ${input.slice(result.pos)}
12302
12595
  } else {
12303
12596
  indent = expressions[0][0];
12304
12597
  }
12305
- const thisAssignments = [];
12306
- const splices = [];
12307
- function insertRestSplices(s, p, thisAssignments2) {
12308
- gatherRecursiveAll(s, (n) => n.blockPrefix).forEach(({ blockPrefix: blockPrefix2 }) => {
12309
- p.push([indent, blockPrefix2, ";\n"]);
12310
- gatherRecursiveAll(blockPrefix2, (n) => n.type === "AtBinding").map(({ ref }) => {
12311
- const { base: name } = ref;
12312
- thisAssignments2.push([indent, [`this.${name} = `, ref], ";\n"]);
12313
- });
12314
- insertRestSplices(blockPrefix2, p, thisAssignments2);
12315
- });
12316
- return p;
12317
- }
12318
- insertRestSplices(parameters, splices, thisAssignments);
12319
- expressions.unshift(...splices, ...thisAssignments);
12320
- }
12321
- function processAtParams(f) {
12322
- const { parameters, block } = f;
12323
- if (!block)
12324
- return;
12325
- const { expressions } = block;
12326
- if (!expressions)
12327
- return;
12328
- let indent;
12329
- if (expressions.length === 0) {
12330
- indent = "";
12331
- } else {
12332
- indent = expressions[0][0];
12333
- }
12334
- const thisAssignments = gatherRecursiveAll(parameters, (n) => n.type === "AtBinding").map(({ ref }) => {
12335
- const { base: name } = ref;
12336
- return [indent, [`this.${name} = `, ref], ";\n"];
12337
- });
12338
- block.expressions.unshift(...thisAssignments);
12598
+ const [splices, thisAssignments] = gatherBindingCode(parameters);
12599
+ const prefix = splices.map((s) => ["let ", s]).concat(thisAssignments).map((s) => [indent, s, ";\n"]);
12600
+ expressions.unshift(...prefix);
12339
12601
  }
12340
- function adjustAtBindings(statements) {
12602
+ function adjustAtBindings(statements, asThis = false) {
12341
12603
  gatherRecursiveAll(statements, (n) => n.type === "AtBindingProperty").forEach((binding) => {
12342
12604
  const { ref } = binding;
12605
+ if (asThis) {
12606
+ const atBinding = binding.children[0];
12607
+ atBinding.children.pop();
12608
+ atBinding.type = void 0;
12609
+ binding.children.unshift(ref.id, ": this.", ref.base);
12610
+ binding.type = "Property";
12611
+ binding.ref = void 0;
12612
+ return;
12613
+ }
12343
12614
  if (ref.names[0] !== ref.base) {
12344
12615
  binding.children.unshift(ref.base, ": ");
12345
12616
  }
@@ -12379,16 +12650,21 @@ ${input.slice(result.pos)}
12379
12650
  });
12380
12651
  }
12381
12652
  }
12653
+ function processBindingPatternLHS(lhs, tail) {
12654
+ adjustAtBindings(lhs, true);
12655
+ const [splices, thisAssignments] = module.gatherBindingCode(lhs);
12656
+ tail.push(...splices.map((s) => [", ", s]), ...thisAssignments.map((a) => [", ", a]));
12657
+ }
12382
12658
  function processAssignments(statements) {
12383
12659
  gatherRecursiveAll(statements, (n) => n.type === "AssignmentExpression" && n.names === null).forEach((exp) => {
12384
- let $02 = exp.children, [$12, $22] = $02, tail = [], i = 0, len = $12.length;
12660
+ let { lhs: $12, exp: $22 } = exp, tail = [], i = 0, len = $12.length;
12385
12661
  let wrapped = false;
12386
12662
  while (i < len) {
12387
12663
  const lastAssignment = $12[i++];
12388
12664
  const [, lhs, , op] = lastAssignment;
12389
12665
  if (op.token !== "=")
12390
12666
  continue;
12391
- if (lhs.type === "ObjectExpression") {
12667
+ if (lhs.type === "ObjectExpression" || lhs.type === "ObjectBindingPattern") {
12392
12668
  if (!wrapped) {
12393
12669
  wrapped = true;
12394
12670
  lhs.children.splice(0, 0, "(");
@@ -12427,33 +12703,8 @@ ${input.slice(result.pos)}
12427
12703
  return;
12428
12704
  }
12429
12705
  }
12430
- } else if (lhs.type === "ObjectExpression") {
12431
- const spreadIndex = lhs.children.findIndex((child) => child.type === "SpreadProperty"), hasSpread = spreadIndex >= 0;
12432
- if (hasSpread) {
12433
- const len2 = lhs.children.length, after = lhs.children.splice(spreadIndex + 1, len2 - spreadIndex - 2);
12434
- if (after.length) {
12435
- if (after.some((child) => child.type === "SpreadProperty")) {
12436
- throw new Error("Cannot have multiple spread properties in object destructuring");
12437
- }
12438
- const lastAfterChildren = after[after.length - 1].children, afterDelimiter = lastAfterChildren.pop(), spread = lhs.children[spreadIndex], spreadDelimiter = spread.children.pop();
12439
- spread.children.push(afterDelimiter);
12440
- lastAfterChildren.push(spreadDelimiter);
12441
- lhs.children.splice(spreadIndex, 0, ...after);
12442
- }
12443
- }
12444
- } else if (lhs.type === "ArrayExpression") {
12445
- const spreadIndex = lhs.children.findIndex((child) => child.type === "SpreadElement"), hasSpread = spreadIndex >= 0;
12446
- if (hasSpread) {
12447
- const len2 = lhs.children.length, after = lhs.children.splice(spreadIndex + 1, len2 - spreadIndex - 2);
12448
- if (after.length) {
12449
- if (after.some((child) => child.type === "SpreadElement")) {
12450
- throw new Error("Cannot have multiple spread elements in array destructuring");
12451
- }
12452
- const spread = lhs.children[spreadIndex], spreadDelimiter = spread.children.pop();
12453
- const spliceRef = module.getSpliceRef();
12454
- tail.push(["\n[", after, "] = ", spliceRef, ".call(", spread.names[0], ", -", after.length.toString(), ")"]);
12455
- }
12456
- }
12706
+ } else if (lhs.type === "ObjectBindingPattern" || lhs.type === "ArrayBindingPattern") {
12707
+ processBindingPatternLHS(lhs, tail);
12457
12708
  }
12458
12709
  }
12459
12710
  i--;
@@ -12477,6 +12728,24 @@ ${input.slice(result.pos)}
12477
12728
  module.prelude.push(["", ["const ", spliceRef, typeSuffix, " = [].splice", asAny, "\n"]]);
12478
12729
  }
12479
12730
  }
12731
+ module.attachPostfixStatementAsExpression = function(exp, post) {
12732
+ let clause;
12733
+ switch (post[1].type) {
12734
+ case "IterationStatement":
12735
+ case "ForStatement":
12736
+ clause = module.addPostfixStatement(exp, ...post);
12737
+ return {
12738
+ type: "IterationExpression",
12739
+ children: [clause],
12740
+ block: clause.block
12741
+ };
12742
+ case "IfStatement":
12743
+ clause = module.expressionizeIfClause(post[1], exp);
12744
+ return clause;
12745
+ default:
12746
+ throw new Error("Unknown postfix statement");
12747
+ }
12748
+ };
12480
12749
  module.processProgram = function(statements) {
12481
12750
  processAssignments(statements);
12482
12751
  processFunctions(statements);
@@ -12535,16 +12804,13 @@ ${input.slice(result.pos)}
12535
12804
  return scopes.some((s) => s.has(name));
12536
12805
  }
12537
12806
  function findAssignments(statements2, decs2) {
12538
- const assignmentStatements = gatherNodes(statements2, (node) => {
12807
+ let assignmentStatements2 = gatherNodes(statements2, (node) => {
12539
12808
  return node.type === "AssignmentExpression";
12540
12809
  });
12541
- const undeclaredIdentifiers = assignmentStatements.flatMap((a) => {
12542
- return a.names;
12543
- });
12544
- return undeclaredIdentifiers.filter((x, i, a) => {
12545
- if (!hasDec(x))
12546
- return a.indexOf(x) === i;
12547
- });
12810
+ if (assignmentStatements2.length) {
12811
+ assignmentStatements2 = assignmentStatements2.concat(findAssignments(assignmentStatements2.map((s) => s.children), decs2));
12812
+ }
12813
+ return assignmentStatements2;
12548
12814
  }
12549
12815
  if (!pushVar) {
12550
12816
  pushVar = function(name) {
@@ -12555,7 +12821,14 @@ ${input.slice(result.pos)}
12555
12821
  const decs = findDecs(statements);
12556
12822
  scopes.push(decs);
12557
12823
  const varIds = [];
12558
- findAssignments(statements, scopes).forEach(pushVar);
12824
+ const assignmentStatements = findAssignments(statements, scopes);
12825
+ const undeclaredIdentifiers = assignmentStatements.flatMap((a) => {
12826
+ return a.names;
12827
+ });
12828
+ undeclaredIdentifiers.filter((x, i, a) => {
12829
+ if (!hasDec(x))
12830
+ return a.indexOf(x) === i;
12831
+ }).forEach(pushVar);
12559
12832
  const fnNodes = gatherNodes(statements, (s) => s.type === "FunctionExpression");
12560
12833
  const forNodes = gatherNodes(statements, (s) => s.type === "ForStatement");
12561
12834
  const blockNodes = new Set(gatherNodes(statements, (s) => s.type === "BlockStatement"));
@@ -12581,6 +12854,25 @@ ${input.slice(result.pos)}
12581
12854
  statements.unshift([indent, "var ", varIds.join(", "), "\n"]);
12582
12855
  }
12583
12856
  }
12857
+ function gatherBindingCode(statements) {
12858
+ const thisAssignments = [];
12859
+ const splices = [];
12860
+ function insertRestSplices(s, p, thisAssignments2) {
12861
+ gatherRecursiveAll(s, (n) => n.blockPrefix || n.type === "AtBinding").forEach((n) => {
12862
+ if (n.type === "AtBinding") {
12863
+ const { ref } = n, { id } = ref;
12864
+ thisAssignments2.push([`this.${id} = `, ref]);
12865
+ return;
12866
+ }
12867
+ const { blockPrefix } = n;
12868
+ p.push(blockPrefix);
12869
+ insertRestSplices(blockPrefix, p, thisAssignments2);
12870
+ });
12871
+ }
12872
+ insertRestSplices(statements, splices, thisAssignments);
12873
+ return [splices, thisAssignments];
12874
+ }
12875
+ module.gatherBindingCode = gatherBindingCode;
12584
12876
  return $0;
12585
12877
  });
12586
12878
  function Init(state) {
@@ -12601,7 +12893,7 @@ ${input.slice(result.pos)}
12601
12893
  return result;
12602
12894
  }
12603
12895
  }
12604
- var Indent$0 = $TV($Q($C($EXPECT($L157, fail, 'Indent " "'), $EXPECT($L158, fail, 'Indent "\\\\t"'))), function($skip, $loc, $0, $1) {
12896
+ var Indent$0 = $TV($Q($C($EXPECT($L156, fail, 'Indent " "'), $EXPECT($L157, fail, 'Indent "\\\\t"'))), function($skip, $loc, $0, $1) {
12605
12897
  const level = $1.length;
12606
12898
  return {
12607
12899
  $loc,
@@ -12726,7 +13018,7 @@ ${input.slice(result.pos)}
12726
13018
  return result;
12727
13019
  }
12728
13020
  }
12729
- var PopIndent$0 = $TV($EXPECT($L14, fail, 'PopIndent ""'), function($skip, $loc, $0, $1) {
13021
+ var PopIndent$0 = $TV($EXPECT($L0, fail, 'PopIndent ""'), function($skip, $loc, $0, $1) {
12730
13022
  if (module.verbose) {
12731
13023
  console.log("popping indent", module.indentLevels[module.indentLevels.length - 1], "->", module.indentLevels[module.indentLevels.length - 2]);
12732
13024
  }
@@ -13290,6 +13582,9 @@ ${"//#"} sourceMappingURL=data:application/json;base64,${base64Encode(JSON.strin
13290
13582
  case "NestedImplicitPropertyDefinitions":
13291
13583
  case "NestedBlockStatement":
13292
13584
  case "NestedInterfaceProperty":
13585
+ case "IndentedApplicationAllowed":
13586
+ case "ExpressionWithIndentedApplicationSuppressed":
13587
+ case "SuppressIndentedApplication":
13293
13588
  case "AssignmentExpressionTail":
13294
13589
  case "AssignmentExpression":
13295
13590
  case "ExtendedExpression":