@putout/babel 5.0.4 → 5.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bundle/index.js CHANGED
@@ -136,509 +136,6 @@ var require_picocolors = __commonJS({
136
136
  },
137
137
  });
138
138
 
139
- // ../babel-babel/node_modules/js-tokens/index.js
140
- var require_js_tokens = __commonJS({
141
- '../babel-babel/node_modules/js-tokens/index.js'(exports2, module2) {
142
- var Identifier3;
143
- var JSXIdentifier3;
144
- var JSXPunctuator;
145
- var JSXString;
146
- var JSXText3;
147
- var KeywordsWithExpressionAfter;
148
- var KeywordsWithNoLineTerminatorAfter;
149
- var LineTerminatorSequence;
150
- var MultiLineComment;
151
- var Newline;
152
- var NumericLiteral4;
153
- var Punctuator;
154
- var RegularExpressionLiteral;
155
- var SingleLineComment;
156
- var StringLiteral4;
157
- var Template;
158
- var TokensNotPrecedingObjectLiteral;
159
- var TokensPrecedingExpression;
160
- var WhiteSpace;
161
- var jsTokens2;
162
-
163
- RegularExpressionLiteral = /\/(?![*\/])(?:\[(?:(?![\]\\]).|\\.)*\]|(?![\/\\]).|\\.)*(\/[$_\u200C\u200D\p{ID_Continue}]*|\\)?/yu;
164
- Punctuator = /--|\+\+|=>|\.{3}|\??\.(?!\d)|(?:&&|\|\||\?\?|[+\-%&|^]|\*{1,2}|<{1,2}|>{1,3}|!=?|={1,2}|\/(?![\/*]))=?|[?~,:;[\](){}]/y;
165
- Identifier3 = /(\x23?)(?=[$_\p{ID_Start}\\])(?:[$_\u200C\u200D\p{ID_Continue}]|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]+\})+/yu;
166
- StringLiteral4 = /(['"])(?:(?!\1)[^\\\n\r]|\\(?:\r\n|[^]))*(\1)?/y;
167
- NumericLiteral4 = /(?:0[xX][\da-fA-F](?:_?[\da-fA-F])*|0[oO][0-7](?:_?[0-7])*|0[bB][01](?:_?[01])*)n?|0n|[1-9](?:_?\d)*n|(?:(?:0(?!\d)|0\d*[89]\d*|[1-9](?:_?\d)*)(?:\.(?:\d(?:_?\d)*)?)?|\.\d(?:_?\d)*)(?:[eE][+-]?\d(?:_?\d)*)?|0[0-7]+/y;
168
- Template = /[`}](?:[^`\\$]|\\[^]|\$(?!\{))*(`|\$\{)?/y;
169
- WhiteSpace = /[\t\v\f\ufeff\p{Zs}]+/yu;
170
- LineTerminatorSequence = /\r?\n|[\r\u2028\u2029]/y;
171
- MultiLineComment = /\/\*(?:[^*]|\*(?!\/))*(\*\/)?/y;
172
- SingleLineComment = /\/\/.*/y;
173
- JSXPunctuator = /[<>.:={}]|\/(?![\/*])/y;
174
- JSXIdentifier3 = /[$_\p{ID_Start}][$_\u200C\u200D\p{ID_Continue}-]*/yu;
175
- JSXString = /(['"])(?:(?!\1)[^])*(\1)?/y;
176
- JSXText3 = /[^<>{}]+/y;
177
- TokensPrecedingExpression = /^(?:[\/+-]|\.{3}|\?(?:InterpolationIn(?:JSX|Template)|NoLineTerminatorHere|NonExpressionParenEnd|UnaryIncDec))?$|[{}([,;<>=*%&|^!~?:]$/;
178
- TokensNotPrecedingObjectLiteral = /^(?:=>|[;\]){}]|else|\?(?:NoLineTerminatorHere|NonExpressionParenEnd))?$/;
179
- KeywordsWithExpressionAfter = /^(?:await|case|default|delete|do|else|instanceof|new|return|throw|typeof|void|yield)$/;
180
- KeywordsWithNoLineTerminatorAfter = /^(?:return|throw|yield)$/;
181
- Newline = RegExp(LineTerminatorSequence.source);
182
- module2.exports =
183
- jsTokens2 = function*(input, {jsx: jsx2 = false} = {}) {
184
- var braces,
185
- firstCodePoint,
186
- isExpression4,
187
- lastIndex,
188
- lastSignificantToken,
189
- length,
190
- match,
191
- mode,
192
- nextLastIndex,
193
- nextLastSignificantToken,
194
- parenNesting,
195
- postfixIncDec,
196
- punctuator,
197
- stack;
198
-
199
- ({length} = input);
200
- lastIndex = 0;
201
- lastSignificantToken = '';
202
- stack = [{
203
- tag: 'JS',
204
- }];
205
- braces = [];
206
- parenNesting = 0;
207
- postfixIncDec = false;
208
- while (lastIndex < length) {
209
- mode = stack[stack.length - 1];
210
- switch(mode.tag) {
211
- case 'JS':
212
- case 'JSNonExpressionParen':
213
- case 'InterpolationInTemplate':
214
- case 'InterpolationInJSX':
215
- if (input[lastIndex] === '/' && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken))) {
216
- RegularExpressionLiteral.lastIndex = lastIndex;
217
-
218
- if (match = RegularExpressionLiteral.exec(input)) {
219
- lastIndex = RegularExpressionLiteral.lastIndex;
220
- lastSignificantToken = match[0];
221
- postfixIncDec = true;
222
- yield {
223
- type: 'RegularExpressionLiteral',
224
- value: match[0],
225
- closed: match[1] !== void 0 && match[1] !== '\\',
226
- };
227
- continue;
228
- }
229
- }
230
-
231
- Punctuator.lastIndex = lastIndex;
232
-
233
- if (match = Punctuator.exec(input)) {
234
- punctuator = match[0];
235
- nextLastIndex = Punctuator.lastIndex;
236
- nextLastSignificantToken = punctuator;
237
- switch(punctuator) {
238
- case '(':
239
- if (lastSignificantToken === '?NonExpressionParenKeyword') {
240
- stack.push({
241
- tag: 'JSNonExpressionParen',
242
- nesting: parenNesting,
243
- });
244
- }
245
-
246
- parenNesting++;
247
- postfixIncDec = false;
248
- break;
249
-
250
- case ')':
251
- parenNesting--;
252
- postfixIncDec = true;
253
-
254
- if (mode.tag === 'JSNonExpressionParen' && parenNesting === mode.nesting) {
255
- stack.pop();
256
- nextLastSignificantToken = '?NonExpressionParenEnd';
257
- postfixIncDec = false;
258
- }
259
-
260
- break;
261
-
262
- case '{':
263
- Punctuator.lastIndex = 0;
264
- isExpression4 = !TokensNotPrecedingObjectLiteral.test(lastSignificantToken) && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken));
265
- braces.push(isExpression4);
266
- postfixIncDec = false;
267
- break;
268
-
269
- case '}':
270
- switch(mode.tag) {
271
- case 'InterpolationInTemplate':
272
- if (braces.length === mode.nesting) {
273
- Template.lastIndex = lastIndex;
274
- match = Template.exec(input);
275
- lastIndex = Template.lastIndex;
276
- lastSignificantToken = match[0];
277
-
278
- if (match[1] === '${') {
279
- lastSignificantToken = '?InterpolationInTemplate';
280
- postfixIncDec = false;
281
- yield {
282
- type: 'TemplateMiddle',
283
- value: match[0],
284
- };
285
- } else {
286
- stack.pop();
287
- postfixIncDec = true;
288
- yield {
289
- type: 'TemplateTail',
290
- value: match[0],
291
- closed: match[1] === '`',
292
- };
293
- }
294
-
295
- continue;
296
- }
297
-
298
- break;
299
-
300
- case 'InterpolationInJSX':
301
- if (braces.length === mode.nesting) {
302
- stack.pop();
303
- lastIndex += 1;
304
- lastSignificantToken = '}';
305
- yield {
306
- type: 'JSXPunctuator',
307
- value: '}',
308
- };
309
- continue;
310
- }
311
- }
312
-
313
- postfixIncDec = braces.pop();
314
- nextLastSignificantToken = postfixIncDec ? '?ExpressionBraceEnd' : '}';
315
- break;
316
-
317
- case ']':
318
- postfixIncDec = true;
319
- break;
320
-
321
- case '++':
322
- case '--':
323
- nextLastSignificantToken = postfixIncDec ? '?PostfixIncDec' : '?UnaryIncDec';
324
- break;
325
-
326
- case '<':
327
- if (jsx2 && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken))) {
328
- stack.push({
329
- tag: 'JSXTag',
330
- });
331
- lastIndex += 1;
332
- lastSignificantToken = '<';
333
- yield {
334
- type: 'JSXPunctuator',
335
- value: punctuator,
336
- };
337
- continue;
338
- }
339
-
340
- postfixIncDec = false;
341
- break;
342
-
343
- default:
344
- postfixIncDec = false;
345
- }
346
-
347
- lastIndex = nextLastIndex;
348
- lastSignificantToken = nextLastSignificantToken;
349
- yield {
350
- type: 'Punctuator',
351
- value: punctuator,
352
- };
353
- continue;
354
- }
355
-
356
- Identifier3.lastIndex = lastIndex;
357
-
358
- if (match = Identifier3.exec(input)) {
359
- lastIndex = Identifier3.lastIndex;
360
- nextLastSignificantToken = match[0];
361
- switch(match[0]) {
362
- case 'for':
363
- case 'if':
364
- case 'while':
365
- case 'with':
366
- if (lastSignificantToken !== '.' && lastSignificantToken !== '?.') {
367
- nextLastSignificantToken = '?NonExpressionParenKeyword';
368
- }
369
- }
370
-
371
- lastSignificantToken = nextLastSignificantToken;
372
- postfixIncDec = !KeywordsWithExpressionAfter.test(match[0]);
373
- yield {
374
- type: match[1] === '#' ? 'PrivateIdentifier' : 'IdentifierName',
375
- value: match[0],
376
- };
377
- continue;
378
- }
379
-
380
- StringLiteral4.lastIndex = lastIndex;
381
-
382
- if (match = StringLiteral4.exec(input)) {
383
- lastIndex = StringLiteral4.lastIndex;
384
- lastSignificantToken = match[0];
385
- postfixIncDec = true;
386
- yield {
387
- type: 'StringLiteral',
388
- value: match[0],
389
- closed: match[2] !== void 0,
390
- };
391
- continue;
392
- }
393
-
394
- NumericLiteral4.lastIndex = lastIndex;
395
-
396
- if (match = NumericLiteral4.exec(input)) {
397
- lastIndex = NumericLiteral4.lastIndex;
398
- lastSignificantToken = match[0];
399
- postfixIncDec = true;
400
- yield {
401
- type: 'NumericLiteral',
402
- value: match[0],
403
- };
404
- continue;
405
- }
406
-
407
- Template.lastIndex = lastIndex;
408
-
409
- if (match = Template.exec(input)) {
410
- lastIndex = Template.lastIndex;
411
- lastSignificantToken = match[0];
412
-
413
- if (match[1] === '${') {
414
- lastSignificantToken = '?InterpolationInTemplate';
415
- stack.push({
416
- tag: 'InterpolationInTemplate',
417
- nesting: braces.length,
418
- });
419
- postfixIncDec = false;
420
- yield {
421
- type: 'TemplateHead',
422
- value: match[0],
423
- };
424
- } else {
425
- postfixIncDec = true;
426
- yield {
427
- type: 'NoSubstitutionTemplate',
428
- value: match[0],
429
- closed: match[1] === '`',
430
- };
431
- }
432
-
433
- continue;
434
- }
435
-
436
- break;
437
-
438
- case 'JSXTag':
439
- case 'JSXTagEnd':
440
- JSXPunctuator.lastIndex = lastIndex;
441
-
442
- if (match = JSXPunctuator.exec(input)) {
443
- lastIndex = JSXPunctuator.lastIndex;
444
- nextLastSignificantToken = match[0];
445
- switch(match[0]) {
446
- case '<':
447
- stack.push({
448
- tag: 'JSXTag',
449
- });
450
- break;
451
-
452
- case '>':
453
- stack.pop();
454
-
455
- if (lastSignificantToken === '/' || mode.tag === 'JSXTagEnd') {
456
- nextLastSignificantToken = '?JSX';
457
- postfixIncDec = true;
458
- } else {
459
- stack.push({
460
- tag: 'JSXChildren',
461
- });
462
- }
463
-
464
- break;
465
-
466
- case '{':
467
- stack.push({
468
- tag: 'InterpolationInJSX',
469
- nesting: braces.length,
470
- });
471
- nextLastSignificantToken = '?InterpolationInJSX';
472
- postfixIncDec = false;
473
- break;
474
-
475
- case '/':
476
- if (lastSignificantToken === '<') {
477
- stack.pop();
478
-
479
- if (stack[stack.length - 1].tag === 'JSXChildren') {
480
- stack.pop();
481
- }
482
-
483
- stack.push({
484
- tag: 'JSXTagEnd',
485
- });
486
- }
487
- }
488
-
489
- lastSignificantToken = nextLastSignificantToken;
490
- yield {
491
- type: 'JSXPunctuator',
492
- value: match[0],
493
- };
494
- continue;
495
- }
496
-
497
- JSXIdentifier3.lastIndex = lastIndex;
498
-
499
- if (match = JSXIdentifier3.exec(input)) {
500
- lastIndex = JSXIdentifier3.lastIndex;
501
- lastSignificantToken = match[0];
502
- yield {
503
- type: 'JSXIdentifier',
504
- value: match[0],
505
- };
506
- continue;
507
- }
508
-
509
- JSXString.lastIndex = lastIndex;
510
-
511
- if (match = JSXString.exec(input)) {
512
- lastIndex = JSXString.lastIndex;
513
- lastSignificantToken = match[0];
514
- yield {
515
- type: 'JSXString',
516
- value: match[0],
517
- closed: match[2] !== void 0,
518
- };
519
- continue;
520
- }
521
-
522
- break;
523
-
524
- case 'JSXChildren':
525
- JSXText3.lastIndex = lastIndex;
526
-
527
- if (match = JSXText3.exec(input)) {
528
- lastIndex = JSXText3.lastIndex;
529
- lastSignificantToken = match[0];
530
- yield {
531
- type: 'JSXText',
532
- value: match[0],
533
- };
534
- continue;
535
- }
536
-
537
- switch(input[lastIndex]) {
538
- case '<':
539
- stack.push({
540
- tag: 'JSXTag',
541
- });
542
- lastIndex++;
543
- lastSignificantToken = '<';
544
- yield {
545
- type: 'JSXPunctuator',
546
- value: '<',
547
- };
548
- continue;
549
-
550
- case '{':
551
- stack.push({
552
- tag: 'InterpolationInJSX',
553
- nesting: braces.length,
554
- });
555
- lastIndex++;
556
- lastSignificantToken = '?InterpolationInJSX';
557
- postfixIncDec = false;
558
- yield {
559
- type: 'JSXPunctuator',
560
- value: '{',
561
- };
562
- continue;
563
- }
564
- }
565
-
566
- WhiteSpace.lastIndex = lastIndex;
567
-
568
- if (match = WhiteSpace.exec(input)) {
569
- lastIndex = WhiteSpace.lastIndex;
570
- yield {
571
- type: 'WhiteSpace',
572
- value: match[0],
573
- };
574
- continue;
575
- }
576
-
577
- LineTerminatorSequence.lastIndex = lastIndex;
578
-
579
- if (match = LineTerminatorSequence.exec(input)) {
580
- lastIndex = LineTerminatorSequence.lastIndex;
581
- postfixIncDec = false;
582
-
583
- if (KeywordsWithNoLineTerminatorAfter.test(lastSignificantToken)) {
584
- lastSignificantToken = '?NoLineTerminatorHere';
585
- }
586
-
587
- yield {
588
- type: 'LineTerminatorSequence',
589
- value: match[0],
590
- };
591
- continue;
592
- }
593
-
594
- MultiLineComment.lastIndex = lastIndex;
595
-
596
- if (match = MultiLineComment.exec(input)) {
597
- lastIndex = MultiLineComment.lastIndex;
598
-
599
- if (Newline.test(match[0])) {
600
- postfixIncDec = false;
601
-
602
- if (KeywordsWithNoLineTerminatorAfter.test(lastSignificantToken)) {
603
- lastSignificantToken = '?NoLineTerminatorHere';
604
- }
605
- }
606
-
607
- yield {
608
- type: 'MultiLineComment',
609
- value: match[0],
610
- closed: match[1] !== void 0,
611
- };
612
- continue;
613
- }
614
-
615
- SingleLineComment.lastIndex = lastIndex;
616
-
617
- if (match = SingleLineComment.exec(input)) {
618
- lastIndex = SingleLineComment.lastIndex;
619
- postfixIncDec = false;
620
- yield {
621
- type: 'SingleLineComment',
622
- value: match[0],
623
- };
624
- continue;
625
- }
626
-
627
- firstCodePoint = String.fromCodePoint(input.codePointAt(lastIndex));
628
- lastIndex += firstCodePoint.length;
629
- lastSignificantToken = firstCodePoint;
630
- postfixIncDec = false;
631
- yield {
632
- type: mode.tag.startsWith('JSX') ? 'JSXInvalid' : 'Invalid',
633
- value: firstCodePoint,
634
- };
635
- }
636
-
637
- return void 0;
638
- };
639
- },
640
- });
641
-
642
139
  // ../babel-babel/node_modules/jsesc/jsesc.js
643
140
  var require_jsesc = __commonJS({
644
141
  '../babel-babel/node_modules/jsesc/jsesc.js'(exports2, module2) {
@@ -8628,7 +8125,8 @@ var functionTypeAnnotationCommon = () => ({
8628
8125
  },
8629
8126
  });
8630
8127
 
8631
- var functionDeclarationCommon = () => Object.assign({}, functionCommon(), {
8128
+ var functionDeclarationCommon = () => ({
8129
+ ...functionCommon(),
8632
8130
  declare: {
8633
8131
  validate: assertValueType('boolean'),
8634
8132
  optional: true,
@@ -8655,7 +8153,9 @@ defineType$4('FunctionDeclaration', {
8655
8153
  'returnType',
8656
8154
  'body',
8657
8155
  ],
8658
- fields: Object.assign({}, functionDeclarationCommon(), functionTypeAnnotationCommon(), {
8156
+ fields: {
8157
+ ...functionDeclarationCommon(),
8158
+ ...functionTypeAnnotationCommon(),
8659
8159
  body: {
8660
8160
  validate: assertNodeType('BlockStatement'),
8661
8161
  },
@@ -8663,7 +8163,7 @@ defineType$4('FunctionDeclaration', {
8663
8163
  validate: assertNodeType('DeclaredPredicate', 'InferredPredicate'),
8664
8164
  optional: true,
8665
8165
  },
8666
- }),
8166
+ },
8667
8167
  aliases: [
8668
8168
  'Scopable',
8669
8169
  'Function',
@@ -8693,7 +8193,9 @@ defineType$4('FunctionExpression', {
8693
8193
  'Expression',
8694
8194
  'Pureish',
8695
8195
  ],
8696
- fields: Object.assign({}, functionCommon(), functionTypeAnnotationCommon(), {
8196
+ fields: {
8197
+ ...functionCommon(),
8198
+ ...functionTypeAnnotationCommon(),
8697
8199
  id: {
8698
8200
  validate: assertNodeType('Identifier'),
8699
8201
  optional: true,
@@ -8705,7 +8207,7 @@ defineType$4('FunctionExpression', {
8705
8207
  validate: assertNodeType('DeclaredPredicate', 'InferredPredicate'),
8706
8208
  optional: true,
8707
8209
  },
8708
- }),
8210
+ },
8709
8211
  });
8710
8212
  var patternLikeCommon = () => ({
8711
8213
  typeAnnotation: {
@@ -8732,7 +8234,8 @@ defineType$4('Identifier', {
8732
8234
  'LVal',
8733
8235
  'TSEntityName',
8734
8236
  ],
8735
- fields: Object.assign({}, patternLikeCommon(), {
8237
+ fields: {
8238
+ ...patternLikeCommon(),
8736
8239
  name: {
8737
8240
  validate: chain(assertValueType('string'), Object.assign(function(node, key, val) {
8738
8241
  if (!isValidIdentifier(val, false)) {
@@ -8742,7 +8245,7 @@ defineType$4('Identifier', {
8742
8245
  type: 'string',
8743
8246
  })),
8744
8247
  },
8745
- }),
8248
+ },
8746
8249
  validate: function(parent, key, node) {
8747
8250
  const match = /\.(\w+)$/.exec(key.toString());
8748
8251
 
@@ -9023,7 +8526,7 @@ defineType$4('ObjectExpression', {
9023
8526
  properties: validateArrayOfType('ObjectMethod', 'ObjectProperty', 'SpreadElement'),
9024
8527
  },
9025
8528
  });
9026
- defineType$4('ObjectMethod', Object.assign({
8529
+ defineType$4('ObjectMethod', {
9027
8530
  builder: [
9028
8531
  'kind',
9029
8532
  'key',
@@ -9041,8 +8544,10 @@ defineType$4('ObjectMethod', Object.assign({
9041
8544
  'returnType',
9042
8545
  'body',
9043
8546
  ],
9044
- }, classMethodOrPropertyUnionShapeCommon(), {
9045
- fields: Object.assign({}, functionCommon(), functionTypeAnnotationCommon(), {
8547
+ ...classMethodOrPropertyUnionShapeCommon(),
8548
+ fields: {
8549
+ ...functionCommon(),
8550
+ ...functionTypeAnnotationCommon(),
9046
8551
  kind: {
9047
8552
  validate: assertOneOf('method', 'get', 'set'),
9048
8553
  },
@@ -9075,7 +8580,7 @@ defineType$4('ObjectMethod', Object.assign({
9075
8580
  body: {
9076
8581
  validate: assertNodeType('BlockStatement'),
9077
8582
  },
9078
- }),
8583
+ },
9079
8584
  aliases: [
9080
8585
  'UserWhitespacable',
9081
8586
  'Function',
@@ -9085,7 +8590,7 @@ defineType$4('ObjectMethod', Object.assign({
9085
8590
  'Method',
9086
8591
  'ObjectMember',
9087
8592
  ],
9088
- }));
8593
+ });
9089
8594
  defineType$4('ObjectProperty', {
9090
8595
  builder: [
9091
8596
  'key',
@@ -9189,11 +8694,12 @@ defineType$4('RestElement', {
9189
8694
  builder: ['argument'],
9190
8695
  aliases: ['FunctionParameter', 'PatternLike'],
9191
8696
  deprecatedAlias: 'RestProperty',
9192
- fields: Object.assign({}, patternLikeCommon(), {
8697
+ fields: {
8698
+ ...patternLikeCommon(),
9193
8699
  argument: {
9194
8700
  validate: assertNodeType('Identifier', 'ArrayPattern', 'ObjectPattern', 'MemberExpression', 'TSAsExpression', 'TSSatisfiesExpression', 'TSTypeAssertion', 'TSNonNullExpression'),
9195
8701
  },
9196
- }),
8702
+ },
9197
8703
  validate: function(parent, key) {
9198
8704
  const match = /(\w+)\[(\d+)\]/.exec(key.toString());
9199
8705
 
@@ -9448,7 +8954,8 @@ defineType$4('AssignmentPattern', {
9448
8954
  'Pattern',
9449
8955
  'PatternLike',
9450
8956
  ],
9451
- fields: Object.assign({}, patternLikeCommon(), {
8957
+ fields: {
8958
+ ...patternLikeCommon(),
9452
8959
  left: {
9453
8960
  validate: assertNodeType('Identifier', 'ObjectPattern', 'ArrayPattern', 'MemberExpression', 'TSAsExpression', 'TSSatisfiesExpression', 'TSTypeAssertion', 'TSNonNullExpression'),
9454
8961
  },
@@ -9459,7 +8966,7 @@ defineType$4('AssignmentPattern', {
9459
8966
  validate: arrayOfType('Decorator'),
9460
8967
  optional: true,
9461
8968
  },
9462
- }),
8969
+ },
9463
8970
  });
9464
8971
  defineType$4('ArrayPattern', {
9465
8972
  visitor: ['elements', 'typeAnnotation'],
@@ -9470,11 +8977,12 @@ defineType$4('ArrayPattern', {
9470
8977
  'PatternLike',
9471
8978
  'LVal',
9472
8979
  ],
9473
- fields: Object.assign({}, patternLikeCommon(), {
8980
+ fields: {
8981
+ ...patternLikeCommon(),
9474
8982
  elements: {
9475
8983
  validate: chain(assertValueType('array'), assertEach(assertNodeOrValueType('null', 'PatternLike'))),
9476
8984
  },
9477
- }),
8985
+ },
9478
8986
  });
9479
8987
  defineType$4('ArrowFunctionExpression', {
9480
8988
  builder: [
@@ -9497,7 +9005,9 @@ defineType$4('ArrowFunctionExpression', {
9497
9005
  'Expression',
9498
9006
  'Pureish',
9499
9007
  ],
9500
- fields: Object.assign({}, functionCommon(), functionTypeAnnotationCommon(), {
9008
+ fields: {
9009
+ ...functionCommon(),
9010
+ ...functionTypeAnnotationCommon(),
9501
9011
  expression: {
9502
9012
  validate: assertValueType('boolean'),
9503
9013
  },
@@ -9508,7 +9018,7 @@ defineType$4('ArrowFunctionExpression', {
9508
9018
  validate: assertNodeType('DeclaredPredicate', 'InferredPredicate'),
9509
9019
  optional: true,
9510
9020
  },
9511
- }),
9021
+ },
9512
9022
  });
9513
9023
  defineType$4('ClassBody', {
9514
9024
  visitor: ['body'],
@@ -9651,12 +9161,13 @@ defineType$4('ExportAllDeclaration', {
9651
9161
  'ImportOrExportDeclaration',
9652
9162
  'ExportDeclaration',
9653
9163
  ],
9654
- fields: Object.assign({
9164
+ fields: {
9655
9165
  source: {
9656
9166
  validate: assertNodeType('StringLiteral'),
9657
9167
  },
9658
9168
  exportKind: validateOptional(assertOneOf('type', 'value')),
9659
- }, importAttributes),
9169
+ ...importAttributes,
9170
+ },
9660
9171
  });
9661
9172
  defineType$4('ExportDefaultDeclaration', {
9662
9173
  visitor: ['declaration'],
@@ -9689,7 +9200,7 @@ defineType$4('ExportNamedDeclaration', {
9689
9200
  'ImportOrExportDeclaration',
9690
9201
  'ExportDeclaration',
9691
9202
  ],
9692
- fields: Object.assign({
9203
+ fields: {
9693
9204
  declaration: {
9694
9205
  optional: true,
9695
9206
  validate: chain(assertNodeType('Declaration'), Object.assign(function(node, key, val) {
@@ -9704,7 +9215,7 @@ defineType$4('ExportNamedDeclaration', {
9704
9215
  oneOfNodeTypes: ['Declaration'],
9705
9216
  })),
9706
9217
  },
9707
- }, importAttributes, {
9218
+ ...importAttributes,
9708
9219
  specifiers: {
9709
9220
  default: [],
9710
9221
  validate: arrayOf((function() {
@@ -9728,7 +9239,7 @@ defineType$4('ExportNamedDeclaration', {
9728
9239
  optional: true,
9729
9240
  },
9730
9241
  exportKind: validateOptional(assertOneOf('type', 'value')),
9731
- }),
9242
+ },
9732
9243
  });
9733
9244
  defineType$4('ExportSpecifier', {
9734
9245
  visitor: ['local', 'exported'],
@@ -9816,7 +9327,8 @@ defineType$4('ImportDeclaration', {
9816
9327
  'Declaration',
9817
9328
  'ImportOrExportDeclaration',
9818
9329
  ],
9819
- fields: Object.assign({}, importAttributes, {
9330
+ fields: {
9331
+ ...importAttributes,
9820
9332
  module: {
9821
9333
  optional: true,
9822
9334
  validate: assertValueType('boolean'),
@@ -9833,7 +9345,7 @@ defineType$4('ImportDeclaration', {
9833
9345
  validate: assertOneOf('type', 'typeof', 'value'),
9834
9346
  optional: true,
9835
9347
  },
9836
- }),
9348
+ },
9837
9349
  });
9838
9350
  defineType$4('ImportDefaultSpecifier', {
9839
9351
  visitor: ['local'],
@@ -9956,7 +9468,9 @@ var classMethodOrPropertyCommon = () => ({
9956
9468
  },
9957
9469
  });
9958
9470
 
9959
- var classMethodOrDeclareMethodCommon = () => Object.assign({}, functionCommon(), classMethodOrPropertyCommon(), {
9471
+ var classMethodOrDeclareMethodCommon = () => ({
9472
+ ...functionCommon(),
9473
+ ...classMethodOrPropertyCommon(),
9960
9474
  params: validateArrayOfType('FunctionParameter', 'TSParameterProperty'),
9961
9475
  kind: {
9962
9476
  validate: assertOneOf('get', 'set', 'method', 'constructor'),
@@ -9972,7 +9486,7 @@ var classMethodOrDeclareMethodCommon = () => Object.assign({}, functionCommon(),
9972
9486
  },
9973
9487
  });
9974
9488
 
9975
- defineType$4('ClassMethod', Object.assign({
9489
+ defineType$4('ClassMethod', {
9976
9490
  aliases: [
9977
9491
  'Function',
9978
9492
  'Scopable',
@@ -9998,13 +9512,15 @@ defineType$4('ClassMethod', Object.assign({
9998
9512
  'returnType',
9999
9513
  'body',
10000
9514
  ],
10001
- }, classMethodOrPropertyUnionShapeCommon(), {
10002
- fields: Object.assign({}, classMethodOrDeclareMethodCommon(), functionTypeAnnotationCommon(), {
9515
+ ...classMethodOrPropertyUnionShapeCommon(),
9516
+ fields: {
9517
+ ...classMethodOrDeclareMethodCommon(),
9518
+ ...functionTypeAnnotationCommon(),
10003
9519
  body: {
10004
9520
  validate: assertNodeType('BlockStatement'),
10005
9521
  },
10006
- }),
10007
- }));
9522
+ },
9523
+ });
10008
9524
  defineType$4('ObjectPattern', {
10009
9525
  visitor: [
10010
9526
  'decorators',
@@ -10018,9 +9534,10 @@ defineType$4('ObjectPattern', {
10018
9534
  'PatternLike',
10019
9535
  'LVal',
10020
9536
  ],
10021
- fields: Object.assign({}, patternLikeCommon(), {
9537
+ fields: {
9538
+ ...patternLikeCommon(),
10022
9539
  properties: validateArrayOfType('RestElement', 'ObjectProperty'),
10023
- }),
9540
+ },
10024
9541
  });
10025
9542
  defineType$4('SpreadElement', {
10026
9543
  visitor: ['argument'],
@@ -10232,7 +9749,7 @@ defineType$4('OptionalCallExpression', {
10232
9749
  },
10233
9750
  },
10234
9751
  });
10235
- defineType$4('ClassProperty', Object.assign({
9752
+ defineType$4('ClassProperty', {
10236
9753
  visitor: [
10237
9754
  'decorators',
10238
9755
  'variance',
@@ -10249,8 +9766,9 @@ defineType$4('ClassProperty', Object.assign({
10249
9766
  'static',
10250
9767
  ],
10251
9768
  aliases: ['Property'],
10252
- }, classMethodOrPropertyUnionShapeCommon(), {
10253
- fields: Object.assign({}, classMethodOrPropertyCommon(), {
9769
+ ...classMethodOrPropertyUnionShapeCommon(),
9770
+ fields: {
9771
+ ...classMethodOrPropertyCommon(),
10254
9772
  value: {
10255
9773
  validate: assertNodeType('Expression'),
10256
9774
  optional: true,
@@ -10279,9 +9797,9 @@ defineType$4('ClassProperty', Object.assign({
10279
9797
  validate: assertNodeType('Variance'),
10280
9798
  optional: true,
10281
9799
  },
10282
- }),
10283
- }));
10284
- defineType$4('ClassAccessorProperty', Object.assign({
9800
+ },
9801
+ });
9802
+ defineType$4('ClassAccessorProperty', {
10285
9803
  visitor: [
10286
9804
  'decorators',
10287
9805
  'key',
@@ -10297,8 +9815,9 @@ defineType$4('ClassAccessorProperty', Object.assign({
10297
9815
  'static',
10298
9816
  ],
10299
9817
  aliases: ['Property', 'Accessor'],
10300
- }, classMethodOrPropertyUnionShapeCommon(true), {
10301
- fields: Object.assign({}, classMethodOrPropertyCommon(), {
9818
+ ...classMethodOrPropertyUnionShapeCommon(true),
9819
+ fields: {
9820
+ ...classMethodOrPropertyCommon(),
10302
9821
  key: {
10303
9822
  validate: chain((function() {
10304
9823
  const normal = assertNodeType('Identifier', 'StringLiteral', 'NumericLiteral', 'BigIntLiteral', 'PrivateName');
@@ -10338,8 +9857,8 @@ defineType$4('ClassAccessorProperty', Object.assign({
10338
9857
  validate: assertNodeType('Variance'),
10339
9858
  optional: true,
10340
9859
  },
10341
- }),
10342
- }));
9860
+ },
9861
+ });
10343
9862
  defineType$4('ClassPrivateProperty', {
10344
9863
  visitor: [
10345
9864
  'decorators',
@@ -10417,7 +9936,9 @@ defineType$4('ClassPrivateMethod', {
10417
9936
  'Method',
10418
9937
  'Private',
10419
9938
  ],
10420
- fields: Object.assign({}, classMethodOrDeclareMethodCommon(), functionTypeAnnotationCommon(), {
9939
+ fields: {
9940
+ ...classMethodOrDeclareMethodCommon(),
9941
+ ...functionTypeAnnotationCommon(),
10421
9942
  kind: {
10422
9943
  validate: assertOneOf('get', 'set', 'method'),
10423
9944
  default: 'method',
@@ -10428,7 +9949,7 @@ defineType$4('ClassPrivateMethod', {
10428
9949
  body: {
10429
9950
  validate: assertNodeType('BlockStatement'),
10430
9951
  },
10431
- }),
9952
+ },
10432
9953
  });
10433
9954
  defineType$4('PrivateName', {
10434
9955
  visitor: ['id'],
@@ -10488,16 +10009,16 @@ var defineInterfaceishType = (name) => {
10488
10009
  'Statement',
10489
10010
  'Declaration',
10490
10011
  ],
10491
- fields: Object.assign({
10012
+ fields: {
10492
10013
  id: validateType('Identifier'),
10493
10014
  typeParameters: validateOptionalType('TypeParameterDeclaration'),
10494
10015
  extends: validateOptional(arrayOfType('InterfaceExtends')),
10495
- }, isDeclareClass2 ? {
10496
- mixins: validateOptional(arrayOfType('InterfaceExtends')),
10497
- implements: validateOptional(arrayOfType('ClassImplements')),
10498
- } : {}, {
10016
+ ...isDeclareClass2 ? {
10017
+ mixins: validateOptional(arrayOfType('InterfaceExtends')),
10018
+ implements: validateOptional(arrayOfType('ClassImplements')),
10019
+ } : {},
10499
10020
  body: validateType('ObjectTypeAnnotation'),
10500
- }),
10021
+ },
10501
10022
  });
10502
10023
  };
10503
10024
 
@@ -10629,12 +10150,13 @@ defineType$3('DeclareExportDeclaration', {
10629
10150
  'Statement',
10630
10151
  'Declaration',
10631
10152
  ],
10632
- fields: Object.assign({
10153
+ fields: {
10633
10154
  declaration: validateOptionalType('Flow'),
10634
10155
  specifiers: validateOptional(arrayOfType('ExportSpecifier', 'ExportNamespaceSpecifier')),
10635
10156
  source: validateOptionalType('StringLiteral'),
10636
10157
  default: validateOptional(assertValueType('boolean')),
10637
- }, importAttributes),
10158
+ ...importAttributes,
10159
+ },
10638
10160
  });
10639
10161
  defineType$3('DeclareExportAllDeclaration', {
10640
10162
  visitor: ['source', 'attributes'],
@@ -10643,10 +10165,11 @@ defineType$3('DeclareExportAllDeclaration', {
10643
10165
  'Statement',
10644
10166
  'Declaration',
10645
10167
  ],
10646
- fields: Object.assign({
10168
+ fields: {
10647
10169
  source: validateType('StringLiteral'),
10648
10170
  exportKind: validateOptional(assertOneOf('type', 'value')),
10649
- }, importAttributes),
10171
+ ...importAttributes,
10172
+ },
10650
10173
  });
10651
10174
  defineType$3('DeclaredPredicate', {
10652
10175
  visitor: ['value'],
@@ -11287,14 +10810,15 @@ var defineType$1 = defineAliasedType('Miscellaneous');
11287
10810
  defineType$1('Placeholder', {
11288
10811
  visitor: [],
11289
10812
  builder: ['expectedNode', 'name'],
11290
- fields: Object.assign({
10813
+ fields: {
11291
10814
  name: {
11292
10815
  validate: assertNodeType('Identifier'),
11293
10816
  },
11294
10817
  expectedNode: {
11295
10818
  validate: assertOneOf(...PLACEHOLDERS),
11296
10819
  },
11297
- }, patternLikeCommon()),
10820
+ ...patternLikeCommon(),
10821
+ },
11298
10822
  });
11299
10823
  defineType$1('V8IntrinsicIdentifier', {
11300
10824
  builder: ['name'],
@@ -11437,9 +10961,12 @@ defineType('TSDeclareFunction', {
11437
10961
  'params',
11438
10962
  'returnType',
11439
10963
  ],
11440
- fields: Object.assign({}, functionDeclarationCommon(), tSFunctionTypeAnnotationCommon()),
10964
+ fields: {
10965
+ ...functionDeclarationCommon(),
10966
+ ...tSFunctionTypeAnnotationCommon(),
10967
+ },
11441
10968
  });
11442
- defineType('TSDeclareMethod', Object.assign({
10969
+ defineType('TSDeclareMethod', {
11443
10970
  visitor: [
11444
10971
  'decorators',
11445
10972
  'key',
@@ -11447,9 +10974,12 @@ defineType('TSDeclareMethod', Object.assign({
11447
10974
  'params',
11448
10975
  'returnType',
11449
10976
  ],
11450
- }, classMethodOrPropertyUnionShapeCommon(), {
11451
- fields: Object.assign({}, classMethodOrDeclareMethodCommon(), tSFunctionTypeAnnotationCommon()),
11452
- }));
10977
+ ...classMethodOrPropertyUnionShapeCommon(),
10978
+ fields: {
10979
+ ...classMethodOrDeclareMethodCommon(),
10980
+ ...tSFunctionTypeAnnotationCommon(),
10981
+ },
10982
+ });
11453
10983
  defineType('TSQualifiedName', {
11454
10984
  aliases: ['TSEntityName'],
11455
10985
  visitor: ['left', 'right'],
@@ -11487,14 +11017,15 @@ var namedTypeElementCommon = () => ({
11487
11017
  defineType('TSPropertySignature', {
11488
11018
  aliases: ['TSTypeElement'],
11489
11019
  visitor: ['key', 'typeAnnotation'],
11490
- fields: Object.assign({}, namedTypeElementCommon(), {
11020
+ fields: {
11021
+ ...namedTypeElementCommon(),
11491
11022
  readonly: validateOptional(bool),
11492
11023
  typeAnnotation: validateOptionalType('TSTypeAnnotation'),
11493
11024
  kind: {
11494
11025
  optional: true,
11495
11026
  validate: assertOneOf('get', 'set'),
11496
11027
  },
11497
- }),
11028
+ },
11498
11029
  });
11499
11030
  defineType('TSMethodSignature', {
11500
11031
  aliases: ['TSTypeElement'],
@@ -11504,11 +11035,13 @@ defineType('TSMethodSignature', {
11504
11035
  'params',
11505
11036
  'returnType',
11506
11037
  ],
11507
- fields: Object.assign({}, signatureDeclarationCommon(), namedTypeElementCommon(), {
11038
+ fields: {
11039
+ ...signatureDeclarationCommon(),
11040
+ ...namedTypeElementCommon(),
11508
11041
  kind: {
11509
11042
  validate: assertOneOf('method', 'get', 'set'),
11510
11043
  },
11511
- }),
11044
+ },
11512
11045
  });
11513
11046
  defineType('TSIndexSignature', {
11514
11047
  aliases: ['TSTypeElement'],
@@ -11559,18 +11092,17 @@ var fnOrCtrBase = {
11559
11092
  ],
11560
11093
  };
11561
11094
 
11562
- defineType('TSFunctionType', Object.assign({},
11563
- fnOrCtrBase,{
11564
- fields: signatureDeclarationCommon(),
11565
- },
11566
- ));
11567
- defineType('TSConstructorType', Object.assign({},
11568
- fnOrCtrBase,{
11569
- fields: Object.assign({}, signatureDeclarationCommon(), {
11570
- abstract: validateOptional(bool),
11571
- }),
11095
+ defineType('TSFunctionType', {
11096
+ ...fnOrCtrBase,
11097
+ fields: signatureDeclarationCommon(),
11098
+ });
11099
+ defineType('TSConstructorType', {
11100
+ ...fnOrCtrBase,
11101
+ fields: {
11102
+ ...signatureDeclarationCommon(),
11103
+ abstract: validateOptional(bool),
11572
11104
  },
11573
- ));
11105
+ });
11574
11106
  defineType('TSTypeReference', {
11575
11107
  aliases: ['TSType'],
11576
11108
  visitor: ['typeName', 'typeArguments'],
@@ -17295,7 +16827,9 @@ function cloneNodeInternal(node, deep = true, withoutLoc = false, commentsCache)
17295
16827
  }
17296
16828
 
17297
16829
  if (hasOwn(node, 'extra')) {
17298
- newNode.extra = Object.assign({}, node.extra);
16830
+ newNode.extra = {
16831
+ ...node.extra,
16832
+ };
17299
16833
  }
17300
16834
 
17301
16835
  return newNode;
@@ -18425,22 +17959,6 @@ var react = {
18425
17959
  };
18426
17960
 
18427
17961
  // ../babel-babel/packages/babel-parser/lib/index.js
18428
- function _objectWithoutPropertiesLoose(r, e) {
18429
- if (null == r)
18430
- return {};
18431
-
18432
- var t = {};
18433
-
18434
- for (var n2 in r) if ({}.hasOwnProperty.call(r, n2)) {
18435
- if (-1 !== e.indexOf(n2))
18436
- continue;
18437
-
18438
- t[n2] = r[n2];
18439
- }
18440
-
18441
- return t;
18442
- }
18443
-
18444
17962
  var Position = class {
18445
17963
  constructor(line, col, index2) {
18446
17964
  __publicField(this, 'line');
@@ -18533,10 +18051,8 @@ var StandardErrors = {
18533
18051
  ConstructorIsGenerator: 'Constructor can\'t be a generator.',
18534
18052
  DeclarationMissingInitializer: ({kind}) => `Missing initializer in ${kind} declaration.`,
18535
18053
  DecoratorArgumentsOutsideParentheses: 'Decorator arguments must be moved inside parentheses: use \'@(decorator(args))\' instead of \'@(decorator)(args)\'.',
18536
- DecoratorBeforeExport: 'Decorators must be placed *before* the \'export\' keyword. Remove the \'decoratorsBeforeExport: true\' option to use the \'export @decorator class {}\' syntax.',
18537
18054
  DecoratorsBeforeAfterExport: 'Decorators can be placed *either* before or after the \'export\' keyword, but not in both locations at the same time.',
18538
18055
  DecoratorConstructor: 'Decorators can\'t be used with a constructor. Did you mean \'@dec class { ... }\'?',
18539
- DecoratorExportClass: 'Decorators must be placed *after* the \'export\' keyword. Remove the \'decoratorsBeforeExport: false\' option to use the \'@decorator export class {}\' syntax.',
18540
18056
  DecoratorSemicolon: 'Decorators must not be followed by a semicolon.',
18541
18057
  DecoratorStaticBlock: 'Decorators can\'t be used with a static block.',
18542
18058
  DeferImportRequiresNamespace: 'Only `import defer * as x from "./module"` is valid.',
@@ -18560,21 +18076,16 @@ var StandardErrors = {
18560
18076
  IllegalBreakContinue: ({type}) => `Unsyntactic ${type === 'BreakStatement' ? 'break' : 'continue'}.`,
18561
18077
  IllegalLanguageModeDirective: 'Illegal \'use strict\' directive in function with non-simple parameter list.',
18562
18078
  IllegalReturn: '\'return\' outside of function.',
18563
- ImportAttributesUseAssert: 'The `assert` keyword in import attributes is deprecated and it has been replaced by the `with` keyword. You can enable the `deprecatedImportAssert` parser plugin to suppress this error.',
18564
18079
  ImportBindingIsString: ({importName}) => `A string literal cannot be used as an imported binding.
18565
18080
  - Did you mean \`import { "${importName}" as foo }\`?`,
18566
18081
  ImportCallArity: `\`import()\` requires exactly one or two arguments.`,
18567
18082
  ImportCallNotNewExpression: 'Cannot use new with import(...).',
18568
18083
  ImportCallSpreadArgument: '`...` is not allowed in `import()`.',
18569
- ImportJSONBindingNotDefault: 'A JSON module can only be imported with `default`.',
18570
- ImportReflectionHasAssertion: '`import module x` cannot have assertions.',
18571
- ImportReflectionNotBinding: 'Only `import module x from "./module"` is valid.',
18572
18084
  IncompatibleRegExpUVFlags: 'The \'u\' and \'v\' regular expression flags cannot be enabled at the same time.',
18573
18085
  InvalidBigIntLiteral: 'Invalid BigIntLiteral.',
18574
18086
  InvalidCodePoint: 'Code point out of bounds.',
18575
18087
  InvalidCoverDiscardElement: '\'void\' must be followed by an expression when not used in a binding position.',
18576
18088
  InvalidCoverInitializedName: 'Invalid shorthand property initializer.',
18577
- InvalidDecimal: 'Invalid decimal.',
18578
18089
  InvalidDigit: ({radix}) => `Expected number in radix ${radix}.`,
18579
18090
  InvalidEscapeSequence: 'Bad character escape sequence.',
18580
18091
  InvalidEscapeSequenceTemplate: 'Invalid escape sequence in template.',
@@ -18589,7 +18100,6 @@ var StandardErrors = {
18589
18100
  InvalidParenthesizedAssignment: 'Invalid parenthesized assignment pattern.',
18590
18101
  InvalidPrivateFieldResolution: ({identifierName}) => `Private name #${identifierName} is not defined.`,
18591
18102
  InvalidPropertyBindingPattern: 'Binding member expression.',
18592
- InvalidRecordProperty: 'Only properties and spread elements are allowed in record definitions.',
18593
18103
  InvalidRestAssignmentPattern: 'Invalid rest operator\'s argument.',
18594
18104
  LabelRedeclaration: ({labelName}) => `Label '${labelName}' is already declared.`,
18595
18105
  LetInLexicalBinding: '\'let\' is disallowed as a lexically bound name.',
@@ -18606,7 +18116,6 @@ var StandardErrors = {
18606
18116
  .join(', ')}.`,
18607
18117
  MissingUnicodeEscape: 'Expecting Unicode escape sequence \\uXXXX.',
18608
18118
  MixingCoalesceWithLogical: 'Nullish coalescing operator(??) requires parens when mixing with logical operators.',
18609
- ModuleAttributeDifferentFromType: 'The only accepted module attribute is `type`.',
18610
18119
  ModuleAttributeInvalidValue: 'Only string literals are allowed as module attribute values.',
18611
18120
  ModuleAttributesWithDuplicateKeys: ({key}) => `Duplicate key "${key}" is not allowed in module attributes.`,
18612
18121
  ModuleExportNameHasLoneSurrogate: ({surrogateCharCode}) => `An export name cannot include a lone surrogate, found '\\u${surrogateCharCode.toString(16)}'.`,
@@ -18625,10 +18134,6 @@ var StandardErrors = {
18625
18134
  PatternHasMethod: 'Object pattern can\'t contain methods.',
18626
18135
  PrivateInExpectedIn: ({identifierName}) => `Private names are only allowed in property accesses (\`obj.#${identifierName}\`) or in \`in\` expressions (\`#${identifierName} in obj\`).`,
18627
18136
  PrivateNameRedeclaration: ({identifierName}) => `Duplicate private name #${identifierName}.`,
18628
- RecordExpressionBarIncorrectEndSyntaxType: 'Record expressions ending with \'|}\' are only allowed when the \'syntaxType\' option of the \'recordAndTuple\' plugin is set to \'bar\'.',
18629
- RecordExpressionBarIncorrectStartSyntaxType: 'Record expressions starting with \'{|\' are only allowed when the \'syntaxType\' option of the \'recordAndTuple\' plugin is set to \'bar\'.',
18630
- RecordExpressionHashIncorrectStartSyntaxType: 'Record expressions starting with \'#{\' are only allowed when the \'syntaxType\' option of the \'recordAndTuple\' plugin is set to \'hash\'.',
18631
- RecordNoProto: '\'__proto__\' is not allowed in Record expressions.',
18632
18137
  RestTrailingComma: 'Unexpected trailing comma after rest element.',
18633
18138
  SloppyFunction: 'In non-strict mode code, functions can only be declared at top level or inside a block.',
18634
18139
  SloppyFunctionAnnexB: 'In non-strict mode code, functions can only be declared at top level, inside a block, or as the body of an if statement.',
@@ -18637,11 +18142,7 @@ var StandardErrors = {
18637
18142
  SuperNotAllowed: '`super()` is only valid inside a class constructor of a subclass. Maybe a typo in the method name (\'constructor\') or not extending another class?',
18638
18143
  SuperPrivateField: 'Private fields can\'t be accessed on super.',
18639
18144
  TrailingDecorator: 'Decorators must be attached to a class element.',
18640
- TupleExpressionBarIncorrectEndSyntaxType: 'Tuple expressions ending with \'|]\' are only allowed when the \'syntaxType\' option of the \'recordAndTuple\' plugin is set to \'bar\'.',
18641
- TupleExpressionBarIncorrectStartSyntaxType: 'Tuple expressions starting with \'[|\' are only allowed when the \'syntaxType\' option of the \'recordAndTuple\' plugin is set to \'bar\'.',
18642
- TupleExpressionHashIncorrectStartSyntaxType: 'Tuple expressions starting with \'#[\' are only allowed when the \'syntaxType\' option of the \'recordAndTuple\' plugin is set to \'hash\'.',
18643
18145
  UnexpectedArgumentPlaceholder: 'Unexpected argument placeholder.',
18644
- UnexpectedAwaitAfterPipelineBody: 'Unexpected "await" after pipeline body; await must have parentheses in minimal proposal.',
18645
18146
  UnexpectedDigitAfterHash: 'Unexpected digit after hash token.',
18646
18147
  UnexpectedImportExport: '\'import\' and \'export\' may only appear at the top level.',
18647
18148
  UnexpectedKeyword: ({keyword}) => `Unexpected keyword '${keyword}'.`,
@@ -18712,8 +18213,6 @@ var PipelineOperatorErrors = {
18712
18213
  })}; please wrap it in parentheses.`,
18713
18214
  };
18714
18215
 
18715
- var _excluded = ['message'];
18716
-
18717
18216
  function defineHidden(obj, key, value) {
18718
18217
  Object.defineProperty(obj, key, {
18719
18218
  enumerable: false,
@@ -18745,7 +18244,10 @@ function toParseErrorConstructor({toMessage, code: code2, reasonCode, syntaxPlug
18745
18244
  index: index2,
18746
18245
  } = overrides.loc ?? loc;
18747
18246
 
18748
- return constructor(new Position(line, column, index2), Object.assign({}, details, overrides.details));
18247
+ return constructor(new Position(line, column, index2), {
18248
+ ...details,
18249
+ ...overrides.details,
18250
+ });
18749
18251
  });
18750
18252
  defineHidden(error, 'details', details);
18751
18253
  Object.defineProperty(error, 'message', {
@@ -18776,27 +18278,35 @@ function ParseErrorEnum(argument, syntaxPlugin) {
18776
18278
 
18777
18279
  for (const reasonCode of Object.keys(argument)) {
18778
18280
  const template = argument[reasonCode];
18779
- const _ref = typeof template === 'string' ? {
18780
- message: () => template,
18781
- } : typeof template === 'function' ? {
18782
- message: template,
18783
- } : template, {message} = _ref, rest = _objectWithoutPropertiesLoose(_ref, _excluded);
18281
+ const {message, ...rest} = typeof template === 'string' ? {
18282
+ message: () => template,
18283
+ } : typeof template === 'function' ? {
18284
+ message: template,
18285
+ } : template;
18784
18286
 
18785
18287
  const toMessage = typeof message === 'string' ? () => message : message;
18786
18288
 
18787
- ParseErrorConstructors[reasonCode] = toParseErrorConstructor(Object.assign({
18289
+ ParseErrorConstructors[reasonCode] = toParseErrorConstructor({
18788
18290
  code: 'BABEL_PARSER_SYNTAX_ERROR',
18789
18291
  reasonCode,
18790
18292
  toMessage,
18791
- }, syntaxPlugin ? {
18792
- syntaxPlugin,
18793
- } : {}, rest));
18293
+ ...syntaxPlugin ? {
18294
+ syntaxPlugin,
18295
+ } : {},
18296
+ ...rest,
18297
+ });
18794
18298
  }
18795
18299
 
18796
18300
  return ParseErrorConstructors;
18797
18301
  }
18798
18302
 
18799
- var Errors = Object.assign({}, ParseErrorEnum(ModuleErrors), ParseErrorEnum(StandardErrors), ParseErrorEnum(StrictModeErrors), ParseErrorEnum(ParseExpressionErrors), ParseErrorEnum`pipelineOperator`(PipelineOperatorErrors));
18303
+ var Errors = {
18304
+ ...ParseErrorEnum(ModuleErrors),
18305
+ ...ParseErrorEnum(StandardErrors),
18306
+ ...ParseErrorEnum(StrictModeErrors),
18307
+ ...ParseErrorEnum(ParseExpressionErrors),
18308
+ ...ParseErrorEnum`pipelineOperator`(PipelineOperatorErrors),
18309
+ };
18800
18310
 
18801
18311
  function createDefaultOptions() {
18802
18312
  return {
@@ -18928,14 +18438,6 @@ var estree = (superClass) => class ESTreeParserMixin extends superClass {
18928
18438
  return node;
18929
18439
  }
18930
18440
 
18931
- parseDecimalLiteral(value) {
18932
- const decimal = null;
18933
- const node = this.estreeParseLiteral(decimal);
18934
-
18935
- node.decimal = String(node.value || value);
18936
- return node;
18937
- }
18938
-
18939
18441
  estreeParseLiteral(value) {
18940
18442
  return this.parseLiteral(value, 'Literal');
18941
18443
  }
@@ -23158,24 +22660,27 @@ var Tokenizer = class extends CommentsParser {
23158
22660
  numericSeparatorInEscapeSequence: this.errorBuilder(Errors.NumericSeparatorInEscapeSequence),
23159
22661
  unexpectedNumericSeparator: this.errorBuilder(Errors.UnexpectedNumericSeparator),
23160
22662
  });
23161
- __publicField(this, 'errorHandlers_readCodePoint', Object.assign({}, this.errorHandlers_readInt, {
22663
+ __publicField(this, 'errorHandlers_readCodePoint', {
22664
+ ...this.errorHandlers_readInt,
23162
22665
  invalidEscapeSequence: this.errorBuilder(Errors.InvalidEscapeSequence),
23163
22666
  invalidCodePoint: this.errorBuilder(Errors.InvalidCodePoint),
23164
- }));
23165
- __publicField(this, 'errorHandlers_readStringContents_string', Object.assign({}, this.errorHandlers_readCodePoint, {
22667
+ });
22668
+ __publicField(this, 'errorHandlers_readStringContents_string', {
22669
+ ...this.errorHandlers_readCodePoint,
23166
22670
  strictNumericEscape: (pos, lineStart, curLine) => {
23167
22671
  this.recordStrictModeErrors(Errors.StrictNumericEscape, buildPosition(pos, lineStart, curLine));
23168
22672
  },
23169
22673
  unterminated: (pos, lineStart, curLine) => {
23170
22674
  throw this.raise(Errors.UnterminatedString, buildPosition(pos - 1, lineStart, curLine));
23171
22675
  },
23172
- }));
23173
- __publicField(this, 'errorHandlers_readStringContents_template', Object.assign({}, this.errorHandlers_readCodePoint, {
22676
+ });
22677
+ __publicField(this, 'errorHandlers_readStringContents_template', {
22678
+ ...this.errorHandlers_readCodePoint,
23174
22679
  strictNumericEscape: this.errorBuilder(Errors.StrictNumericEscape),
23175
22680
  unterminated: (pos, lineStart, curLine) => {
23176
22681
  throw this.raise(Errors.UnterminatedTemplate, buildPosition(pos, lineStart, curLine));
23177
22682
  },
23178
- }));
22683
+ });
23179
22684
  this.state = new State();
23180
22685
  this.state.init(options);
23181
22686
  this.input = input;
@@ -24028,8 +23533,6 @@ var Tokenizer = class extends CommentsParser {
24028
23533
  if (next === 110) {
24029
23534
  ++this.state.pos;
24030
23535
  isBigInt = true;
24031
- } else if (next === 109) {
24032
- throw this.raise(Errors.InvalidDecimal, startLoc);
24033
23536
  }
24034
23537
 
24035
23538
  if (isIdentifierStart2(this.codePointAtPos(this.state.pos))) {
@@ -25560,7 +25063,6 @@ var TSErrors = ParseErrorEnum`typescript`({
25560
25063
  EmptyTypeParameters: 'Type parameter list cannot be empty.',
25561
25064
  ExpectedAmbientAfterExportDeclare: '\'export declare\' must be followed by an ambient declaration.',
25562
25065
  ImportAliasHasImportType: 'An import alias can not use \'import type\'.',
25563
- ImportReflectionHasImportType: 'An `import module` declaration can not use `type` modifier',
25564
25066
  IncompatibleModifiers: ({modifiers}) => `'${modifiers[0]}' modifier cannot be used with '${modifiers[1]}' modifier.`,
25565
25067
  IndexSignatureHasAbstract: 'Index signatures cannot have the \'abstract\' modifier.',
25566
25068
  IndexSignatureHasAccessibility: ({modifier}) => `Index signatures cannot have an accessibility modifier ('${modifier}').`,
@@ -27611,8 +27113,8 @@ var typescript = (superClass) => class TypeScriptParserMixin extends superClass
27611
27113
  return exprList;
27612
27114
  }
27613
27115
 
27614
- parseArrayLike(close, isTuple, refExpressionErrors) {
27615
- const node = super.parseArrayLike(close, isTuple, refExpressionErrors);
27116
+ parseArrayLike(close, refExpressionErrors) {
27117
+ const node = super.parseArrayLike(close, refExpressionErrors);
27616
27118
 
27617
27119
  if (node.type === 'ArrayExpression') {
27618
27120
  this.tsCheckForInvalidTypeCasts(node.elements);
@@ -27769,14 +27271,6 @@ var typescript = (superClass) => class TypeScriptParserMixin extends superClass
27769
27271
  }
27770
27272
  }
27771
27273
 
27772
- checkImportReflection(node) {
27773
- super.checkImportReflection(node);
27774
-
27775
- if (node.module && node.importKind !== 'value') {
27776
- this.raise(TSErrors.ImportReflectionHasImportType, node.specifiers[0].loc.start);
27777
- }
27778
- }
27779
-
27780
27274
  checkDuplicateExports() {}
27781
27275
 
27782
27276
  isPotentialImportPhase(isExport) {
@@ -29488,18 +28982,6 @@ function validatePlugins(pluginsMap) {
29488
28982
  if (pluginsMap.has('decorators-legacy')) {
29489
28983
  throw new Error('Cannot use the decorators and decorators-legacy plugin together');
29490
28984
  }
29491
-
29492
- const decoratorsBeforeExport = pluginsMap.get('decorators').decoratorsBeforeExport;
29493
-
29494
- if (decoratorsBeforeExport != null && typeof decoratorsBeforeExport !== 'boolean') {
29495
- throw new Error('\'decoratorsBeforeExport\' must be a boolean, if specified.');
29496
- }
29497
-
29498
- const allowCallParenthesized = pluginsMap.get('decorators').allowCallParenthesized;
29499
-
29500
- if (allowCallParenthesized != null && typeof allowCallParenthesized !== 'boolean') {
29501
- throw new Error('\'allowCallParenthesized\' must be a boolean.');
29502
- }
29503
28985
  }
29504
28986
 
29505
28987
  if (pluginsMap.has('flow') && pluginsMap.has('typescript')) {
@@ -29593,7 +29075,7 @@ var mixinPlugins = {
29593
29075
  var mixinPluginNames = Object.keys(mixinPlugins);
29594
29076
 
29595
29077
  var ExpressionParser = class extends LValParser {
29596
- checkProto(prop, isRecord, sawProto, refExpressionErrors) {
29078
+ checkProto(prop, sawProto, refExpressionErrors) {
29597
29079
  if (prop.type === 'SpreadElement' || this.isObjectMethod(prop) || prop.computed || prop.shorthand) {
29598
29080
  return sawProto;
29599
29081
  }
@@ -29602,11 +29084,6 @@ var ExpressionParser = class extends LValParser {
29602
29084
  const name = key.type === 'Identifier' ? key.name : key.value;
29603
29085
 
29604
29086
  if (name === '__proto__') {
29605
- if (isRecord) {
29606
- this.raise(Errors.RecordNoProto, key);
29607
- return true;
29608
- }
29609
-
29610
29087
  if (sawProto) {
29611
29088
  if (refExpressionErrors) {
29612
29089
  if (refExpressionErrors.doubleProtoLoc === null) {
@@ -30350,11 +29827,11 @@ var ExpressionParser = class extends LValParser {
30350
29827
  }
30351
29828
 
30352
29829
  case 0: {
30353
- return this.parseArrayLike(3, false, refExpressionErrors);
29830
+ return this.parseArrayLike(3, refExpressionErrors);
30354
29831
  }
30355
29832
 
30356
29833
  case 5: {
30357
- return this.parseObjectLike(8, false, false, refExpressionErrors);
29834
+ return this.parseObjectLike(8, false, refExpressionErrors);
30358
29835
  }
30359
29836
 
30360
29837
  case 68:
@@ -30517,9 +29994,6 @@ var ExpressionParser = class extends LValParser {
30517
29994
  }]);
30518
29995
  }
30519
29996
 
30520
- case 'smart':
30521
- return tokenType === 27;
30522
-
30523
29997
  default:
30524
29998
  throw this.raise(Errors.PipeTopicRequiresHackPipes, startLoc);
30525
29999
  }
@@ -30688,10 +30162,6 @@ var ExpressionParser = class extends LValParser {
30688
30162
  return node;
30689
30163
  }
30690
30164
 
30691
- parseDecimalLiteral(value) {
30692
- return this.parseLiteral(value, 'DecimalLiteral');
30693
- }
30694
-
30695
30165
  parseRegExpLiteral(value) {
30696
30166
  const node = this.startNode();
30697
30167
  this.addExtra(node, 'raw', this.input.slice(this.offsetToSourcePos(node.start), this.state.end));
@@ -30934,11 +30404,7 @@ var ExpressionParser = class extends LValParser {
30934
30404
  return this.parseExpression();
30935
30405
  }
30936
30406
 
30937
- parseObjectLike(close, isPattern3, isRecord, refExpressionErrors) {
30938
- if (isRecord) {
30939
- this.expectPlugin('recordAndTuple');
30940
- }
30941
-
30407
+ parseObjectLike(close, isPattern3, refExpressionErrors) {
30942
30408
  const oldInFSharpPipelineDirectBody = this.state.inFSharpPipelineDirectBody;
30943
30409
 
30944
30410
  this.state.inFSharpPipelineDirectBody = false;
@@ -30966,11 +30432,7 @@ var ExpressionParser = class extends LValParser {
30966
30432
  prop = this.parseBindingProperty();
30967
30433
  } else {
30968
30434
  prop = this.parsePropertyDefinition(refExpressionErrors);
30969
- sawProto = this.checkProto(prop, isRecord, sawProto, refExpressionErrors);
30970
- }
30971
-
30972
- if (isRecord && !this.isObjectProperty(prop) && prop.type !== 'SpreadElement') {
30973
- this.raise(Errors.InvalidRecordProperty, prop);
30435
+ sawProto = this.checkProto(prop, sawProto, refExpressionErrors);
30974
30436
  }
30975
30437
 
30976
30438
  node.properties.push(prop);
@@ -30978,13 +30440,7 @@ var ExpressionParser = class extends LValParser {
30978
30440
 
30979
30441
  this.next();
30980
30442
  this.state.inFSharpPipelineDirectBody = oldInFSharpPipelineDirectBody;
30981
- let type = 'ObjectExpression';
30982
-
30983
- if (isPattern3) {
30984
- type = 'ObjectPattern';
30985
- } else if (isRecord) {
30986
- type = 'RecordExpression';
30987
- }
30443
+ const type = isPattern3 ? 'ObjectPattern' : 'ObjectExpression';
30988
30444
 
30989
30445
  return this.finishNode(node, type);
30990
30446
  }
@@ -31231,19 +30687,15 @@ var ExpressionParser = class extends LValParser {
31231
30687
  return finishedNode;
31232
30688
  }
31233
30689
 
31234
- parseArrayLike(close, isTuple, refExpressionErrors) {
31235
- if (isTuple) {
31236
- this.expectPlugin('recordAndTuple');
31237
- }
31238
-
30690
+ parseArrayLike(close, refExpressionErrors) {
31239
30691
  const oldInFSharpPipelineDirectBody = this.state.inFSharpPipelineDirectBody;
31240
30692
 
31241
30693
  this.state.inFSharpPipelineDirectBody = false;
31242
30694
  const node = this.startNode();
31243
30695
  this.next();
31244
- node.elements = this.parseExprList(close, !isTuple, refExpressionErrors, node);
30696
+ node.elements = this.parseExprList(close, true, refExpressionErrors, node);
31245
30697
  this.state.inFSharpPipelineDirectBody = oldInFSharpPipelineDirectBody;
31246
- return this.finishNode(node, isTuple ? 'TupleExpression' : 'ArrayExpression');
30698
+ return this.finishNode(node, 'ArrayExpression');
31247
30699
  }
31248
30700
 
31249
30701
  parseArrowExpression(node, params, isAsync, trailingCommaLoc) {
@@ -31615,10 +31067,6 @@ var ExpressionParser = class extends LValParser {
31615
31067
  }
31616
31068
  }
31617
31069
 
31618
- withSmartMixTopicForbiddingContext(callback) {
31619
- return callback();
31620
- }
31621
-
31622
31070
  withSoloAwaitPermittingContext(callback) {
31623
31071
  const outerContextSoloAwaitState = this.state.soloAwait;
31624
31072
 
@@ -32149,20 +31597,10 @@ var StatementParser = class extends ExpressionParser {
32149
31597
  }
32150
31598
  }
32151
31599
 
32152
- decoratorsEnabledBeforeExport() {
32153
- if (this.hasPlugin('decorators-legacy'))
32154
- return true;
32155
-
32156
- return this.hasPlugin('decorators') && this.getPluginOption('decorators', 'decoratorsBeforeExport') !== false;
32157
- }
32158
-
32159
31600
  maybeTakeDecorators(maybeDecorators, classNode, exportNode) {
32160
31601
  if (maybeDecorators) {
32161
31602
  if (classNode.decorators?.length) {
32162
- if (typeof this.getPluginOption('decorators', 'decoratorsBeforeExport') !== 'boolean') {
32163
- this.raise(Errors.DecoratorsBeforeAfterExport, classNode.decorators[0]);
32164
- }
32165
-
31603
+ this.raise(Errors.DecoratorsBeforeAfterExport, classNode.decorators[0]);
32166
31604
  classNode.decorators.unshift(...maybeDecorators);
32167
31605
  } else {
32168
31606
  classNode.decorators = maybeDecorators;
@@ -32191,10 +31629,6 @@ var StatementParser = class extends ExpressionParser {
32191
31629
  if (!allowExport) {
32192
31630
  this.unexpected();
32193
31631
  }
32194
-
32195
- if (!this.decoratorsEnabledBeforeExport()) {
32196
- this.raise(Errors.DecoratorExportClass, this.state.startLoc);
32197
- }
32198
31632
  } else if (!this.canHaveLeadingDecorator()) {
32199
31633
  throw this.raise(Errors.UnexpectedLeadingDecorator, this.state.startLoc);
32200
31634
  }
@@ -32221,7 +31655,7 @@ var StatementParser = class extends ExpressionParser {
32221
31655
 
32222
31656
  node.expression = this.parseMaybeDecoratorArguments(expr, startLoc2);
32223
31657
 
32224
- if (this.getPluginOption('decorators', 'allowCallParenthesized') === false && node.expression !== expr) {
31658
+ if (node.expression !== expr) {
32225
31659
  this.raise(Errors.DecoratorArgumentsOutsideParentheses, paramsStartLoc);
32226
31660
  }
32227
31661
  } else {
@@ -32319,7 +31753,7 @@ var StatementParser = class extends ExpressionParser {
32319
31753
  parseDoWhileStatement(node) {
32320
31754
  this.next();
32321
31755
  this.state.labels.push(loopLabel);
32322
- node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement());
31756
+ node.body = this.parseStatement();
32323
31757
  this.state.labels.pop();
32324
31758
  this.expect(92);
32325
31759
  node.test = this.parseHeaderExpression();
@@ -32546,7 +31980,7 @@ var StatementParser = class extends ExpressionParser {
32546
31980
  this.scope.enter(0);
32547
31981
  }
32548
31982
 
32549
- clause.body = this.withSmartMixTopicForbiddingContext(() => this.parseBlock(false, false));
31983
+ clause.body = this.parseBlock(false, false);
32550
31984
  this.scope.exit();
32551
31985
  node.handler = this.finishNode(clause, 'CatchClause');
32552
31986
  }
@@ -32571,7 +32005,7 @@ var StatementParser = class extends ExpressionParser {
32571
32005
  this.next();
32572
32006
  node.test = this.parseHeaderExpression();
32573
32007
  this.state.labels.push(loopLabel);
32574
- node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement());
32008
+ node.body = this.parseStatement();
32575
32009
  this.state.labels.pop();
32576
32010
  return this.finishNode(node, 'WhileStatement');
32577
32011
  }
@@ -32583,7 +32017,7 @@ var StatementParser = class extends ExpressionParser {
32583
32017
 
32584
32018
  this.next();
32585
32019
  node.object = this.parseHeaderExpression();
32586
- node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement());
32020
+ node.body = this.parseStatement();
32587
32021
  return this.finishNode(node, 'WithStatement');
32588
32022
  }
32589
32023
 
@@ -32707,7 +32141,7 @@ var StatementParser = class extends ExpressionParser {
32707
32141
  this.semicolon(false);
32708
32142
  node.update = this.match(11) ? null : this.parseExpression();
32709
32143
  this.expect(11);
32710
- node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement());
32144
+ node.body = this.parseStatement();
32711
32145
  this.scope.exit();
32712
32146
  this.state.labels.pop();
32713
32147
  return this.finishNode(node, 'ForStatement');
@@ -32741,7 +32175,7 @@ var StatementParser = class extends ExpressionParser {
32741
32175
  node.left = init;
32742
32176
  node.right = isForIn ? this.parseExpression() : this.parseMaybeAssignAllowIn();
32743
32177
  this.expect(11);
32744
- node.body = this.withSmartMixTopicForbiddingContext(() => this.parseStatement());
32178
+ node.body = this.parseStatement();
32745
32179
  this.scope.exit();
32746
32180
  this.state.labels.pop();
32747
32181
  return this.finishNode(node, isForIn ? 'ForInStatement' : 'ForOfStatement');
@@ -32832,9 +32266,7 @@ var StatementParser = class extends ExpressionParser {
32832
32266
  }
32833
32267
 
32834
32268
  this.parseFunctionParams(node, false);
32835
- this.withSmartMixTopicForbiddingContext(() => {
32836
- this.parseFunctionBodyAndFinish(node, isDeclaration2 ? 'FunctionDeclaration' : 'FunctionExpression');
32837
- });
32269
+ this.parseFunctionBodyAndFinish(node, isDeclaration2 ? 'FunctionDeclaration' : 'FunctionExpression');
32838
32270
  this.prodParam.exit();
32839
32271
  this.scope.exit();
32840
32272
 
@@ -32904,36 +32336,35 @@ var StatementParser = class extends ExpressionParser {
32904
32336
 
32905
32337
  classBody2.body = [];
32906
32338
  this.expect(5);
32907
- this.withSmartMixTopicForbiddingContext(() => {
32908
- while (!this.match(8)) {
32909
- if (this.eat(13)) {
32910
- if (decorators.length > 0) {
32911
- throw this.raise(Errors.DecoratorSemicolon, this.state.lastTokEndLoc);
32912
- }
32913
-
32914
- continue;
32915
- }
32916
-
32917
- if (this.match(26)) {
32918
- decorators.push(this.parseDecorator());
32919
- continue;
32920
- }
32921
-
32922
- const member = this.startNode();
32923
-
32924
- if (decorators.length) {
32925
- member.decorators = decorators;
32926
- this.resetStartLocationFromNode(member, decorators[0]);
32927
- decorators = [];
32339
+ while (!this.match(8)) {
32340
+ if (this.eat(13)) {
32341
+ if (decorators.length > 0) {
32342
+ throw this.raise(Errors.DecoratorSemicolon, this.state.lastTokEndLoc);
32928
32343
  }
32929
32344
 
32930
- this.parseClassMember(classBody2, member, state);
32931
-
32932
- if (member.kind === 'constructor' && member.decorators && member.decorators.length > 0) {
32933
- this.raise(Errors.DecoratorConstructor, member);
32934
- }
32345
+ continue;
32935
32346
  }
32936
- });
32347
+
32348
+ if (this.match(26)) {
32349
+ decorators.push(this.parseDecorator());
32350
+ continue;
32351
+ }
32352
+
32353
+ const member = this.startNode();
32354
+
32355
+ if (decorators.length) {
32356
+ member.decorators = decorators;
32357
+ this.resetStartLocationFromNode(member, decorators[0]);
32358
+ decorators = [];
32359
+ }
32360
+
32361
+ this.parseClassMember(classBody2, member, state);
32362
+
32363
+ if (member.kind === 'constructor' && member.decorators && member.decorators.length > 0) {
32364
+ this.raise(Errors.DecoratorConstructor, member);
32365
+ }
32366
+ }
32367
+
32937
32368
  this.state.strict = oldStrict;
32938
32369
  this.next();
32939
32370
 
@@ -33429,10 +32860,6 @@ var StatementParser = class extends ExpressionParser {
33429
32860
  }
33430
32861
 
33431
32862
  if (this.match(26)) {
33432
- if (this.hasPlugin('decorators') && this.getPluginOption('decorators', 'decoratorsBeforeExport') === true) {
33433
- this.raise(Errors.DecoratorBeforeExport, this.state.startLoc);
33434
- }
33435
-
33436
32863
  return this.parseClass(this.maybeTakeDecorators(this.parseDecorators(false), this.startNode()), true, true);
33437
32864
  }
33438
32865
 
@@ -33495,7 +32922,6 @@ var StatementParser = class extends ExpressionParser {
33495
32922
  node.source = this.parseImportSource();
33496
32923
  this.checkExport(node);
33497
32924
  this.maybeParseImportAttributes(node);
33498
- this.checkJSONModuleImport(node);
33499
32925
  } else if (expect) {
33500
32926
  this.unexpected();
33501
32927
  }
@@ -33510,10 +32936,6 @@ var StatementParser = class extends ExpressionParser {
33510
32936
  this.expectOnePlugin(['decorators', 'decorators-legacy']);
33511
32937
 
33512
32938
  if (this.hasPlugin('decorators')) {
33513
- if (this.getPluginOption('decorators', 'decoratorsBeforeExport') === true) {
33514
- this.raise(Errors.DecoratorBeforeExport, this.state.startLoc);
33515
- }
33516
-
33517
32939
  return true;
33518
32940
  }
33519
32941
  }
@@ -33688,17 +33110,7 @@ var StatementParser = class extends ExpressionParser {
33688
33110
  return this.parseIdentifier(true);
33689
33111
  }
33690
33112
 
33691
- isJSONModuleImport(node) {
33692
- if (node.assertions != null) {
33693
- return node.assertions.some(({key, value}) => {
33694
- return value.value === 'json' && (key.type === 'Identifier' ? key.name === 'type' : key.value === 'type');
33695
- });
33696
- }
33697
-
33698
- return false;
33699
- }
33700
-
33701
- checkImportReflection(node) {
33113
+ checkImportPhase(node) {
33702
33114
  const {specifiers} = node;
33703
33115
 
33704
33116
  const singleBindingType = specifiers.length === 1 ? specifiers[0].type : null;
@@ -33711,41 +33123,6 @@ var StatementParser = class extends ExpressionParser {
33711
33123
  if (singleBindingType !== 'ImportNamespaceSpecifier') {
33712
33124
  this.raise(Errors.DeferImportRequiresNamespace, specifiers[0].loc.start);
33713
33125
  }
33714
- } else if (node.module) {
33715
- if (singleBindingType !== 'ImportDefaultSpecifier') {
33716
- this.raise(Errors.ImportReflectionNotBinding, specifiers[0].loc.start);
33717
- }
33718
-
33719
- if (node.assertions?.length > 0) {
33720
- this.raise(Errors.ImportReflectionHasAssertion, specifiers[0].loc.start);
33721
- }
33722
- }
33723
-
33724
- }
33725
-
33726
- checkJSONModuleImport(node) {
33727
- if (this.isJSONModuleImport(node) && node.type !== 'ExportAllDeclaration') {
33728
- const {specifiers} = node;
33729
-
33730
- if (specifiers != null) {
33731
- const nonDefaultNamedSpecifier = specifiers.find((specifier) => {
33732
- let imported;
33733
-
33734
- if (specifier.type === 'ExportSpecifier') {
33735
- imported = specifier.local;
33736
- } else if (specifier.type === 'ImportSpecifier') {
33737
- imported = specifier.imported;
33738
- }
33739
-
33740
- if (imported !== void 0) {
33741
- return imported.type === 'Identifier' ? imported.name !== 'default' : imported.value !== 'default';
33742
- }
33743
- });
33744
-
33745
- if (nonDefaultNamedSpecifier !== void 0) {
33746
- this.raise(Errors.ImportJSONBindingNotDefault, nonDefaultNamedSpecifier.loc.start);
33747
- }
33748
- }
33749
33126
  }
33750
33127
  }
33751
33128
 
@@ -33761,10 +33138,6 @@ var StatementParser = class extends ExpressionParser {
33761
33138
  return;
33762
33139
  }
33763
33140
 
33764
- if (this.hasPlugin('importReflection')) {
33765
- node.module = false;
33766
- }
33767
-
33768
33141
  if (phase === 'source') {
33769
33142
  this.expectPlugin('sourcePhaseImports', loc);
33770
33143
  node.phase = 'source';
@@ -33830,8 +33203,7 @@ var StatementParser = class extends ExpressionParser {
33830
33203
  node.specifiers ?? (node.specifiers = []);
33831
33204
  node.source = this.parseImportSource();
33832
33205
  this.maybeParseImportAttributes(node);
33833
- this.checkImportReflection(node);
33834
- this.checkJSONModuleImport(node);
33206
+ this.checkImportPhase(node);
33835
33207
  this.semicolon();
33836
33208
  this.sawUnambiguousESM = true;
33837
33209
  return this.finishNode(node, 'ImportDeclaration');
@@ -33896,39 +33268,6 @@ var StatementParser = class extends ExpressionParser {
33896
33268
  return attrs;
33897
33269
  }
33898
33270
 
33899
- parseModuleAttributes() {
33900
- const attrs = [];
33901
- const attributes = /* @__PURE__ */new Set();
33902
-
33903
- do {
33904
- const node = this.startNode();
33905
-
33906
- node.key = this.parseIdentifier(true);
33907
-
33908
- if (node.key.name !== 'type') {
33909
- this.raise(Errors.ModuleAttributeDifferentFromType, node.key);
33910
- }
33911
-
33912
- if (attributes.has(node.key.name)) {
33913
- this.raise(Errors.ModuleAttributesWithDuplicateKeys, node.key, {
33914
- key: node.key.name,
33915
- });
33916
- }
33917
-
33918
- attributes.add(node.key.name);
33919
- this.expect(14);
33920
-
33921
- if (!this.match(134)) {
33922
- throw this.raise(Errors.ModuleAttributeInvalidValue, this.state.startLoc);
33923
- }
33924
-
33925
- node.value = this.parseStringLiteral(this.state.value);
33926
- attrs.push(this.finishNode(node, 'ImportAttribute'));
33927
- } while (this.eat(12))
33928
-
33929
- return attrs;
33930
- }
33931
-
33932
33271
  maybeParseImportAttributes(node) {
33933
33272
  let attributes;
33934
33273
 
@@ -34118,7 +33457,9 @@ var Parser = class extends StatementParser {
34118
33457
 
34119
33458
  function parse(input, options) {
34120
33459
  if (options?.sourceType === 'unambiguous') {
34121
- options = Object.assign({}, options);
33460
+ options = {
33461
+ ...options,
33462
+ };
34122
33463
  try {
34123
33464
  options.sourceType = 'module';
34124
33465
  const parser = getParser(options, input);
@@ -34228,8 +33569,518 @@ function getParserClass(pluginsMap) {
34228
33569
 
34229
33570
  // ../babel-babel/packages/babel-code-frame/lib/index.js
34230
33571
  var import_picocolors = __toESM(require_picocolors(), 1);
34231
- var import_js_tokens = __toESM(require_js_tokens(), 1);
34232
33572
 
33573
+ // ../babel-babel/node_modules/js-tokens/index.js
33574
+ var HashbangComment;
33575
+ var Identifier2;
33576
+ var JSXIdentifier2;
33577
+ var JSXPunctuator;
33578
+ var JSXString;
33579
+ var JSXText2;
33580
+ var KeywordsWithExpressionAfter;
33581
+ var KeywordsWithNoLineTerminatorAfter;
33582
+ var LineTerminatorSequence;
33583
+ var MultiLineComment;
33584
+ var Newline;
33585
+ var NumericLiteral2;
33586
+ var Punctuator;
33587
+ var RegularExpressionLiteral;
33588
+ var SingleLineComment;
33589
+ var StringLiteral2;
33590
+ var Template;
33591
+ var TokensNotPrecedingObjectLiteral;
33592
+ var TokensPrecedingExpression;
33593
+ var WhiteSpace;
33594
+ var jsTokens;
33595
+
33596
+ RegularExpressionLiteral = /\/(?![*\/])(?:\[(?:[^\]\\\n\r\u2028\u2029]+|\\.)*\]?|[^\/[\\\n\r\u2028\u2029]+|\\.)*(\/[$_\u200C\u200D\p{ID_Continue}]*|\\)?/yu;
33597
+ Punctuator = /--|\+\+|=>|\.{3}|\??\.(?!\d)|(?:&&|\|\||\?\?|[+\-%&|^]|\*{1,2}|<{1,2}|>{1,3}|!=?|={1,2}|\/(?![\/*]))=?|[?~,:;[\](){}]/y;
33598
+ Identifier2 = /(\x23?)(?=[$_\p{ID_Start}\\])(?:[$_\u200C\u200D\p{ID_Continue}]+|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]+\})+/yu;
33599
+ StringLiteral2 = /(['"])(?:[^'"\\\n\r]+|(?!\1)['"]|\\(?:\r\n|[^]))*(\1)?/y;
33600
+ NumericLiteral2 = /(?:0[xX][\da-fA-F](?:_?[\da-fA-F])*|0[oO][0-7](?:_?[0-7])*|0[bB][01](?:_?[01])*)n?|0n|[1-9](?:_?\d)*n|(?:(?:0(?!\d)|0\d*[89]\d*|[1-9](?:_?\d)*)(?:\.(?:\d(?:_?\d)*)?)?|\.\d(?:_?\d)*)(?:[eE][+-]?\d(?:_?\d)*)?|0[0-7]+/y;
33601
+ Template = /[`}](?:[^`\\$]+|\\[^]|\$(?!\{))*(`|\$\{)?/y;
33602
+ WhiteSpace = /[\t\v\f\ufeff\p{Zs}]+/yu;
33603
+ LineTerminatorSequence = /\r?\n|[\r\u2028\u2029]/y;
33604
+ MultiLineComment = /\/\*(?:[^*]+|\*(?!\/))*(\*\/)?/y;
33605
+ SingleLineComment = /\/\/.*/y;
33606
+ HashbangComment = /^#!.*/;
33607
+ JSXPunctuator = /[<>.:={}]|\/(?![\/*])/y;
33608
+ JSXIdentifier2 = /[$_\p{ID_Start}][$_\u200C\u200D\p{ID_Continue}-]*/yu;
33609
+ JSXString = /(['"])(?:[^'"]+|(?!\1)['"])*(\1)?/y;
33610
+ JSXText2 = /[^<>{}]+/y;
33611
+ TokensPrecedingExpression = /^(?:[\/+-]|\.{3}|\?(?:InterpolationIn(?:JSX|Template)|NoLineTerminatorHere|NonExpressionParenEnd|UnaryIncDec))?$|[{}([,;<>=*%&|^!~?:]$/;
33612
+ TokensNotPrecedingObjectLiteral = /^(?:=>|[;\]){}]|else|\?(?:NoLineTerminatorHere|NonExpressionParenEnd))?$/;
33613
+ KeywordsWithExpressionAfter = /^(?:await|case|default|delete|do|else|instanceof|new|return|throw|typeof|void|yield)$/;
33614
+ KeywordsWithNoLineTerminatorAfter = /^(?:return|throw|yield)$/;
33615
+ Newline = RegExp(LineTerminatorSequence.source);
33616
+ jsTokens = function*(input, {jsx: jsx2 = false} = {}) {
33617
+ var braces,
33618
+ firstCodePoint,
33619
+ isExpression4,
33620
+ lastIndex,
33621
+ lastSignificantToken,
33622
+ length,
33623
+ match,
33624
+ mode,
33625
+ nextLastIndex,
33626
+ nextLastSignificantToken,
33627
+ parenNesting,
33628
+ postfixIncDec,
33629
+ punctuator,
33630
+ stack;
33631
+
33632
+ ({length} = input);
33633
+ lastIndex = 0;
33634
+ lastSignificantToken = '';
33635
+ stack = [{
33636
+ tag: 'JS',
33637
+ }];
33638
+ braces = [];
33639
+ parenNesting = 0;
33640
+ postfixIncDec = false;
33641
+
33642
+ if (match = HashbangComment.exec(input)) {
33643
+ yield {
33644
+ type: 'HashbangComment',
33645
+ value: match[0],
33646
+ };
33647
+ lastIndex = match[0].length;
33648
+ }
33649
+
33650
+ while (lastIndex < length) {
33651
+ mode = stack[stack.length - 1];
33652
+ switch(mode.tag) {
33653
+ case 'JS':
33654
+ case 'JSNonExpressionParen':
33655
+ case 'InterpolationInTemplate':
33656
+ case 'InterpolationInJSX':
33657
+ if (input[lastIndex] === '/' && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken))) {
33658
+ RegularExpressionLiteral.lastIndex = lastIndex;
33659
+
33660
+ if (match = RegularExpressionLiteral.exec(input)) {
33661
+ lastIndex = RegularExpressionLiteral.lastIndex;
33662
+ lastSignificantToken = match[0];
33663
+ postfixIncDec = true;
33664
+ yield {
33665
+ type: 'RegularExpressionLiteral',
33666
+ value: match[0],
33667
+ closed: match[1] !== void 0 && match[1] !== '\\',
33668
+ };
33669
+ continue;
33670
+ }
33671
+ }
33672
+
33673
+ Punctuator.lastIndex = lastIndex;
33674
+
33675
+ if (match = Punctuator.exec(input)) {
33676
+ punctuator = match[0];
33677
+ nextLastIndex = Punctuator.lastIndex;
33678
+ nextLastSignificantToken = punctuator;
33679
+ switch(punctuator) {
33680
+ case '(':
33681
+ if (lastSignificantToken === '?NonExpressionParenKeyword') {
33682
+ stack.push({
33683
+ tag: 'JSNonExpressionParen',
33684
+ nesting: parenNesting,
33685
+ });
33686
+ }
33687
+
33688
+ parenNesting++;
33689
+ postfixIncDec = false;
33690
+ break;
33691
+
33692
+ case ')':
33693
+ parenNesting--;
33694
+ postfixIncDec = true;
33695
+
33696
+ if (mode.tag === 'JSNonExpressionParen' && parenNesting === mode.nesting) {
33697
+ stack.pop();
33698
+ nextLastSignificantToken = '?NonExpressionParenEnd';
33699
+ postfixIncDec = false;
33700
+ }
33701
+
33702
+ break;
33703
+
33704
+ case '{':
33705
+ Punctuator.lastIndex = 0;
33706
+ isExpression4 = !TokensNotPrecedingObjectLiteral.test(lastSignificantToken) && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken));
33707
+ braces.push(isExpression4);
33708
+ postfixIncDec = false;
33709
+ break;
33710
+
33711
+ case '}':
33712
+ switch(mode.tag) {
33713
+ case 'InterpolationInTemplate':
33714
+ if (braces.length === mode.nesting) {
33715
+ Template.lastIndex = lastIndex;
33716
+ match = Template.exec(input);
33717
+ lastIndex = Template.lastIndex;
33718
+ lastSignificantToken = match[0];
33719
+
33720
+ if (match[1] === '${') {
33721
+ lastSignificantToken = '?InterpolationInTemplate';
33722
+ postfixIncDec = false;
33723
+ yield {
33724
+ type: 'TemplateMiddle',
33725
+ value: match[0],
33726
+ };
33727
+ } else {
33728
+ stack.pop();
33729
+ postfixIncDec = true;
33730
+ yield {
33731
+ type: 'TemplateTail',
33732
+ value: match[0],
33733
+ closed: match[1] === '`',
33734
+ };
33735
+ }
33736
+
33737
+ continue;
33738
+ }
33739
+
33740
+ break;
33741
+
33742
+ case 'InterpolationInJSX':
33743
+ if (braces.length === mode.nesting) {
33744
+ stack.pop();
33745
+ lastIndex += 1;
33746
+ lastSignificantToken = '}';
33747
+ yield {
33748
+ type: 'JSXPunctuator',
33749
+ value: '}',
33750
+ };
33751
+ continue;
33752
+ }
33753
+ }
33754
+
33755
+ postfixIncDec = braces.pop();
33756
+ nextLastSignificantToken = postfixIncDec ? '?ExpressionBraceEnd' : '}';
33757
+ break;
33758
+
33759
+ case ']':
33760
+ postfixIncDec = true;
33761
+ break;
33762
+
33763
+ case '++':
33764
+ case '--':
33765
+ nextLastSignificantToken = postfixIncDec ? '?PostfixIncDec' : '?UnaryIncDec';
33766
+ break;
33767
+
33768
+ case '<':
33769
+ if (jsx2 && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken))) {
33770
+ stack.push({
33771
+ tag: 'JSXTag',
33772
+ });
33773
+ lastIndex += 1;
33774
+ lastSignificantToken = '<';
33775
+ yield {
33776
+ type: 'JSXPunctuator',
33777
+ value: punctuator,
33778
+ };
33779
+ continue;
33780
+ }
33781
+
33782
+ postfixIncDec = false;
33783
+ break;
33784
+
33785
+ default:
33786
+ postfixIncDec = false;
33787
+ }
33788
+
33789
+ lastIndex = nextLastIndex;
33790
+ lastSignificantToken = nextLastSignificantToken;
33791
+ yield {
33792
+ type: 'Punctuator',
33793
+ value: punctuator,
33794
+ };
33795
+ continue;
33796
+ }
33797
+
33798
+ Identifier2.lastIndex = lastIndex;
33799
+
33800
+ if (match = Identifier2.exec(input)) {
33801
+ lastIndex = Identifier2.lastIndex;
33802
+ nextLastSignificantToken = match[0];
33803
+ switch(match[0]) {
33804
+ case 'for':
33805
+ case 'if':
33806
+ case 'while':
33807
+ case 'with':
33808
+ if (lastSignificantToken !== '.' && lastSignificantToken !== '?.') {
33809
+ nextLastSignificantToken = '?NonExpressionParenKeyword';
33810
+ }
33811
+ }
33812
+
33813
+ lastSignificantToken = nextLastSignificantToken;
33814
+ postfixIncDec = !KeywordsWithExpressionAfter.test(match[0]);
33815
+ yield {
33816
+ type: match[1] === '#' ? 'PrivateIdentifier' : 'IdentifierName',
33817
+ value: match[0],
33818
+ };
33819
+ continue;
33820
+ }
33821
+
33822
+ StringLiteral2.lastIndex = lastIndex;
33823
+
33824
+ if (match = StringLiteral2.exec(input)) {
33825
+ lastIndex = StringLiteral2.lastIndex;
33826
+ lastSignificantToken = match[0];
33827
+ postfixIncDec = true;
33828
+ yield {
33829
+ type: 'StringLiteral',
33830
+ value: match[0],
33831
+ closed: match[2] !== void 0,
33832
+ };
33833
+ continue;
33834
+ }
33835
+
33836
+ NumericLiteral2.lastIndex = lastIndex;
33837
+
33838
+ if (match = NumericLiteral2.exec(input)) {
33839
+ lastIndex = NumericLiteral2.lastIndex;
33840
+ lastSignificantToken = match[0];
33841
+ postfixIncDec = true;
33842
+ yield {
33843
+ type: 'NumericLiteral',
33844
+ value: match[0],
33845
+ };
33846
+ continue;
33847
+ }
33848
+
33849
+ Template.lastIndex = lastIndex;
33850
+
33851
+ if (match = Template.exec(input)) {
33852
+ lastIndex = Template.lastIndex;
33853
+ lastSignificantToken = match[0];
33854
+
33855
+ if (match[1] === '${') {
33856
+ lastSignificantToken = '?InterpolationInTemplate';
33857
+ stack.push({
33858
+ tag: 'InterpolationInTemplate',
33859
+ nesting: braces.length,
33860
+ });
33861
+ postfixIncDec = false;
33862
+ yield {
33863
+ type: 'TemplateHead',
33864
+ value: match[0],
33865
+ };
33866
+ } else {
33867
+ postfixIncDec = true;
33868
+ yield {
33869
+ type: 'NoSubstitutionTemplate',
33870
+ value: match[0],
33871
+ closed: match[1] === '`',
33872
+ };
33873
+ }
33874
+
33875
+ continue;
33876
+ }
33877
+
33878
+ break;
33879
+
33880
+ case 'JSXTag':
33881
+ case 'JSXTagEnd':
33882
+ JSXPunctuator.lastIndex = lastIndex;
33883
+
33884
+ if (match = JSXPunctuator.exec(input)) {
33885
+ lastIndex = JSXPunctuator.lastIndex;
33886
+ nextLastSignificantToken = match[0];
33887
+ switch(match[0]) {
33888
+ case '<':
33889
+ stack.push({
33890
+ tag: 'JSXTag',
33891
+ });
33892
+ break;
33893
+
33894
+ case '>':
33895
+ stack.pop();
33896
+
33897
+ if (lastSignificantToken === '/' || mode.tag === 'JSXTagEnd') {
33898
+ nextLastSignificantToken = '?JSX';
33899
+ postfixIncDec = true;
33900
+ } else {
33901
+ stack.push({
33902
+ tag: 'JSXChildren',
33903
+ });
33904
+ }
33905
+
33906
+ break;
33907
+
33908
+ case '{':
33909
+ stack.push({
33910
+ tag: 'InterpolationInJSX',
33911
+ nesting: braces.length,
33912
+ });
33913
+ nextLastSignificantToken = '?InterpolationInJSX';
33914
+ postfixIncDec = false;
33915
+ break;
33916
+
33917
+ case '/':
33918
+ if (lastSignificantToken === '<') {
33919
+ stack.pop();
33920
+
33921
+ if (stack[stack.length - 1].tag === 'JSXChildren') {
33922
+ stack.pop();
33923
+ }
33924
+
33925
+ stack.push({
33926
+ tag: 'JSXTagEnd',
33927
+ });
33928
+ }
33929
+ }
33930
+
33931
+ lastSignificantToken = nextLastSignificantToken;
33932
+ yield {
33933
+ type: 'JSXPunctuator',
33934
+ value: match[0],
33935
+ };
33936
+ continue;
33937
+ }
33938
+
33939
+ JSXIdentifier2.lastIndex = lastIndex;
33940
+
33941
+ if (match = JSXIdentifier2.exec(input)) {
33942
+ lastIndex = JSXIdentifier2.lastIndex;
33943
+ lastSignificantToken = match[0];
33944
+ yield {
33945
+ type: 'JSXIdentifier',
33946
+ value: match[0],
33947
+ };
33948
+ continue;
33949
+ }
33950
+
33951
+ JSXString.lastIndex = lastIndex;
33952
+
33953
+ if (match = JSXString.exec(input)) {
33954
+ lastIndex = JSXString.lastIndex;
33955
+ lastSignificantToken = match[0];
33956
+ yield {
33957
+ type: 'JSXString',
33958
+ value: match[0],
33959
+ closed: match[2] !== void 0,
33960
+ };
33961
+ continue;
33962
+ }
33963
+
33964
+ break;
33965
+
33966
+ case 'JSXChildren':
33967
+ JSXText2.lastIndex = lastIndex;
33968
+
33969
+ if (match = JSXText2.exec(input)) {
33970
+ lastIndex = JSXText2.lastIndex;
33971
+ lastSignificantToken = match[0];
33972
+ yield {
33973
+ type: 'JSXText',
33974
+ value: match[0],
33975
+ };
33976
+ continue;
33977
+ }
33978
+
33979
+ switch(input[lastIndex]) {
33980
+ case '<':
33981
+ stack.push({
33982
+ tag: 'JSXTag',
33983
+ });
33984
+ lastIndex++;
33985
+ lastSignificantToken = '<';
33986
+ yield {
33987
+ type: 'JSXPunctuator',
33988
+ value: '<',
33989
+ };
33990
+ continue;
33991
+
33992
+ case '{':
33993
+ stack.push({
33994
+ tag: 'InterpolationInJSX',
33995
+ nesting: braces.length,
33996
+ });
33997
+ lastIndex++;
33998
+ lastSignificantToken = '?InterpolationInJSX';
33999
+ postfixIncDec = false;
34000
+ yield {
34001
+ type: 'JSXPunctuator',
34002
+ value: '{',
34003
+ };
34004
+ continue;
34005
+ }
34006
+ }
34007
+
34008
+ WhiteSpace.lastIndex = lastIndex;
34009
+
34010
+ if (match = WhiteSpace.exec(input)) {
34011
+ lastIndex = WhiteSpace.lastIndex;
34012
+ yield {
34013
+ type: 'WhiteSpace',
34014
+ value: match[0],
34015
+ };
34016
+ continue;
34017
+ }
34018
+
34019
+ LineTerminatorSequence.lastIndex = lastIndex;
34020
+
34021
+ if (match = LineTerminatorSequence.exec(input)) {
34022
+ lastIndex = LineTerminatorSequence.lastIndex;
34023
+ postfixIncDec = false;
34024
+
34025
+ if (KeywordsWithNoLineTerminatorAfter.test(lastSignificantToken)) {
34026
+ lastSignificantToken = '?NoLineTerminatorHere';
34027
+ }
34028
+
34029
+ yield {
34030
+ type: 'LineTerminatorSequence',
34031
+ value: match[0],
34032
+ };
34033
+ continue;
34034
+ }
34035
+
34036
+ MultiLineComment.lastIndex = lastIndex;
34037
+
34038
+ if (match = MultiLineComment.exec(input)) {
34039
+ lastIndex = MultiLineComment.lastIndex;
34040
+
34041
+ if (Newline.test(match[0])) {
34042
+ postfixIncDec = false;
34043
+
34044
+ if (KeywordsWithNoLineTerminatorAfter.test(lastSignificantToken)) {
34045
+ lastSignificantToken = '?NoLineTerminatorHere';
34046
+ }
34047
+ }
34048
+
34049
+ yield {
34050
+ type: 'MultiLineComment',
34051
+ value: match[0],
34052
+ closed: match[1] !== void 0,
34053
+ };
34054
+ continue;
34055
+ }
34056
+
34057
+ SingleLineComment.lastIndex = lastIndex;
34058
+
34059
+ if (match = SingleLineComment.exec(input)) {
34060
+ lastIndex = SingleLineComment.lastIndex;
34061
+ postfixIncDec = false;
34062
+ yield {
34063
+ type: 'SingleLineComment',
34064
+ value: match[0],
34065
+ };
34066
+ continue;
34067
+ }
34068
+
34069
+ firstCodePoint = String.fromCodePoint(input.codePointAt(lastIndex));
34070
+ lastIndex += firstCodePoint.length;
34071
+ lastSignificantToken = firstCodePoint;
34072
+ postfixIncDec = false;
34073
+ yield {
34074
+ type: mode.tag.startsWith('JSX') ? 'JSXInvalid' : 'Invalid',
34075
+ value: firstCodePoint,
34076
+ };
34077
+ }
34078
+
34079
+ return void 0;
34080
+ };
34081
+ var js_tokens_default = jsTokens;
34082
+
34083
+ // ../babel-babel/packages/babel-code-frame/lib/index.js
34233
34084
  function isColorSupported() {
34234
34085
  return typeof process === 'object' && (process.env.FORCE_COLOR === '0' || process.env.FORCE_COLOR === 'false') ? false : import_picocolors.default.isColorSupported;
34235
34086
  }
@@ -34336,7 +34187,7 @@ var getTokenType = function(token) {
34336
34187
  };
34337
34188
 
34338
34189
  function* tokenize(text) {
34339
- for (const token of (0, import_js_tokens.default)(text, {jsx: true})) {
34190
+ for (const token of js_tokens_default(text, {jsx: true})) {
34340
34191
  switch(token.type) {
34341
34192
  case 'TemplateHead':
34342
34193
  yield {
@@ -34408,12 +34259,17 @@ function highlight(text) {
34408
34259
  var NEWLINE = /\r\n|[\n\r\u2028\u2029]/;
34409
34260
 
34410
34261
  function getMarkerLines(loc, source, opts) {
34411
- const startLoc = Object.assign({
34262
+ const startLoc = {
34412
34263
  column: 0,
34413
34264
  line: -1,
34414
- }, loc.start);
34265
+ ...loc.start,
34266
+ };
34267
+
34268
+ const endLoc = {
34269
+ ...startLoc,
34270
+ ...loc.end,
34271
+ };
34415
34272
 
34416
- const endLoc = Object.assign({}, startLoc, loc.end);
34417
34273
  const {linesAbove = 2, linesBelow = 3} = opts || {};
34418
34274
 
34419
34275
  const startLine = startLoc.line;
@@ -34611,29 +34467,6 @@ var program$1 = {
34611
34467
  unwrap: (ast) => ast.program,
34612
34468
  };
34613
34469
 
34614
- function _objectWithoutPropertiesLoose2(r, e) {
34615
- if (null == r)
34616
- return {};
34617
-
34618
- var t = {};
34619
-
34620
- for (var n2 in r) if ({}.hasOwnProperty.call(r, n2)) {
34621
- if (-1 !== e.indexOf(n2))
34622
- continue;
34623
-
34624
- t[n2] = r[n2];
34625
- }
34626
-
34627
- return t;
34628
- }
34629
-
34630
- var _excluded2 = [
34631
- 'placeholderWhitelist',
34632
- 'placeholderPattern',
34633
- 'preserveComments',
34634
- 'syntacticPlaceholders',
34635
- ];
34636
-
34637
34470
  function merge(a, b2) {
34638
34471
  const {
34639
34472
  placeholderWhitelist = a.placeholderWhitelist,
@@ -34643,7 +34476,10 @@ function merge(a, b2) {
34643
34476
  } = b2;
34644
34477
 
34645
34478
  return {
34646
- parser: Object.assign({}, a.parser, b2.parser),
34479
+ parser: {
34480
+ ...a.parser,
34481
+ ...b2.parser,
34482
+ },
34647
34483
  placeholderWhitelist,
34648
34484
  placeholderPattern,
34649
34485
  preserveComments,
@@ -34656,12 +34492,13 @@ function validate$12(opts) {
34656
34492
  throw new Error('Unknown template options.');
34657
34493
  }
34658
34494
 
34659
- const _ref = opts || {}, {
34660
- placeholderWhitelist,
34661
- placeholderPattern,
34662
- preserveComments,
34663
- syntacticPlaceholders,
34664
- } = _ref, parser = _objectWithoutPropertiesLoose2(_ref, _excluded2);
34495
+ const {
34496
+ placeholderWhitelist,
34497
+ placeholderPattern,
34498
+ preserveComments,
34499
+ syntacticPlaceholders,
34500
+ ...parser
34501
+ } = opts || {};
34665
34502
 
34666
34503
  if (placeholderWhitelist != null && !(placeholderWhitelist instanceof Set)) {
34667
34504
  throw new Error('\'.placeholderWhitelist\' must be a Set, null, or undefined');
@@ -34750,9 +34587,10 @@ function parseAndBuildMetadata(formatter, code2, opts) {
34750
34587
  };
34751
34588
 
34752
34589
  traverse2(ast, placeholderVisitorHandler, state);
34753
- return Object.assign({
34590
+ return {
34754
34591
  ast,
34755
- }, state.syntactic.placeholders.length ? state.syntactic : state.legacy);
34592
+ ...state.syntactic.placeholders.length ? state.syntactic : state.legacy,
34593
+ };
34756
34594
  }
34757
34595
 
34758
34596
  function placeholderVisitorHandler(node, ancestors, state) {
@@ -34847,16 +34685,16 @@ function parseWithCodeFrame(code2, parserOpts, syntacticPlaceholders) {
34847
34685
  plugins.push('placeholders');
34848
34686
  }
34849
34687
 
34850
- parserOpts = Object.assign({
34688
+ parserOpts = {
34851
34689
  allowAwaitOutsideFunction: true,
34852
34690
  allowReturnOutsideFunction: true,
34853
34691
  allowNewTargetOutsideFunction: true,
34854
34692
  allowSuperOutsideMethod: true,
34855
34693
  allowYieldOutsideFunction: true,
34856
34694
  sourceType: 'module',
34857
- }, parserOpts, {
34695
+ ...parserOpts,
34858
34696
  plugins,
34859
- });
34697
+ };
34860
34698
  try {
34861
34699
  return parse(code2, parserOpts);
34862
34700
  } catch(err) {
@@ -37816,7 +37654,7 @@ function NewExpression2(node, parent) {
37816
37654
  this.space();
37817
37655
  this.print(node.callee);
37818
37656
 
37819
- if (this.format.minified && node.arguments.length === 0 && !node.optional && !isCallExpression3(parent, {callee: node}) && !isMemberExpression2(parent) && !isNewExpression3(parent)) {
37657
+ if (this.format.minified && node.arguments.length === 0 && !isCallExpression3(parent, {callee: node}) && !isMemberExpression2(parent) && !isNewExpression3(parent)) {
37820
37658
  return;
37821
37659
  }
37822
37660
 
@@ -37846,10 +37684,6 @@ function Super2() {
37846
37684
  }
37847
37685
 
37848
37686
  function _shouldPrintDecoratorsBeforeExport(node) {
37849
- if (typeof this.format.decoratorsBeforeExport === 'boolean') {
37850
- return this.format.decoratorsBeforeExport;
37851
- }
37852
-
37853
37687
  return typeof node.start === 'number' && node.start === node.declaration.start;
37854
37688
  }
37855
37689
 
@@ -38053,6 +37887,7 @@ var {
38053
37887
  isForStatement: isForStatement2,
38054
37888
  isIfStatement: isIfStatement2,
38055
37889
  isStatement: isStatement$3,
37890
+ isVoidPattern: isVoidPattern2,
38056
37891
  } = lib_exports;
38057
37892
 
38058
37893
  function WithStatement2(node) {
@@ -38340,7 +38175,9 @@ function VariableDeclarator2(node) {
38340
38175
  if (node.definite)
38341
38176
  this.tokenChar(33);
38342
38177
 
38343
- this.print(node.id.typeAnnotation);
38178
+ if (!isVoidPattern2(node.id)) {
38179
+ this.print(node.id.typeAnnotation);
38180
+ }
38344
38181
 
38345
38182
  if (node.init) {
38346
38183
  this.space();
@@ -39156,7 +38993,7 @@ function _getRawIdentifier(node) {
39156
38993
  return lastRawIdentResult = node.name;
39157
38994
  }
39158
38995
 
39159
- function Identifier2(node) {
38996
+ function Identifier3(node) {
39160
38997
  this.sourceIdentifierName(node.loc?.identifierName || node.name);
39161
38998
  this.word(this.tokenMap ? this._getRawIdentifier(node) : node.name);
39162
38999
  }
@@ -39257,7 +39094,7 @@ function NullLiteral2() {
39257
39094
  this.word('null');
39258
39095
  }
39259
39096
 
39260
- function NumericLiteral2(node) {
39097
+ function NumericLiteral3(node) {
39261
39098
  const raw = this.getPossibleRaw(node);
39262
39099
  const opts = this.format.jsescOption;
39263
39100
  const value = node.value;
@@ -39275,7 +39112,7 @@ function NumericLiteral2(node) {
39275
39112
 
39276
39113
  }
39277
39114
 
39278
- function StringLiteral2(node) {
39115
+ function StringLiteral3(node) {
39279
39116
  const raw = this.getPossibleRaw(node);
39280
39117
 
39281
39118
  if (!this.format.minified && raw !== void 0) {
@@ -39378,7 +39215,7 @@ function DeclareFunction2(node, parent) {
39378
39215
  this.word('function');
39379
39216
  this.space();
39380
39217
  this.print(node.id);
39381
- this.print(node.id.typeAnnotation.typeAnnotation);
39218
+ this.print(node.id.typeAnnotation?.typeAnnotation);
39382
39219
 
39383
39220
  if (node.predicate) {
39384
39221
  this.space();
@@ -40098,7 +39935,7 @@ function JSXAttribute2(node) {
40098
39935
  }
40099
39936
  }
40100
39937
 
40101
- function JSXIdentifier2(node) {
39938
+ function JSXIdentifier3(node) {
40102
39939
  this.word(node.name);
40103
39940
  }
40104
39941
 
@@ -40134,7 +39971,7 @@ function JSXSpreadChild2(node) {
40134
39971
  this.rightBrace(node);
40135
39972
  }
40136
39973
 
40137
- function JSXText2(node) {
39974
+ function JSXText3(node) {
40138
39975
  const raw = this.getPossibleRaw(node);
40139
39976
 
40140
39977
  if (raw !== void 0) {
@@ -41040,7 +40877,7 @@ var generatorFunctions = /* @__PURE__ */Object.freeze({
41040
40877
  FunctionTypeAnnotation: FunctionTypeAnnotation2,
41041
40878
  FunctionTypeParam: FunctionTypeParam2,
41042
40879
  GenericTypeAnnotation: InterfaceExtends2,
41043
- Identifier: Identifier2,
40880
+ Identifier: Identifier3,
41044
40881
  IfStatement: IfStatement2,
41045
40882
  Import: Import2,
41046
40883
  ImportAttribute: ImportAttribute2,
@@ -41063,14 +40900,14 @@ var generatorFunctions = /* @__PURE__ */Object.freeze({
41063
40900
  JSXEmptyExpression: JSXEmptyExpression2,
41064
40901
  JSXExpressionContainer: JSXExpressionContainer2,
41065
40902
  JSXFragment: JSXFragment2,
41066
- JSXIdentifier: JSXIdentifier2,
40903
+ JSXIdentifier: JSXIdentifier3,
41067
40904
  JSXMemberExpression: JSXMemberExpression2,
41068
40905
  JSXNamespacedName: JSXNamespacedName2,
41069
40906
  JSXOpeningElement: JSXOpeningElement2,
41070
40907
  JSXOpeningFragment: JSXOpeningFragment2,
41071
40908
  JSXSpreadAttribute: JSXSpreadAttribute2,
41072
40909
  JSXSpreadChild: JSXSpreadChild2,
41073
- JSXText: JSXText2,
40910
+ JSXText: JSXText3,
41074
40911
  LabeledStatement: LabeledStatement2,
41075
40912
  LogicalExpression: AssignmentExpression2,
41076
40913
  MemberExpression: MemberExpression2,
@@ -41081,9 +40918,9 @@ var generatorFunctions = /* @__PURE__ */Object.freeze({
41081
40918
  NullLiteral: NullLiteral2,
41082
40919
  NullLiteralTypeAnnotation: NullLiteralTypeAnnotation2,
41083
40920
  NullableTypeAnnotation: NullableTypeAnnotation2,
41084
- NumberLiteralTypeAnnotation: NumericLiteral2,
40921
+ NumberLiteralTypeAnnotation: NumericLiteral3,
41085
40922
  NumberTypeAnnotation: NumberTypeAnnotation2,
41086
- NumericLiteral: NumericLiteral2,
40923
+ NumericLiteral: NumericLiteral3,
41087
40924
  ObjectExpression: ObjectExpression2,
41088
40925
  ObjectMethod: ObjectMethod2,
41089
40926
  ObjectPattern: ObjectExpression2,
@@ -41112,8 +40949,8 @@ var generatorFunctions = /* @__PURE__ */Object.freeze({
41112
40949
  SequenceExpression: SequenceExpression2,
41113
40950
  SpreadElement: RestElement2,
41114
40951
  StaticBlock: StaticBlock2,
41115
- StringLiteral: StringLiteral2,
41116
- StringLiteralTypeAnnotation: StringLiteral2,
40952
+ StringLiteral: StringLiteral3,
40953
+ StringLiteralTypeAnnotation: StringLiteral3,
41117
40954
  StringTypeAnnotation: StringTypeAnnotation2,
41118
40955
  Super: Super2,
41119
40956
  SwitchCase: SwitchCase2,
@@ -42311,11 +42148,12 @@ function normalizeOptions(code2, opts, ast) {
42311
42148
  adjustMultilineComment: true,
42312
42149
  style: ' ',
42313
42150
  },
42314
- jsescOption: Object.assign({
42151
+ jsescOption: {
42315
42152
  quotes: 'double',
42316
42153
  wrap: true,
42317
42154
  minimal: true,
42318
- }, opts.jsescOption),
42155
+ ...opts.jsescOption,
42156
+ },
42319
42157
  topicToken: opts.topicToken,
42320
42158
  };
42321
42159
 
@@ -42860,7 +42698,9 @@ function explode$1(visitor) {
42860
42698
  if (existing) {
42861
42699
  mergePair(existing, fns);
42862
42700
  } else {
42863
- visitor[alias2] = Object.assign({}, fns);
42701
+ visitor[alias2] = {
42702
+ ...fns,
42703
+ };
42864
42704
  }
42865
42705
  }
42866
42706
  }
@@ -42892,7 +42732,7 @@ function verify$1(visitor) {
42892
42732
  continue;
42893
42733
 
42894
42734
  if (!TYPES2.includes(nodeType)) {
42895
- throw new Error(`You gave us a visitor for the node type ${nodeType} but it's not a valid type in @babel/traverse ${'8.0.0-beta.3'}`);
42735
+ throw new Error(`You gave us a visitor for the node type ${nodeType} but it's not a valid type in @babel/traverse ${'7.28.5'}`);
42896
42736
  }
42897
42737
 
42898
42738
  const visitors2 = visitor[nodeType];
@@ -43211,8 +43051,8 @@ function traverseForScope(path, visitors2, state) {
43211
43051
  throw new Error('Should not be used with enter/exit visitors.');
43212
43052
  }
43213
43053
 
43214
- _traverse2(path.parentPath, path.parent, path.node, path.container, path.key, path.listKey, path.hub, path);
43215
- function _traverse2(parentPath, parent, node, container, key, listKey, hub, inPath) {
43054
+ _traverse(path.parentPath, path.parent, path.node, path.container, path.key, path.listKey, path.hub, path);
43055
+ function _traverse(parentPath, parent, node, container, key, listKey, hub, inPath) {
43216
43056
  if (!node) {
43217
43057
  return;
43218
43058
  }
@@ -43254,10 +43094,10 @@ function traverseForScope(path, visitors2, state) {
43254
43094
  if (Array.isArray(prop)) {
43255
43095
  for (let i = 0; i < prop.length; i++) {
43256
43096
  const value = prop[i];
43257
- _traverse2(path2, node, value, prop, i, key2);
43097
+ _traverse(path2, node, value, prop, i, key2);
43258
43098
  }
43259
43099
  } else {
43260
- _traverse2(path2, node, prop, node, key2, null);
43100
+ _traverse(path2, node, prop, node, key2, null);
43261
43101
  }
43262
43102
  }
43263
43103
 
@@ -45093,11 +44933,11 @@ function UpdateExpression3(node) {
45093
44933
  }
45094
44934
  }
45095
44935
 
45096
- function StringLiteral3() {
44936
+ function StringLiteral4() {
45097
44937
  return stringTypeAnnotation$1();
45098
44938
  }
45099
44939
 
45100
- function NumericLiteral3() {
44940
+ function NumericLiteral4() {
45101
44941
  return numberTypeAnnotation2();
45102
44942
  }
45103
44943
 
@@ -45194,13 +45034,13 @@ var inferers = /* @__PURE__ */Object.freeze({
45194
45034
  LogicalExpression: LogicalExpression3,
45195
45035
  NewExpression: NewExpression3,
45196
45036
  NullLiteral: NullLiteral3,
45197
- NumericLiteral: NumericLiteral3,
45037
+ NumericLiteral: NumericLiteral4,
45198
45038
  ObjectExpression: ObjectExpression3,
45199
45039
  ParenthesizedExpression: ParenthesizedExpression3,
45200
45040
  RegExpLiteral: RegExpLiteral3,
45201
45041
  RestElement: RestElement3,
45202
45042
  SequenceExpression: SequenceExpression3,
45203
- StringLiteral: StringLiteral3,
45043
+ StringLiteral: StringLiteral4,
45204
45044
  TSAsExpression: TSAsExpression3,
45205
45045
  TSNonNullExpression: TSNonNullExpression3,
45206
45046
  TaggedTemplateExpression: TaggedTemplateExpression3,
@@ -46710,8 +46550,9 @@ function arrowFunctionToExpression({allowInsertArrow = true, allowInsertArrowWit
46710
46550
  }
46711
46551
 
46712
46552
  fn.get('body').unshiftContainer('body', expressionStatement3(callExpression2(this.hub.addHelper('newArrowCheck'), [thisExpression2(), checkBinding ? identifier3(checkBinding.name) : identifier3(thisBinding)])));
46713
- fn.replaceWith(callExpression2(memberExpression2(fn.node, identifier3('bind')), [checkBinding ? identifier3(checkBinding.name) : thisExpression2()]));
46714
- return fn.get('callee.object');
46553
+ return fn
46554
+ .replaceWith(callExpression2(memberExpression2(fn.node, identifier3('bind')), [checkBinding ? identifier3(checkBinding.name) : thisExpression2()]))[0]
46555
+ .get('callee.object');
46715
46556
  }
46716
46557
 
46717
46558
  return fn;
@@ -46752,8 +46593,9 @@ function hoistFunctionEnvironment(fnPath, noNewArrows = true, allowInsertArrow =
46752
46593
  if (arrowParent) {
46753
46594
  thisEnvFn = arrowParent;
46754
46595
  } else if (allowInsertArrow) {
46755
- fnPath.replaceWith(callExpression2(arrowFunctionExpression2([], toExpression2(fnPath.node)), []));
46756
- thisEnvFn = fnPath.get('callee');
46596
+ thisEnvFn = fnPath
46597
+ .replaceWith(callExpression2(arrowFunctionExpression2([], toExpression2(fnPath.node)), []))[0]
46598
+ .get('callee');
46757
46599
  fnPath = thisEnvFn.get('body');
46758
46600
  } else {
46759
46601
  throw fnPath.buildCodeFrameError('Unable to transform arrow inside class property');
@@ -46865,8 +46707,9 @@ function hoistFunctionEnvironment(fnPath, noNewArrows = true, allowInsertArrow =
46865
46707
  } else if (isAssignment) {
46866
46708
  superParentPath.replaceWith(call2);
46867
46709
  } else if (isTaggedTemplate) {
46868
- superProp.replaceWith(callExpression2(memberExpression2(call2, identifier3('bind'), false), [thisExpression2()]));
46869
- thisPaths.push(superProp.get('arguments.0'));
46710
+ thisPaths.push(superProp
46711
+ .replaceWith(callExpression2(memberExpression2(call2, identifier3('bind'), false), [thisExpression2()]))[0]
46712
+ .get('arguments.0'));
46870
46713
  } else {
46871
46714
  superProp.replaceWith(call2);
46872
46715
  }
@@ -46945,9 +46788,9 @@ function standardizeSuperProperty(superProp) {
46945
46788
  parts.push(identifier3(tmp.name));
46946
46789
  }
46947
46790
 
46948
- updateExpr.replaceWith(sequenceExpression2(parts));
46949
- const left = updateExpr.get('expressions.0.right');
46950
- const right = updateExpr.get('expressions.1.left');
46791
+ const sequenceExpr = updateExpr.replaceWith(sequenceExpression2(parts))[0];
46792
+ const left = sequenceExpr.get('expressions.0.right');
46793
+ const right = sequenceExpr.get('expressions.1.left');
46951
46794
 
46952
46795
  return [left, right];
46953
46796
  }
@@ -47892,9 +47735,10 @@ function getStatementListCompletion(paths, context) {
47892
47735
 
47893
47736
  for (let i = 0; i < paths.length; i++) {
47894
47737
  const path = paths[i];
47895
- const newContext = Object.assign({}, context, {
47738
+ const newContext = {
47739
+ ...context,
47896
47740
  inCaseClause: false,
47897
- });
47741
+ };
47898
47742
 
47899
47743
  if (path.isBlockStatement() && (context.inCaseClause || context.shouldPopulateBreak)) {
47900
47744
  newContext.shouldPopulateBreak = true;
@@ -48730,7 +48574,7 @@ function _visit(ctx, path) {
48730
48574
  }
48731
48575
 
48732
48576
  const opts = ctx.opts;
48733
- const denylist = opts.denylist ?? opts.blacklist;
48577
+ const denylist = opts.denylist;
48734
48578
 
48735
48579
  if (denylist?.includes(node.type)) {
48736
48580
  return false;
@@ -48751,7 +48595,7 @@ function _visit(ctx, path) {
48751
48595
  return path.shouldStop;
48752
48596
  }
48753
48597
 
48754
- path.shouldStop = _traverse(path.node, opts, path.scope, ctx.state, path, path.skipKeys);
48598
+ path.shouldStop = traverseNode(path.node, opts, path.scope, ctx.state, path, path.skipKeys);
48755
48599
 
48756
48600
  if (path.node) {
48757
48601
  if (_call.call(path, opts.exit))
@@ -48765,7 +48609,7 @@ function _visit(ctx, path) {
48765
48609
  return path.shouldStop;
48766
48610
  }
48767
48611
 
48768
- function _traverse(node, opts, scope2, state, path, skipKeys, visitSelf) {
48612
+ function traverseNode(node, opts, scope2, state, path, skipKeys, visitSelf) {
48769
48613
  const keys2 = VISITOR_KEYS$12[node.type];
48770
48614
 
48771
48615
  if (!keys2?.length)
@@ -48821,10 +48665,6 @@ function _traverse(node, opts, scope2, state, path, skipKeys, visitSelf) {
48821
48665
  return false;
48822
48666
  }
48823
48667
 
48824
- function traverseNode(node, opts, scope2, state, path, skipKeys, visitSelf) {
48825
- return _traverse(node, opts, scope2, state, path, skipKeys, visitSelf);
48826
- }
48827
-
48828
48668
  function call(key) {
48829
48669
  const opts = this.opts;
48830
48670
  this.debug(key);
@@ -48875,8 +48715,7 @@ function _call(fns) {
48875
48715
  }
48876
48716
 
48877
48717
  function isDenylisted() {
48878
- const denylist = this.opts.denylist ?? this.opts.blacklist;
48879
- return denylist?.includes(this.node.type);
48718
+ return !!this.opts.denylist?.includes(this.node.type);
48880
48719
  }
48881
48720
 
48882
48721
  function restoreContext(path, context) {