hermes-transform 0.8.0 → 0.9.0

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.
@@ -35,7 +35,6 @@ var _exportNames = {
35
35
  CatchClause: true,
36
36
  ChainExpression: true,
37
37
  ClassBody: true,
38
- ClassDeclaration: true,
39
38
  ClassExpression: true,
40
39
  ClassImplements: true,
41
40
  ConditionalExpression: true,
@@ -183,7 +182,6 @@ exports.CallExpression = CallExpression;
183
182
  exports.CatchClause = CatchClause;
184
183
  exports.ChainExpression = ChainExpression;
185
184
  exports.ClassBody = ClassBody;
186
- exports.ClassDeclaration = ClassDeclaration;
187
185
  exports.ClassExpression = ClassExpression;
188
186
  exports.ClassImplements = ClassImplements;
189
187
  exports.ConditionalExpression = ConditionalExpression;
@@ -325,1689 +323,1466 @@ Object.keys(_specialCaseNodeTypes).forEach(function (key) {
325
323
  exports[key] = _specialCaseNodeTypes[key];
326
324
  });
327
325
 
328
- function AnyTypeAnnotation({
329
- parent
330
- } = {}) {
331
- return (0, _detachedNode.detachedProps)(parent, {
326
+ function AnyTypeAnnotation(props = { ...null
327
+ }) {
328
+ return (0, _detachedNode.detachedProps)(props.parent, {
332
329
  type: 'AnyTypeAnnotation'
333
330
  });
334
331
  }
335
332
 
336
- function ArrayExpression({
337
- parent,
338
- ...props
339
- }) {
340
- const node = (0, _detachedNode.detachedProps)(parent, {
333
+ function ArrayExpression(props) {
334
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
341
335
  type: 'ArrayExpression',
342
- ...props
336
+ elements: props.elements.map(n => (0, _detachedNode.asDetachedNode)(n)),
337
+ trailingComma: props.trailingComma
343
338
  });
344
339
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
345
340
  return node;
346
341
  }
347
342
 
348
- function ArrayPattern({
349
- parent,
350
- ...props
351
- }) {
352
- const node = (0, _detachedNode.detachedProps)(parent, {
343
+ function ArrayPattern(props) {
344
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
353
345
  type: 'ArrayPattern',
354
- ...props
346
+ elements: props.elements.map(n => (0, _detachedNode.asDetachedNode)(n)),
347
+ typeAnnotation: (0, _detachedNode.asDetachedNode)(props.typeAnnotation)
355
348
  });
356
349
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
357
350
  return node;
358
351
  }
359
352
 
360
- function ArrayTypeAnnotation({
361
- parent,
362
- ...props
363
- }) {
364
- const node = (0, _detachedNode.detachedProps)(parent, {
353
+ function ArrayTypeAnnotation(props) {
354
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
365
355
  type: 'ArrayTypeAnnotation',
366
- ...props
356
+ elementType: (0, _detachedNode.asDetachedNode)(props.elementType)
367
357
  });
368
358
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
369
359
  return node;
370
360
  }
371
361
 
372
- function AssignmentExpression({
373
- parent,
374
- ...props
375
- }) {
376
- const node = (0, _detachedNode.detachedProps)(parent, {
362
+ function AssignmentExpression(props) {
363
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
377
364
  type: 'AssignmentExpression',
378
- ...props
365
+ operator: props.operator,
366
+ left: (0, _detachedNode.asDetachedNode)(props.left),
367
+ right: (0, _detachedNode.asDetachedNode)(props.right)
379
368
  });
380
369
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
381
370
  return node;
382
371
  }
383
372
 
384
- function AssignmentPattern({
385
- parent,
386
- ...props
387
- }) {
388
- const node = (0, _detachedNode.detachedProps)(parent, {
373
+ function AssignmentPattern(props) {
374
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
389
375
  type: 'AssignmentPattern',
390
- ...props
376
+ left: (0, _detachedNode.asDetachedNode)(props.left),
377
+ right: (0, _detachedNode.asDetachedNode)(props.right)
391
378
  });
392
379
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
393
380
  return node;
394
381
  }
395
382
 
396
- function AwaitExpression({
397
- parent,
398
- ...props
399
- }) {
400
- const node = (0, _detachedNode.detachedProps)(parent, {
383
+ function AwaitExpression(props) {
384
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
401
385
  type: 'AwaitExpression',
402
- ...props
386
+ argument: (0, _detachedNode.asDetachedNode)(props.argument)
403
387
  });
404
388
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
405
389
  return node;
406
390
  }
407
391
 
408
- function BigIntLiteralTypeAnnotation({
409
- parent,
410
- ...props
411
- }) {
412
- const node = (0, _detachedNode.detachedProps)(parent, {
392
+ function BigIntLiteralTypeAnnotation(props) {
393
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
413
394
  type: 'BigIntLiteralTypeAnnotation',
414
- ...props
395
+ raw: props.raw
415
396
  });
416
397
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
417
398
  return node;
418
399
  }
419
400
 
420
- function BinaryExpression({
421
- parent,
422
- ...props
423
- }) {
424
- const node = (0, _detachedNode.detachedProps)(parent, {
401
+ function BinaryExpression(props) {
402
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
425
403
  type: 'BinaryExpression',
426
- ...props
404
+ left: (0, _detachedNode.asDetachedNode)(props.left),
405
+ right: (0, _detachedNode.asDetachedNode)(props.right),
406
+ operator: props.operator
427
407
  });
428
408
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
429
409
  return node;
430
410
  }
431
411
 
432
- function BlockStatement({
433
- parent,
434
- ...props
435
- }) {
436
- const node = (0, _detachedNode.detachedProps)(parent, {
412
+ function BlockStatement(props) {
413
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
437
414
  type: 'BlockStatement',
438
- ...props
415
+ body: props.body.map(n => (0, _detachedNode.asDetachedNode)(n))
439
416
  });
440
417
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
441
418
  return node;
442
419
  }
443
420
 
444
- function BooleanLiteralTypeAnnotation({
445
- parent,
446
- ...props
447
- }) {
448
- const node = (0, _detachedNode.detachedProps)(parent, {
421
+ function BooleanLiteralTypeAnnotation(props) {
422
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
449
423
  type: 'BooleanLiteralTypeAnnotation',
450
- ...props
424
+ value: props.value,
425
+ raw: props.raw
451
426
  });
452
427
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
453
428
  return node;
454
429
  }
455
430
 
456
- function BooleanTypeAnnotation({
457
- parent
458
- } = {}) {
459
- return (0, _detachedNode.detachedProps)(parent, {
431
+ function BooleanTypeAnnotation(props = { ...null
432
+ }) {
433
+ return (0, _detachedNode.detachedProps)(props.parent, {
460
434
  type: 'BooleanTypeAnnotation'
461
435
  });
462
436
  }
463
437
 
464
- function BreakStatement({
465
- parent,
466
- ...props
467
- }) {
468
- const node = (0, _detachedNode.detachedProps)(parent, {
438
+ function BreakStatement(props) {
439
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
469
440
  type: 'BreakStatement',
470
- ...props
441
+ label: (0, _detachedNode.asDetachedNode)(props.label)
471
442
  });
472
443
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
473
444
  return node;
474
445
  }
475
446
 
476
- function CallExpression({
477
- parent,
478
- ...props
479
- }) {
480
- const node = (0, _detachedNode.detachedProps)(parent, {
447
+ function CallExpression(props) {
448
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
481
449
  type: 'CallExpression',
482
- ...props
450
+ callee: (0, _detachedNode.asDetachedNode)(props.callee),
451
+ typeArguments: (0, _detachedNode.asDetachedNode)(props.typeArguments),
452
+ arguments: props.arguments.map(n => (0, _detachedNode.asDetachedNode)(n))
483
453
  });
484
454
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
485
455
  return node;
486
456
  }
487
457
 
488
- function CatchClause({
489
- parent,
490
- ...props
491
- }) {
492
- const node = (0, _detachedNode.detachedProps)(parent, {
458
+ function CatchClause(props) {
459
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
493
460
  type: 'CatchClause',
494
- ...props
461
+ param: (0, _detachedNode.asDetachedNode)(props.param),
462
+ body: (0, _detachedNode.asDetachedNode)(props.body)
495
463
  });
496
464
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
497
465
  return node;
498
466
  }
499
467
 
500
- function ChainExpression({
501
- parent,
502
- ...props
503
- }) {
504
- const node = (0, _detachedNode.detachedProps)(parent, {
468
+ function ChainExpression(props) {
469
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
505
470
  type: 'ChainExpression',
506
- ...props
471
+ expression: (0, _detachedNode.asDetachedNode)(props.expression)
507
472
  });
508
473
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
509
474
  return node;
510
475
  }
511
476
 
512
- function ClassBody({
513
- parent,
514
- ...props
515
- }) {
516
- const node = (0, _detachedNode.detachedProps)(parent, {
477
+ function ClassBody(props) {
478
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
517
479
  type: 'ClassBody',
518
- ...props
480
+ body: props.body.map(n => (0, _detachedNode.asDetachedNode)(n))
519
481
  });
520
482
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
521
483
  return node;
522
484
  }
523
485
 
524
- function ClassDeclaration({
525
- parent,
526
- ...props
527
- }) {
528
- const node = (0, _detachedNode.detachedProps)(parent, {
529
- type: 'ClassDeclaration',
530
- ...props
531
- });
532
- (0, _detachedNode.setParentPointersInDirectChildren)(node);
533
- return node;
534
- }
535
-
536
- function ClassExpression({
537
- parent,
538
- ...props
539
- }) {
540
- const node = (0, _detachedNode.detachedProps)(parent, {
486
+ function ClassExpression(props) {
487
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
541
488
  type: 'ClassExpression',
542
- ...props
489
+ id: (0, _detachedNode.asDetachedNode)(props.id),
490
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
491
+ superClass: (0, _detachedNode.asDetachedNode)(props.superClass),
492
+ superTypeParameters: (0, _detachedNode.asDetachedNode)(props.superTypeParameters),
493
+ implements: props.implements.map(n => (0, _detachedNode.asDetachedNode)(n)),
494
+ decorators: props.decorators.map(n => (0, _detachedNode.asDetachedNode)(n)),
495
+ body: (0, _detachedNode.asDetachedNode)(props.body)
543
496
  });
544
497
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
545
498
  return node;
546
499
  }
547
500
 
548
- function ClassImplements({
549
- parent,
550
- ...props
551
- }) {
552
- const node = (0, _detachedNode.detachedProps)(parent, {
501
+ function ClassImplements(props) {
502
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
553
503
  type: 'ClassImplements',
554
- ...props
504
+ id: (0, _detachedNode.asDetachedNode)(props.id),
505
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters)
555
506
  });
556
507
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
557
508
  return node;
558
509
  }
559
510
 
560
- function ConditionalExpression({
561
- parent,
562
- ...props
563
- }) {
564
- const node = (0, _detachedNode.detachedProps)(parent, {
511
+ function ConditionalExpression(props) {
512
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
565
513
  type: 'ConditionalExpression',
566
- ...props
514
+ test: (0, _detachedNode.asDetachedNode)(props.test),
515
+ alternate: (0, _detachedNode.asDetachedNode)(props.alternate),
516
+ consequent: (0, _detachedNode.asDetachedNode)(props.consequent)
567
517
  });
568
518
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
569
519
  return node;
570
520
  }
571
521
 
572
- function ContinueStatement({
573
- parent,
574
- ...props
575
- }) {
576
- const node = (0, _detachedNode.detachedProps)(parent, {
522
+ function ContinueStatement(props) {
523
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
577
524
  type: 'ContinueStatement',
578
- ...props
525
+ label: (0, _detachedNode.asDetachedNode)(props.label)
579
526
  });
580
527
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
581
528
  return node;
582
529
  }
583
530
 
584
- function DebuggerStatement({
585
- parent
586
- } = {}) {
587
- return (0, _detachedNode.detachedProps)(parent, {
531
+ function DebuggerStatement(props = { ...null
532
+ }) {
533
+ return (0, _detachedNode.detachedProps)(props.parent, {
588
534
  type: 'DebuggerStatement'
589
535
  });
590
536
  }
591
537
 
592
- function DeclareClass({
593
- parent,
594
- ...props
595
- }) {
596
- const node = (0, _detachedNode.detachedProps)(parent, {
538
+ function DeclareClass(props) {
539
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
597
540
  type: 'DeclareClass',
598
- ...props
541
+ id: (0, _detachedNode.asDetachedNode)(props.id),
542
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
543
+ extends: props.extends.map(n => (0, _detachedNode.asDetachedNode)(n)),
544
+ implements: props.implements.map(n => (0, _detachedNode.asDetachedNode)(n)),
545
+ mixins: props.mixins.map(n => (0, _detachedNode.asDetachedNode)(n)),
546
+ body: (0, _detachedNode.asDetachedNode)(props.body)
599
547
  });
600
548
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
601
549
  return node;
602
550
  }
603
551
 
604
- function DeclaredPredicate({
605
- parent,
606
- ...props
607
- }) {
608
- const node = (0, _detachedNode.detachedProps)(parent, {
552
+ function DeclaredPredicate(props) {
553
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
609
554
  type: 'DeclaredPredicate',
610
- ...props
555
+ value: (0, _detachedNode.asDetachedNode)(props.value)
611
556
  });
612
557
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
613
558
  return node;
614
559
  }
615
560
 
616
- function DeclareExportAllDeclaration({
617
- parent,
618
- ...props
619
- }) {
620
- const node = (0, _detachedNode.detachedProps)(parent, {
561
+ function DeclareExportAllDeclaration(props) {
562
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
621
563
  type: 'DeclareExportAllDeclaration',
622
- ...props
564
+ source: (0, _detachedNode.asDetachedNode)(props.source)
623
565
  });
624
566
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
625
567
  return node;
626
568
  }
627
569
 
628
- function DeclareExportDeclaration({
629
- parent,
630
- ...props
631
- }) {
632
- const node = (0, _detachedNode.detachedProps)(parent, {
570
+ function DeclareExportDeclaration(props) {
571
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
633
572
  type: 'DeclareExportDeclaration',
634
- ...props
573
+ declaration: (0, _detachedNode.asDetachedNode)(props.declaration),
574
+ specifiers: props.specifiers.map(n => (0, _detachedNode.asDetachedNode)(n)),
575
+ source: (0, _detachedNode.asDetachedNode)(props.source),
576
+ default: props.default
635
577
  });
636
578
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
637
579
  return node;
638
580
  }
639
581
 
640
- function DeclareFunction({
641
- parent,
642
- ...props
643
- }) {
644
- const node = (0, _detachedNode.detachedProps)(parent, {
582
+ function DeclareFunction(props) {
583
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
645
584
  type: 'DeclareFunction',
646
- ...props
585
+ id: (0, _detachedNode.asDetachedNode)(props.id),
586
+ predicate: (0, _detachedNode.asDetachedNode)(props.predicate)
647
587
  });
648
588
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
649
589
  return node;
650
590
  }
651
591
 
652
- function DeclareInterface({
653
- parent,
654
- ...props
655
- }) {
656
- const node = (0, _detachedNode.detachedProps)(parent, {
592
+ function DeclareInterface(props) {
593
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
657
594
  type: 'DeclareInterface',
658
- ...props
595
+ id: (0, _detachedNode.asDetachedNode)(props.id),
596
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
597
+ extends: props.extends.map(n => (0, _detachedNode.asDetachedNode)(n)),
598
+ body: (0, _detachedNode.asDetachedNode)(props.body)
659
599
  });
660
600
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
661
601
  return node;
662
602
  }
663
603
 
664
- function DeclareModule({
665
- parent,
666
- ...props
667
- }) {
668
- const node = (0, _detachedNode.detachedProps)(parent, {
604
+ function DeclareModule(props) {
605
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
669
606
  type: 'DeclareModule',
670
- ...props
607
+ id: (0, _detachedNode.asDetachedNode)(props.id),
608
+ body: (0, _detachedNode.asDetachedNode)(props.body),
609
+ kind: props.kind
671
610
  });
672
611
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
673
612
  return node;
674
613
  }
675
614
 
676
- function DeclareModuleExports({
677
- parent,
678
- ...props
679
- }) {
680
- const node = (0, _detachedNode.detachedProps)(parent, {
615
+ function DeclareModuleExports(props) {
616
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
681
617
  type: 'DeclareModuleExports',
682
- ...props
618
+ typeAnnotation: (0, _detachedNode.asDetachedNode)(props.typeAnnotation)
683
619
  });
684
620
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
685
621
  return node;
686
622
  }
687
623
 
688
- function DeclareOpaqueType({
689
- parent,
690
- ...props
691
- }) {
692
- const node = (0, _detachedNode.detachedProps)(parent, {
624
+ function DeclareOpaqueType(props) {
625
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
693
626
  type: 'DeclareOpaqueType',
694
- ...props
627
+ id: (0, _detachedNode.asDetachedNode)(props.id),
628
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
629
+ impltype: (0, _detachedNode.asDetachedNode)(props.impltype),
630
+ supertype: (0, _detachedNode.asDetachedNode)(props.supertype)
695
631
  });
696
632
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
697
633
  return node;
698
634
  }
699
635
 
700
- function DeclareTypeAlias({
701
- parent,
702
- ...props
703
- }) {
704
- const node = (0, _detachedNode.detachedProps)(parent, {
636
+ function DeclareTypeAlias(props) {
637
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
705
638
  type: 'DeclareTypeAlias',
706
- ...props
639
+ id: (0, _detachedNode.asDetachedNode)(props.id),
640
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
641
+ right: (0, _detachedNode.asDetachedNode)(props.right)
707
642
  });
708
643
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
709
644
  return node;
710
645
  }
711
646
 
712
- function DeclareVariable({
713
- parent,
714
- ...props
715
- }) {
716
- const node = (0, _detachedNode.detachedProps)(parent, {
647
+ function DeclareVariable(props) {
648
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
717
649
  type: 'DeclareVariable',
718
- ...props
650
+ id: (0, _detachedNode.asDetachedNode)(props.id)
719
651
  });
720
652
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
721
653
  return node;
722
654
  }
723
655
 
724
- function DoWhileStatement({
725
- parent,
726
- ...props
727
- }) {
728
- const node = (0, _detachedNode.detachedProps)(parent, {
656
+ function DoWhileStatement(props) {
657
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
729
658
  type: 'DoWhileStatement',
730
- ...props
659
+ body: (0, _detachedNode.asDetachedNode)(props.body),
660
+ test: (0, _detachedNode.asDetachedNode)(props.test)
731
661
  });
732
662
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
733
663
  return node;
734
664
  }
735
665
 
736
- function EmptyStatement({
737
- parent
738
- } = {}) {
739
- return (0, _detachedNode.detachedProps)(parent, {
666
+ function EmptyStatement(props = { ...null
667
+ }) {
668
+ return (0, _detachedNode.detachedProps)(props.parent, {
740
669
  type: 'EmptyStatement'
741
670
  });
742
671
  }
743
672
 
744
- function EmptyTypeAnnotation({
745
- parent
746
- } = {}) {
747
- return (0, _detachedNode.detachedProps)(parent, {
673
+ function EmptyTypeAnnotation(props = { ...null
674
+ }) {
675
+ return (0, _detachedNode.detachedProps)(props.parent, {
748
676
  type: 'EmptyTypeAnnotation'
749
677
  });
750
678
  }
751
679
 
752
- function EnumBooleanBody({
753
- parent,
754
- ...props
755
- }) {
756
- const node = (0, _detachedNode.detachedProps)(parent, {
680
+ function EnumBooleanBody(props) {
681
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
757
682
  type: 'EnumBooleanBody',
758
- ...props
683
+ members: props.members.map(n => (0, _detachedNode.asDetachedNode)(n)),
684
+ explicitType: props.explicitType,
685
+ hasUnknownMembers: props.hasUnknownMembers
759
686
  });
760
687
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
761
688
  return node;
762
689
  }
763
690
 
764
- function EnumBooleanMember({
765
- parent,
766
- ...props
767
- }) {
768
- const node = (0, _detachedNode.detachedProps)(parent, {
691
+ function EnumBooleanMember(props) {
692
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
769
693
  type: 'EnumBooleanMember',
770
- ...props
694
+ id: (0, _detachedNode.asDetachedNode)(props.id),
695
+ init: (0, _detachedNode.asDetachedNode)(props.init)
771
696
  });
772
697
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
773
698
  return node;
774
699
  }
775
700
 
776
- function EnumDeclaration({
777
- parent,
778
- ...props
779
- }) {
780
- const node = (0, _detachedNode.detachedProps)(parent, {
701
+ function EnumDeclaration(props) {
702
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
781
703
  type: 'EnumDeclaration',
782
- ...props
704
+ id: (0, _detachedNode.asDetachedNode)(props.id),
705
+ body: (0, _detachedNode.asDetachedNode)(props.body)
783
706
  });
784
707
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
785
708
  return node;
786
709
  }
787
710
 
788
- function EnumDefaultedMember({
789
- parent,
790
- ...props
791
- }) {
792
- const node = (0, _detachedNode.detachedProps)(parent, {
711
+ function EnumDefaultedMember(props) {
712
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
793
713
  type: 'EnumDefaultedMember',
794
- ...props
714
+ id: (0, _detachedNode.asDetachedNode)(props.id)
795
715
  });
796
716
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
797
717
  return node;
798
718
  }
799
719
 
800
- function EnumNumberBody({
801
- parent,
802
- ...props
803
- }) {
804
- const node = (0, _detachedNode.detachedProps)(parent, {
720
+ function EnumNumberBody(props) {
721
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
805
722
  type: 'EnumNumberBody',
806
- ...props
723
+ members: props.members.map(n => (0, _detachedNode.asDetachedNode)(n)),
724
+ explicitType: props.explicitType,
725
+ hasUnknownMembers: props.hasUnknownMembers
807
726
  });
808
727
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
809
728
  return node;
810
729
  }
811
730
 
812
- function EnumNumberMember({
813
- parent,
814
- ...props
815
- }) {
816
- const node = (0, _detachedNode.detachedProps)(parent, {
731
+ function EnumNumberMember(props) {
732
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
817
733
  type: 'EnumNumberMember',
818
- ...props
734
+ id: (0, _detachedNode.asDetachedNode)(props.id),
735
+ init: (0, _detachedNode.asDetachedNode)(props.init)
819
736
  });
820
737
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
821
738
  return node;
822
739
  }
823
740
 
824
- function EnumStringBody({
825
- parent,
826
- ...props
827
- }) {
828
- const node = (0, _detachedNode.detachedProps)(parent, {
741
+ function EnumStringBody(props) {
742
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
829
743
  type: 'EnumStringBody',
830
- ...props
744
+ members: props.members.map(n => (0, _detachedNode.asDetachedNode)(n)),
745
+ explicitType: props.explicitType,
746
+ hasUnknownMembers: props.hasUnknownMembers
831
747
  });
832
748
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
833
749
  return node;
834
750
  }
835
751
 
836
- function EnumStringMember({
837
- parent,
838
- ...props
839
- }) {
840
- const node = (0, _detachedNode.detachedProps)(parent, {
752
+ function EnumStringMember(props) {
753
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
841
754
  type: 'EnumStringMember',
842
- ...props
755
+ id: (0, _detachedNode.asDetachedNode)(props.id),
756
+ init: (0, _detachedNode.asDetachedNode)(props.init)
843
757
  });
844
758
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
845
759
  return node;
846
760
  }
847
761
 
848
- function EnumSymbolBody({
849
- parent,
850
- ...props
851
- }) {
852
- const node = (0, _detachedNode.detachedProps)(parent, {
762
+ function EnumSymbolBody(props) {
763
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
853
764
  type: 'EnumSymbolBody',
854
- ...props
765
+ members: props.members.map(n => (0, _detachedNode.asDetachedNode)(n)),
766
+ hasUnknownMembers: props.hasUnknownMembers
855
767
  });
856
768
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
857
769
  return node;
858
770
  }
859
771
 
860
- function ExistsTypeAnnotation({
861
- parent
862
- } = {}) {
863
- return (0, _detachedNode.detachedProps)(parent, {
772
+ function ExistsTypeAnnotation(props = { ...null
773
+ }) {
774
+ return (0, _detachedNode.detachedProps)(props.parent, {
864
775
  type: 'ExistsTypeAnnotation'
865
776
  });
866
777
  }
867
778
 
868
- function ExportAllDeclaration({
869
- parent,
870
- ...props
871
- }) {
872
- const node = (0, _detachedNode.detachedProps)(parent, {
779
+ function ExportAllDeclaration(props) {
780
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
873
781
  type: 'ExportAllDeclaration',
874
- ...props
782
+ exported: (0, _detachedNode.asDetachedNode)(props.exported),
783
+ source: (0, _detachedNode.asDetachedNode)(props.source),
784
+ exportKind: props.exportKind
875
785
  });
876
786
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
877
787
  return node;
878
788
  }
879
789
 
880
- function ExportDefaultDeclaration({
881
- parent,
882
- ...props
883
- }) {
884
- const node = (0, _detachedNode.detachedProps)(parent, {
790
+ function ExportDefaultDeclaration(props) {
791
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
885
792
  type: 'ExportDefaultDeclaration',
886
- ...props
793
+ declaration: (0, _detachedNode.asDetachedNode)(props.declaration)
887
794
  });
888
795
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
889
796
  return node;
890
797
  }
891
798
 
892
- function ExportNamedDeclaration({
893
- parent,
894
- ...props
895
- }) {
896
- const node = (0, _detachedNode.detachedProps)(parent, {
799
+ function ExportNamedDeclaration(props) {
800
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
897
801
  type: 'ExportNamedDeclaration',
898
- ...props
802
+ declaration: (0, _detachedNode.asDetachedNode)(props.declaration),
803
+ specifiers: props.specifiers.map(n => (0, _detachedNode.asDetachedNode)(n)),
804
+ source: (0, _detachedNode.asDetachedNode)(props.source),
805
+ exportKind: props.exportKind
899
806
  });
900
807
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
901
808
  return node;
902
809
  }
903
810
 
904
- function ExportSpecifier({
905
- parent,
906
- ...props
907
- }) {
908
- const node = (0, _detachedNode.detachedProps)(parent, {
811
+ function ExportSpecifier(props) {
812
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
909
813
  type: 'ExportSpecifier',
910
- ...props
814
+ exported: (0, _detachedNode.asDetachedNode)(props.exported),
815
+ local: (0, _detachedNode.asDetachedNode)(props.local)
911
816
  });
912
817
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
913
818
  return node;
914
819
  }
915
820
 
916
- function ExpressionStatement({
917
- parent,
918
- ...props
919
- }) {
920
- const node = (0, _detachedNode.detachedProps)(parent, {
821
+ function ExpressionStatement(props) {
822
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
921
823
  type: 'ExpressionStatement',
922
- ...props
824
+ expression: (0, _detachedNode.asDetachedNode)(props.expression),
825
+ directive: props.directive
923
826
  });
924
827
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
925
828
  return node;
926
829
  }
927
830
 
928
- function ForInStatement({
929
- parent,
930
- ...props
931
- }) {
932
- const node = (0, _detachedNode.detachedProps)(parent, {
831
+ function ForInStatement(props) {
832
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
933
833
  type: 'ForInStatement',
934
- ...props
834
+ left: (0, _detachedNode.asDetachedNode)(props.left),
835
+ right: (0, _detachedNode.asDetachedNode)(props.right),
836
+ body: (0, _detachedNode.asDetachedNode)(props.body)
935
837
  });
936
838
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
937
839
  return node;
938
840
  }
939
841
 
940
- function ForOfStatement({
941
- parent,
942
- ...props
943
- }) {
944
- const node = (0, _detachedNode.detachedProps)(parent, {
842
+ function ForOfStatement(props) {
843
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
945
844
  type: 'ForOfStatement',
946
- ...props
845
+ left: (0, _detachedNode.asDetachedNode)(props.left),
846
+ right: (0, _detachedNode.asDetachedNode)(props.right),
847
+ body: (0, _detachedNode.asDetachedNode)(props.body),
848
+ await: props.await
947
849
  });
948
850
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
949
851
  return node;
950
852
  }
951
853
 
952
- function ForStatement({
953
- parent,
954
- ...props
955
- }) {
956
- const node = (0, _detachedNode.detachedProps)(parent, {
854
+ function ForStatement(props) {
855
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
957
856
  type: 'ForStatement',
958
- ...props
857
+ init: (0, _detachedNode.asDetachedNode)(props.init),
858
+ test: (0, _detachedNode.asDetachedNode)(props.test),
859
+ update: (0, _detachedNode.asDetachedNode)(props.update),
860
+ body: (0, _detachedNode.asDetachedNode)(props.body)
959
861
  });
960
862
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
961
863
  return node;
962
864
  }
963
865
 
964
- function FunctionDeclaration({
965
- parent,
966
- ...props
967
- }) {
968
- const node = (0, _detachedNode.detachedProps)(parent, {
866
+ function FunctionDeclaration(props) {
867
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
969
868
  type: 'FunctionDeclaration',
970
- ...props
869
+ id: (0, _detachedNode.asDetachedNode)(props.id),
870
+ params: props.params.map(n => (0, _detachedNode.asDetachedNode)(n)),
871
+ body: (0, _detachedNode.asDetachedNode)(props.body),
872
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
873
+ returnType: (0, _detachedNode.asDetachedNode)(props.returnType),
874
+ predicate: (0, _detachedNode.asDetachedNode)(props.predicate),
875
+ generator: props.generator,
876
+ async: props.async
971
877
  });
972
878
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
973
879
  return node;
974
880
  }
975
881
 
976
- function FunctionExpression({
977
- parent,
978
- ...props
979
- }) {
980
- const node = (0, _detachedNode.detachedProps)(parent, {
882
+ function FunctionExpression(props) {
883
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
981
884
  type: 'FunctionExpression',
982
- ...props
885
+ id: (0, _detachedNode.asDetachedNode)(props.id),
886
+ params: props.params.map(n => (0, _detachedNode.asDetachedNode)(n)),
887
+ body: (0, _detachedNode.asDetachedNode)(props.body),
888
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
889
+ returnType: (0, _detachedNode.asDetachedNode)(props.returnType),
890
+ predicate: (0, _detachedNode.asDetachedNode)(props.predicate),
891
+ generator: props.generator,
892
+ async: props.async
983
893
  });
984
894
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
985
895
  return node;
986
896
  }
987
897
 
988
- function FunctionTypeAnnotation({
989
- parent,
990
- ...props
991
- }) {
992
- const node = (0, _detachedNode.detachedProps)(parent, {
898
+ function FunctionTypeAnnotation(props) {
899
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
993
900
  type: 'FunctionTypeAnnotation',
994
- ...props
901
+ params: props.params.map(n => (0, _detachedNode.asDetachedNode)(n)),
902
+ this: (0, _detachedNode.asDetachedNode)(props.this),
903
+ returnType: (0, _detachedNode.asDetachedNode)(props.returnType),
904
+ rest: (0, _detachedNode.asDetachedNode)(props.rest),
905
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters)
995
906
  });
996
907
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
997
908
  return node;
998
909
  }
999
910
 
1000
- function FunctionTypeParam({
1001
- parent,
1002
- ...props
1003
- }) {
1004
- const node = (0, _detachedNode.detachedProps)(parent, {
911
+ function FunctionTypeParam(props) {
912
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1005
913
  type: 'FunctionTypeParam',
1006
- ...props
914
+ name: (0, _detachedNode.asDetachedNode)(props.name),
915
+ typeAnnotation: (0, _detachedNode.asDetachedNode)(props.typeAnnotation),
916
+ optional: props.optional
1007
917
  });
1008
918
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1009
919
  return node;
1010
920
  }
1011
921
 
1012
- function GenericTypeAnnotation({
1013
- parent,
1014
- ...props
1015
- }) {
1016
- const node = (0, _detachedNode.detachedProps)(parent, {
922
+ function GenericTypeAnnotation(props) {
923
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1017
924
  type: 'GenericTypeAnnotation',
1018
- ...props
925
+ id: (0, _detachedNode.asDetachedNode)(props.id),
926
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters)
1019
927
  });
1020
928
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1021
929
  return node;
1022
930
  }
1023
931
 
1024
- function IfStatement({
1025
- parent,
1026
- ...props
1027
- }) {
1028
- const node = (0, _detachedNode.detachedProps)(parent, {
932
+ function IfStatement(props) {
933
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1029
934
  type: 'IfStatement',
1030
- ...props
935
+ test: (0, _detachedNode.asDetachedNode)(props.test),
936
+ consequent: (0, _detachedNode.asDetachedNode)(props.consequent),
937
+ alternate: (0, _detachedNode.asDetachedNode)(props.alternate)
1031
938
  });
1032
939
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1033
940
  return node;
1034
941
  }
1035
942
 
1036
- function ImportAttribute({
1037
- parent,
1038
- ...props
1039
- }) {
1040
- const node = (0, _detachedNode.detachedProps)(parent, {
943
+ function ImportAttribute(props) {
944
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1041
945
  type: 'ImportAttribute',
1042
- ...props
946
+ key: (0, _detachedNode.asDetachedNode)(props.key),
947
+ value: (0, _detachedNode.asDetachedNode)(props.value)
1043
948
  });
1044
949
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1045
950
  return node;
1046
951
  }
1047
952
 
1048
- function ImportDeclaration({
1049
- parent,
1050
- ...props
1051
- }) {
1052
- const node = (0, _detachedNode.detachedProps)(parent, {
953
+ function ImportDeclaration(props) {
954
+ var _props$assertions;
955
+
956
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1053
957
  type: 'ImportDeclaration',
1054
- ...props
958
+ specifiers: props.specifiers.map(n => (0, _detachedNode.asDetachedNode)(n)),
959
+ source: (0, _detachedNode.asDetachedNode)(props.source),
960
+ assertions: (_props$assertions = props.assertions) == null ? void 0 : _props$assertions.map(n => (0, _detachedNode.asDetachedNode)(n)),
961
+ importKind: props.importKind
1055
962
  });
1056
963
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1057
964
  return node;
1058
965
  }
1059
966
 
1060
- function ImportDefaultSpecifier({
1061
- parent,
1062
- ...props
1063
- }) {
1064
- const node = (0, _detachedNode.detachedProps)(parent, {
967
+ function ImportDefaultSpecifier(props) {
968
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1065
969
  type: 'ImportDefaultSpecifier',
1066
- ...props
970
+ local: (0, _detachedNode.asDetachedNode)(props.local)
1067
971
  });
1068
972
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1069
973
  return node;
1070
974
  }
1071
975
 
1072
- function ImportExpression({
1073
- parent,
1074
- ...props
1075
- }) {
1076
- const node = (0, _detachedNode.detachedProps)(parent, {
976
+ function ImportExpression(props) {
977
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1077
978
  type: 'ImportExpression',
1078
- ...props
979
+ source: (0, _detachedNode.asDetachedNode)(props.source),
980
+ attributes: (0, _detachedNode.asDetachedNode)(props.attributes)
1079
981
  });
1080
982
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1081
983
  return node;
1082
984
  }
1083
985
 
1084
- function ImportNamespaceSpecifier({
1085
- parent,
1086
- ...props
1087
- }) {
1088
- const node = (0, _detachedNode.detachedProps)(parent, {
986
+ function ImportNamespaceSpecifier(props) {
987
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1089
988
  type: 'ImportNamespaceSpecifier',
1090
- ...props
989
+ local: (0, _detachedNode.asDetachedNode)(props.local)
1091
990
  });
1092
991
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1093
992
  return node;
1094
993
  }
1095
994
 
1096
- function ImportSpecifier({
1097
- parent,
1098
- ...props
1099
- }) {
1100
- const node = (0, _detachedNode.detachedProps)(parent, {
995
+ function ImportSpecifier(props) {
996
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1101
997
  type: 'ImportSpecifier',
1102
- ...props
998
+ imported: (0, _detachedNode.asDetachedNode)(props.imported),
999
+ local: (0, _detachedNode.asDetachedNode)(props.local),
1000
+ importKind: props.importKind
1103
1001
  });
1104
1002
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1105
1003
  return node;
1106
1004
  }
1107
1005
 
1108
- function IndexedAccessType({
1109
- parent,
1110
- ...props
1111
- }) {
1112
- const node = (0, _detachedNode.detachedProps)(parent, {
1006
+ function IndexedAccessType(props) {
1007
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1113
1008
  type: 'IndexedAccessType',
1114
- ...props
1009
+ objectType: (0, _detachedNode.asDetachedNode)(props.objectType),
1010
+ indexType: (0, _detachedNode.asDetachedNode)(props.indexType)
1115
1011
  });
1116
1012
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1117
1013
  return node;
1118
1014
  }
1119
1015
 
1120
- function InferredPredicate({
1121
- parent
1122
- } = {}) {
1123
- return (0, _detachedNode.detachedProps)(parent, {
1016
+ function InferredPredicate(props = { ...null
1017
+ }) {
1018
+ return (0, _detachedNode.detachedProps)(props.parent, {
1124
1019
  type: 'InferredPredicate'
1125
1020
  });
1126
1021
  }
1127
1022
 
1128
- function InterfaceDeclaration({
1129
- parent,
1130
- ...props
1131
- }) {
1132
- const node = (0, _detachedNode.detachedProps)(parent, {
1023
+ function InterfaceDeclaration(props) {
1024
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1133
1025
  type: 'InterfaceDeclaration',
1134
- ...props
1026
+ id: (0, _detachedNode.asDetachedNode)(props.id),
1027
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
1028
+ extends: props.extends.map(n => (0, _detachedNode.asDetachedNode)(n)),
1029
+ body: (0, _detachedNode.asDetachedNode)(props.body)
1135
1030
  });
1136
1031
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1137
1032
  return node;
1138
1033
  }
1139
1034
 
1140
- function InterfaceExtends({
1141
- parent,
1142
- ...props
1143
- }) {
1144
- const node = (0, _detachedNode.detachedProps)(parent, {
1035
+ function InterfaceExtends(props) {
1036
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1145
1037
  type: 'InterfaceExtends',
1146
- ...props
1038
+ id: (0, _detachedNode.asDetachedNode)(props.id),
1039
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters)
1147
1040
  });
1148
1041
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1149
1042
  return node;
1150
1043
  }
1151
1044
 
1152
- function InterfaceTypeAnnotation({
1153
- parent,
1154
- ...props
1155
- }) {
1156
- const node = (0, _detachedNode.detachedProps)(parent, {
1045
+ function InterfaceTypeAnnotation(props) {
1046
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1157
1047
  type: 'InterfaceTypeAnnotation',
1158
- ...props
1048
+ extends: props.extends.map(n => (0, _detachedNode.asDetachedNode)(n)),
1049
+ body: (0, _detachedNode.asDetachedNode)(props.body)
1159
1050
  });
1160
1051
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1161
1052
  return node;
1162
1053
  }
1163
1054
 
1164
- function IntersectionTypeAnnotation({
1165
- parent,
1166
- ...props
1167
- }) {
1168
- const node = (0, _detachedNode.detachedProps)(parent, {
1055
+ function IntersectionTypeAnnotation(props) {
1056
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1169
1057
  type: 'IntersectionTypeAnnotation',
1170
- ...props
1058
+ types: props.types.map(n => (0, _detachedNode.asDetachedNode)(n))
1171
1059
  });
1172
1060
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1173
1061
  return node;
1174
1062
  }
1175
1063
 
1176
- function JSXAttribute({
1177
- parent,
1178
- ...props
1179
- }) {
1180
- const node = (0, _detachedNode.detachedProps)(parent, {
1064
+ function JSXAttribute(props) {
1065
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1181
1066
  type: 'JSXAttribute',
1182
- ...props
1067
+ name: (0, _detachedNode.asDetachedNode)(props.name),
1068
+ value: (0, _detachedNode.asDetachedNode)(props.value)
1183
1069
  });
1184
1070
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1185
1071
  return node;
1186
1072
  }
1187
1073
 
1188
- function JSXClosingElement({
1189
- parent,
1190
- ...props
1191
- }) {
1192
- const node = (0, _detachedNode.detachedProps)(parent, {
1074
+ function JSXClosingElement(props) {
1075
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1193
1076
  type: 'JSXClosingElement',
1194
- ...props
1077
+ name: (0, _detachedNode.asDetachedNode)(props.name)
1195
1078
  });
1196
1079
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1197
1080
  return node;
1198
1081
  }
1199
1082
 
1200
- function JSXClosingFragment({
1201
- parent
1202
- } = {}) {
1203
- return (0, _detachedNode.detachedProps)(parent, {
1083
+ function JSXClosingFragment(props = { ...null
1084
+ }) {
1085
+ return (0, _detachedNode.detachedProps)(props.parent, {
1204
1086
  type: 'JSXClosingFragment'
1205
1087
  });
1206
1088
  }
1207
1089
 
1208
- function JSXElement({
1209
- parent,
1210
- ...props
1211
- }) {
1212
- const node = (0, _detachedNode.detachedProps)(parent, {
1090
+ function JSXElement(props) {
1091
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1213
1092
  type: 'JSXElement',
1214
- ...props
1093
+ openingElement: (0, _detachedNode.asDetachedNode)(props.openingElement),
1094
+ children: props.children.map(n => (0, _detachedNode.asDetachedNode)(n)),
1095
+ closingElement: (0, _detachedNode.asDetachedNode)(props.closingElement)
1215
1096
  });
1216
1097
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1217
1098
  return node;
1218
1099
  }
1219
1100
 
1220
- function JSXEmptyExpression({
1221
- parent
1222
- } = {}) {
1223
- return (0, _detachedNode.detachedProps)(parent, {
1101
+ function JSXEmptyExpression(props = { ...null
1102
+ }) {
1103
+ return (0, _detachedNode.detachedProps)(props.parent, {
1224
1104
  type: 'JSXEmptyExpression'
1225
1105
  });
1226
1106
  }
1227
1107
 
1228
- function JSXExpressionContainer({
1229
- parent,
1230
- ...props
1231
- }) {
1232
- const node = (0, _detachedNode.detachedProps)(parent, {
1108
+ function JSXExpressionContainer(props) {
1109
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1233
1110
  type: 'JSXExpressionContainer',
1234
- ...props
1111
+ expression: (0, _detachedNode.asDetachedNode)(props.expression)
1235
1112
  });
1236
1113
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1237
1114
  return node;
1238
1115
  }
1239
1116
 
1240
- function JSXFragment({
1241
- parent,
1242
- ...props
1243
- }) {
1244
- const node = (0, _detachedNode.detachedProps)(parent, {
1117
+ function JSXFragment(props) {
1118
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1245
1119
  type: 'JSXFragment',
1246
- ...props
1120
+ openingFragment: (0, _detachedNode.asDetachedNode)(props.openingFragment),
1121
+ children: props.children.map(n => (0, _detachedNode.asDetachedNode)(n)),
1122
+ closingFragment: (0, _detachedNode.asDetachedNode)(props.closingFragment)
1247
1123
  });
1248
1124
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1249
1125
  return node;
1250
1126
  }
1251
1127
 
1252
- function JSXIdentifier({
1253
- parent,
1254
- ...props
1255
- }) {
1256
- const node = (0, _detachedNode.detachedProps)(parent, {
1128
+ function JSXIdentifier(props) {
1129
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1257
1130
  type: 'JSXIdentifier',
1258
- ...props
1131
+ name: props.name
1259
1132
  });
1260
1133
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1261
1134
  return node;
1262
1135
  }
1263
1136
 
1264
- function JSXMemberExpression({
1265
- parent,
1266
- ...props
1267
- }) {
1268
- const node = (0, _detachedNode.detachedProps)(parent, {
1137
+ function JSXMemberExpression(props) {
1138
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1269
1139
  type: 'JSXMemberExpression',
1270
- ...props
1140
+ object: (0, _detachedNode.asDetachedNode)(props.object),
1141
+ property: (0, _detachedNode.asDetachedNode)(props.property)
1271
1142
  });
1272
1143
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1273
1144
  return node;
1274
1145
  }
1275
1146
 
1276
- function JSXNamespacedName({
1277
- parent,
1278
- ...props
1279
- }) {
1280
- const node = (0, _detachedNode.detachedProps)(parent, {
1147
+ function JSXNamespacedName(props) {
1148
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1281
1149
  type: 'JSXNamespacedName',
1282
- ...props
1150
+ namespace: (0, _detachedNode.asDetachedNode)(props.namespace),
1151
+ name: (0, _detachedNode.asDetachedNode)(props.name)
1283
1152
  });
1284
1153
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1285
1154
  return node;
1286
1155
  }
1287
1156
 
1288
- function JSXOpeningElement({
1289
- parent,
1290
- ...props
1291
- }) {
1292
- const node = (0, _detachedNode.detachedProps)(parent, {
1157
+ function JSXOpeningElement(props) {
1158
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1293
1159
  type: 'JSXOpeningElement',
1294
- ...props
1160
+ name: (0, _detachedNode.asDetachedNode)(props.name),
1161
+ attributes: props.attributes.map(n => (0, _detachedNode.asDetachedNode)(n)),
1162
+ selfClosing: props.selfClosing
1295
1163
  });
1296
1164
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1297
1165
  return node;
1298
1166
  }
1299
1167
 
1300
- function JSXOpeningFragment({
1301
- parent
1302
- } = {}) {
1303
- return (0, _detachedNode.detachedProps)(parent, {
1168
+ function JSXOpeningFragment(props = { ...null
1169
+ }) {
1170
+ return (0, _detachedNode.detachedProps)(props.parent, {
1304
1171
  type: 'JSXOpeningFragment'
1305
1172
  });
1306
1173
  }
1307
1174
 
1308
- function JSXSpreadAttribute({
1309
- parent,
1310
- ...props
1311
- }) {
1312
- const node = (0, _detachedNode.detachedProps)(parent, {
1175
+ function JSXSpreadAttribute(props) {
1176
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1313
1177
  type: 'JSXSpreadAttribute',
1314
- ...props
1178
+ argument: (0, _detachedNode.asDetachedNode)(props.argument)
1315
1179
  });
1316
1180
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1317
1181
  return node;
1318
1182
  }
1319
1183
 
1320
- function JSXSpreadChild({
1321
- parent,
1322
- ...props
1323
- }) {
1324
- const node = (0, _detachedNode.detachedProps)(parent, {
1184
+ function JSXSpreadChild(props) {
1185
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1325
1186
  type: 'JSXSpreadChild',
1326
- ...props
1187
+ expression: (0, _detachedNode.asDetachedNode)(props.expression)
1327
1188
  });
1328
1189
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1329
1190
  return node;
1330
1191
  }
1331
1192
 
1332
- function JSXText({
1333
- parent,
1334
- ...props
1335
- }) {
1336
- const node = (0, _detachedNode.detachedProps)(parent, {
1193
+ function JSXText(props) {
1194
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1337
1195
  type: 'JSXText',
1338
- ...props
1196
+ value: props.value,
1197
+ raw: props.raw
1339
1198
  });
1340
1199
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1341
1200
  return node;
1342
1201
  }
1343
1202
 
1344
- function LabeledStatement({
1345
- parent,
1346
- ...props
1347
- }) {
1348
- const node = (0, _detachedNode.detachedProps)(parent, {
1203
+ function LabeledStatement(props) {
1204
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1349
1205
  type: 'LabeledStatement',
1350
- ...props
1206
+ label: (0, _detachedNode.asDetachedNode)(props.label),
1207
+ body: (0, _detachedNode.asDetachedNode)(props.body)
1351
1208
  });
1352
1209
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1353
1210
  return node;
1354
1211
  }
1355
1212
 
1356
- function LogicalExpression({
1357
- parent,
1358
- ...props
1359
- }) {
1360
- const node = (0, _detachedNode.detachedProps)(parent, {
1213
+ function LogicalExpression(props) {
1214
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1361
1215
  type: 'LogicalExpression',
1362
- ...props
1216
+ left: (0, _detachedNode.asDetachedNode)(props.left),
1217
+ right: (0, _detachedNode.asDetachedNode)(props.right),
1218
+ operator: props.operator
1363
1219
  });
1364
1220
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1365
1221
  return node;
1366
1222
  }
1367
1223
 
1368
- function MemberExpression({
1369
- parent,
1370
- ...props
1371
- }) {
1372
- const node = (0, _detachedNode.detachedProps)(parent, {
1224
+ function MemberExpression(props) {
1225
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1373
1226
  type: 'MemberExpression',
1374
- ...props
1227
+ object: (0, _detachedNode.asDetachedNode)(props.object),
1228
+ property: (0, _detachedNode.asDetachedNode)(props.property),
1229
+ computed: props.computed
1375
1230
  });
1376
1231
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1377
1232
  return node;
1378
1233
  }
1379
1234
 
1380
- function MetaProperty({
1381
- parent,
1382
- ...props
1383
- }) {
1384
- const node = (0, _detachedNode.detachedProps)(parent, {
1235
+ function MetaProperty(props) {
1236
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1385
1237
  type: 'MetaProperty',
1386
- ...props
1238
+ meta: (0, _detachedNode.asDetachedNode)(props.meta),
1239
+ property: (0, _detachedNode.asDetachedNode)(props.property)
1387
1240
  });
1388
1241
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1389
1242
  return node;
1390
1243
  }
1391
1244
 
1392
- function MethodDefinition({
1393
- parent,
1394
- ...props
1395
- }) {
1396
- const node = (0, _detachedNode.detachedProps)(parent, {
1245
+ function MethodDefinition(props) {
1246
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1397
1247
  type: 'MethodDefinition',
1398
- ...props
1248
+ key: (0, _detachedNode.asDetachedNode)(props.key),
1249
+ value: (0, _detachedNode.asDetachedNode)(props.value),
1250
+ kind: props.kind,
1251
+ computed: props.computed,
1252
+ static: props.static
1399
1253
  });
1400
1254
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1401
1255
  return node;
1402
1256
  }
1403
1257
 
1404
- function MixedTypeAnnotation({
1405
- parent
1406
- } = {}) {
1407
- return (0, _detachedNode.detachedProps)(parent, {
1258
+ function MixedTypeAnnotation(props = { ...null
1259
+ }) {
1260
+ return (0, _detachedNode.detachedProps)(props.parent, {
1408
1261
  type: 'MixedTypeAnnotation'
1409
1262
  });
1410
1263
  }
1411
1264
 
1412
- function NewExpression({
1413
- parent,
1414
- ...props
1415
- }) {
1416
- const node = (0, _detachedNode.detachedProps)(parent, {
1265
+ function NewExpression(props) {
1266
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1417
1267
  type: 'NewExpression',
1418
- ...props
1268
+ callee: (0, _detachedNode.asDetachedNode)(props.callee),
1269
+ typeArguments: (0, _detachedNode.asDetachedNode)(props.typeArguments),
1270
+ arguments: props.arguments.map(n => (0, _detachedNode.asDetachedNode)(n))
1419
1271
  });
1420
1272
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1421
1273
  return node;
1422
1274
  }
1423
1275
 
1424
- function NullableTypeAnnotation({
1425
- parent,
1426
- ...props
1427
- }) {
1428
- const node = (0, _detachedNode.detachedProps)(parent, {
1276
+ function NullableTypeAnnotation(props) {
1277
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1429
1278
  type: 'NullableTypeAnnotation',
1430
- ...props
1279
+ typeAnnotation: (0, _detachedNode.asDetachedNode)(props.typeAnnotation)
1431
1280
  });
1432
1281
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1433
1282
  return node;
1434
1283
  }
1435
1284
 
1436
- function NullLiteralTypeAnnotation({
1437
- parent
1438
- } = {}) {
1439
- return (0, _detachedNode.detachedProps)(parent, {
1285
+ function NullLiteralTypeAnnotation(props = { ...null
1286
+ }) {
1287
+ return (0, _detachedNode.detachedProps)(props.parent, {
1440
1288
  type: 'NullLiteralTypeAnnotation'
1441
1289
  });
1442
1290
  }
1443
1291
 
1444
- function NumberLiteralTypeAnnotation({
1445
- parent,
1446
- ...props
1447
- }) {
1448
- const node = (0, _detachedNode.detachedProps)(parent, {
1292
+ function NumberLiteralTypeAnnotation(props) {
1293
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1449
1294
  type: 'NumberLiteralTypeAnnotation',
1450
- ...props
1295
+ value: props.value,
1296
+ raw: props.raw
1451
1297
  });
1452
1298
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1453
1299
  return node;
1454
1300
  }
1455
1301
 
1456
- function NumberTypeAnnotation({
1457
- parent
1458
- } = {}) {
1459
- return (0, _detachedNode.detachedProps)(parent, {
1302
+ function NumberTypeAnnotation(props = { ...null
1303
+ }) {
1304
+ return (0, _detachedNode.detachedProps)(props.parent, {
1460
1305
  type: 'NumberTypeAnnotation'
1461
1306
  });
1462
1307
  }
1463
1308
 
1464
- function ObjectExpression({
1465
- parent,
1466
- ...props
1467
- }) {
1468
- const node = (0, _detachedNode.detachedProps)(parent, {
1309
+ function ObjectExpression(props) {
1310
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1469
1311
  type: 'ObjectExpression',
1470
- ...props
1312
+ properties: props.properties.map(n => (0, _detachedNode.asDetachedNode)(n))
1471
1313
  });
1472
1314
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1473
1315
  return node;
1474
1316
  }
1475
1317
 
1476
- function ObjectPattern({
1477
- parent,
1478
- ...props
1479
- }) {
1480
- const node = (0, _detachedNode.detachedProps)(parent, {
1318
+ function ObjectPattern(props) {
1319
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1481
1320
  type: 'ObjectPattern',
1482
- ...props
1321
+ properties: props.properties.map(n => (0, _detachedNode.asDetachedNode)(n)),
1322
+ typeAnnotation: (0, _detachedNode.asDetachedNode)(props.typeAnnotation)
1483
1323
  });
1484
1324
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1485
1325
  return node;
1486
1326
  }
1487
1327
 
1488
- function ObjectTypeAnnotation({
1489
- parent,
1490
- ...props
1491
- }) {
1492
- const node = (0, _detachedNode.detachedProps)(parent, {
1328
+ function ObjectTypeAnnotation(props) {
1329
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1493
1330
  type: 'ObjectTypeAnnotation',
1494
- ...props
1331
+ properties: props.properties.map(n => (0, _detachedNode.asDetachedNode)(n)),
1332
+ indexers: props.indexers.map(n => (0, _detachedNode.asDetachedNode)(n)),
1333
+ callProperties: props.callProperties.map(n => (0, _detachedNode.asDetachedNode)(n)),
1334
+ internalSlots: props.internalSlots.map(n => (0, _detachedNode.asDetachedNode)(n)),
1335
+ inexact: props.inexact,
1336
+ exact: props.exact
1495
1337
  });
1496
1338
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1497
1339
  return node;
1498
1340
  }
1499
1341
 
1500
- function ObjectTypeCallProperty({
1501
- parent,
1502
- ...props
1503
- }) {
1504
- const node = (0, _detachedNode.detachedProps)(parent, {
1342
+ function ObjectTypeCallProperty(props) {
1343
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1505
1344
  type: 'ObjectTypeCallProperty',
1506
- ...props
1345
+ value: (0, _detachedNode.asDetachedNode)(props.value),
1346
+ static: props.static
1507
1347
  });
1508
1348
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1509
1349
  return node;
1510
1350
  }
1511
1351
 
1512
- function ObjectTypeIndexer({
1513
- parent,
1514
- ...props
1515
- }) {
1516
- const node = (0, _detachedNode.detachedProps)(parent, {
1352
+ function ObjectTypeIndexer(props) {
1353
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1517
1354
  type: 'ObjectTypeIndexer',
1518
- ...props
1355
+ id: (0, _detachedNode.asDetachedNode)(props.id),
1356
+ key: (0, _detachedNode.asDetachedNode)(props.key),
1357
+ value: (0, _detachedNode.asDetachedNode)(props.value),
1358
+ static: props.static,
1359
+ variance: (0, _detachedNode.asDetachedNode)(props.variance)
1519
1360
  });
1520
1361
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1521
1362
  return node;
1522
1363
  }
1523
1364
 
1524
- function ObjectTypeInternalSlot({
1525
- parent,
1526
- ...props
1527
- }) {
1528
- const node = (0, _detachedNode.detachedProps)(parent, {
1365
+ function ObjectTypeInternalSlot(props) {
1366
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1529
1367
  type: 'ObjectTypeInternalSlot',
1530
- ...props
1368
+ id: (0, _detachedNode.asDetachedNode)(props.id),
1369
+ value: (0, _detachedNode.asDetachedNode)(props.value),
1370
+ optional: props.optional,
1371
+ static: props.static,
1372
+ method: props.method
1531
1373
  });
1532
1374
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1533
1375
  return node;
1534
1376
  }
1535
1377
 
1536
- function ObjectTypeProperty({
1537
- parent,
1538
- ...props
1539
- }) {
1540
- const node = (0, _detachedNode.detachedProps)(parent, {
1378
+ function ObjectTypeProperty(props) {
1379
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1541
1380
  type: 'ObjectTypeProperty',
1542
- ...props
1381
+ key: (0, _detachedNode.asDetachedNode)(props.key),
1382
+ value: (0, _detachedNode.asDetachedNode)(props.value),
1383
+ method: props.method,
1384
+ optional: props.optional,
1385
+ static: props.static,
1386
+ proto: props.proto,
1387
+ variance: (0, _detachedNode.asDetachedNode)(props.variance),
1388
+ kind: props.kind
1543
1389
  });
1544
1390
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1545
1391
  return node;
1546
1392
  }
1547
1393
 
1548
- function ObjectTypeSpreadProperty({
1549
- parent,
1550
- ...props
1551
- }) {
1552
- const node = (0, _detachedNode.detachedProps)(parent, {
1394
+ function ObjectTypeSpreadProperty(props) {
1395
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1553
1396
  type: 'ObjectTypeSpreadProperty',
1554
- ...props
1397
+ argument: (0, _detachedNode.asDetachedNode)(props.argument)
1555
1398
  });
1556
1399
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1557
1400
  return node;
1558
1401
  }
1559
1402
 
1560
- function OpaqueType({
1561
- parent,
1562
- ...props
1563
- }) {
1564
- const node = (0, _detachedNode.detachedProps)(parent, {
1403
+ function OpaqueType(props) {
1404
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1565
1405
  type: 'OpaqueType',
1566
- ...props
1406
+ id: (0, _detachedNode.asDetachedNode)(props.id),
1407
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
1408
+ impltype: (0, _detachedNode.asDetachedNode)(props.impltype),
1409
+ supertype: (0, _detachedNode.asDetachedNode)(props.supertype)
1567
1410
  });
1568
1411
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1569
1412
  return node;
1570
1413
  }
1571
1414
 
1572
- function OptionalIndexedAccessType({
1573
- parent,
1574
- ...props
1575
- }) {
1576
- const node = (0, _detachedNode.detachedProps)(parent, {
1415
+ function OptionalIndexedAccessType(props) {
1416
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1577
1417
  type: 'OptionalIndexedAccessType',
1578
- ...props
1418
+ objectType: (0, _detachedNode.asDetachedNode)(props.objectType),
1419
+ indexType: (0, _detachedNode.asDetachedNode)(props.indexType),
1420
+ optional: props.optional
1579
1421
  });
1580
1422
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1581
1423
  return node;
1582
1424
  }
1583
1425
 
1584
- function PrivateIdentifier({
1585
- parent,
1586
- ...props
1587
- }) {
1588
- const node = (0, _detachedNode.detachedProps)(parent, {
1426
+ function PrivateIdentifier(props) {
1427
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1589
1428
  type: 'PrivateIdentifier',
1590
- ...props
1429
+ name: props.name
1591
1430
  });
1592
1431
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1593
1432
  return node;
1594
1433
  }
1595
1434
 
1596
- function Property({
1597
- parent,
1598
- ...props
1599
- }) {
1600
- const node = (0, _detachedNode.detachedProps)(parent, {
1435
+ function Property(props) {
1436
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1601
1437
  type: 'Property',
1602
- ...props
1438
+ key: (0, _detachedNode.asDetachedNode)(props.key),
1439
+ value: (0, _detachedNode.asDetachedNode)(props.value),
1440
+ kind: props.kind,
1441
+ computed: props.computed,
1442
+ method: props.method,
1443
+ shorthand: props.shorthand
1603
1444
  });
1604
1445
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1605
1446
  return node;
1606
1447
  }
1607
1448
 
1608
- function PropertyDefinition({
1609
- parent,
1610
- ...props
1611
- }) {
1612
- const node = (0, _detachedNode.detachedProps)(parent, {
1449
+ function PropertyDefinition(props) {
1450
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1613
1451
  type: 'PropertyDefinition',
1614
- ...props
1452
+ key: (0, _detachedNode.asDetachedNode)(props.key),
1453
+ value: (0, _detachedNode.asDetachedNode)(props.value),
1454
+ computed: props.computed,
1455
+ static: props.static,
1456
+ declare: props.declare,
1457
+ optional: props.optional,
1458
+ variance: (0, _detachedNode.asDetachedNode)(props.variance),
1459
+ typeAnnotation: (0, _detachedNode.asDetachedNode)(props.typeAnnotation)
1615
1460
  });
1616
1461
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1617
1462
  return node;
1618
1463
  }
1619
1464
 
1620
- function QualifiedTypeIdentifier({
1621
- parent,
1622
- ...props
1623
- }) {
1624
- const node = (0, _detachedNode.detachedProps)(parent, {
1465
+ function QualifiedTypeIdentifier(props) {
1466
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1625
1467
  type: 'QualifiedTypeIdentifier',
1626
- ...props
1468
+ qualification: (0, _detachedNode.asDetachedNode)(props.qualification),
1469
+ id: (0, _detachedNode.asDetachedNode)(props.id)
1627
1470
  });
1628
1471
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1629
1472
  return node;
1630
1473
  }
1631
1474
 
1632
- function RestElement({
1633
- parent,
1634
- ...props
1635
- }) {
1636
- const node = (0, _detachedNode.detachedProps)(parent, {
1475
+ function RestElement(props) {
1476
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1637
1477
  type: 'RestElement',
1638
- ...props
1478
+ argument: (0, _detachedNode.asDetachedNode)(props.argument)
1639
1479
  });
1640
1480
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1641
1481
  return node;
1642
1482
  }
1643
1483
 
1644
- function ReturnStatement({
1645
- parent,
1646
- ...props
1647
- }) {
1648
- const node = (0, _detachedNode.detachedProps)(parent, {
1484
+ function ReturnStatement(props) {
1485
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1649
1486
  type: 'ReturnStatement',
1650
- ...props
1487
+ argument: (0, _detachedNode.asDetachedNode)(props.argument)
1651
1488
  });
1652
1489
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1653
1490
  return node;
1654
1491
  }
1655
1492
 
1656
- function SequenceExpression({
1657
- parent,
1658
- ...props
1659
- }) {
1660
- const node = (0, _detachedNode.detachedProps)(parent, {
1493
+ function SequenceExpression(props) {
1494
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1661
1495
  type: 'SequenceExpression',
1662
- ...props
1496
+ expressions: props.expressions.map(n => (0, _detachedNode.asDetachedNode)(n))
1663
1497
  });
1664
1498
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1665
1499
  return node;
1666
1500
  }
1667
1501
 
1668
- function SpreadElement({
1669
- parent,
1670
- ...props
1671
- }) {
1672
- const node = (0, _detachedNode.detachedProps)(parent, {
1502
+ function SpreadElement(props) {
1503
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1673
1504
  type: 'SpreadElement',
1674
- ...props
1505
+ argument: (0, _detachedNode.asDetachedNode)(props.argument)
1675
1506
  });
1676
1507
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1677
1508
  return node;
1678
1509
  }
1679
1510
 
1680
- function StringLiteralTypeAnnotation({
1681
- parent,
1682
- ...props
1683
- }) {
1684
- const node = (0, _detachedNode.detachedProps)(parent, {
1511
+ function StringLiteralTypeAnnotation(props) {
1512
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1685
1513
  type: 'StringLiteralTypeAnnotation',
1686
- ...props
1514
+ value: props.value,
1515
+ raw: props.raw
1687
1516
  });
1688
1517
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1689
1518
  return node;
1690
1519
  }
1691
1520
 
1692
- function StringTypeAnnotation({
1693
- parent
1694
- } = {}) {
1695
- return (0, _detachedNode.detachedProps)(parent, {
1521
+ function StringTypeAnnotation(props = { ...null
1522
+ }) {
1523
+ return (0, _detachedNode.detachedProps)(props.parent, {
1696
1524
  type: 'StringTypeAnnotation'
1697
1525
  });
1698
1526
  }
1699
1527
 
1700
- function Super({
1701
- parent
1702
- } = {}) {
1703
- return (0, _detachedNode.detachedProps)(parent, {
1528
+ function Super(props = { ...null
1529
+ }) {
1530
+ return (0, _detachedNode.detachedProps)(props.parent, {
1704
1531
  type: 'Super'
1705
1532
  });
1706
1533
  }
1707
1534
 
1708
- function SwitchCase({
1709
- parent,
1710
- ...props
1711
- }) {
1712
- const node = (0, _detachedNode.detachedProps)(parent, {
1535
+ function SwitchCase(props) {
1536
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1713
1537
  type: 'SwitchCase',
1714
- ...props
1538
+ test: (0, _detachedNode.asDetachedNode)(props.test),
1539
+ consequent: props.consequent.map(n => (0, _detachedNode.asDetachedNode)(n))
1715
1540
  });
1716
1541
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1717
1542
  return node;
1718
1543
  }
1719
1544
 
1720
- function SwitchStatement({
1721
- parent,
1722
- ...props
1723
- }) {
1724
- const node = (0, _detachedNode.detachedProps)(parent, {
1545
+ function SwitchStatement(props) {
1546
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1725
1547
  type: 'SwitchStatement',
1726
- ...props
1548
+ discriminant: (0, _detachedNode.asDetachedNode)(props.discriminant),
1549
+ cases: props.cases.map(n => (0, _detachedNode.asDetachedNode)(n))
1727
1550
  });
1728
1551
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1729
1552
  return node;
1730
1553
  }
1731
1554
 
1732
- function SymbolTypeAnnotation({
1733
- parent
1734
- } = {}) {
1735
- return (0, _detachedNode.detachedProps)(parent, {
1555
+ function SymbolTypeAnnotation(props = { ...null
1556
+ }) {
1557
+ return (0, _detachedNode.detachedProps)(props.parent, {
1736
1558
  type: 'SymbolTypeAnnotation'
1737
1559
  });
1738
1560
  }
1739
1561
 
1740
- function TaggedTemplateExpression({
1741
- parent,
1742
- ...props
1743
- }) {
1744
- const node = (0, _detachedNode.detachedProps)(parent, {
1562
+ function TaggedTemplateExpression(props) {
1563
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1745
1564
  type: 'TaggedTemplateExpression',
1746
- ...props
1565
+ tag: (0, _detachedNode.asDetachedNode)(props.tag),
1566
+ quasi: (0, _detachedNode.asDetachedNode)(props.quasi)
1747
1567
  });
1748
1568
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1749
1569
  return node;
1750
1570
  }
1751
1571
 
1752
- function TemplateLiteral({
1753
- parent,
1754
- ...props
1755
- }) {
1756
- const node = (0, _detachedNode.detachedProps)(parent, {
1572
+ function TemplateLiteral(props) {
1573
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1757
1574
  type: 'TemplateLiteral',
1758
- ...props
1575
+ quasis: props.quasis.map(n => (0, _detachedNode.asDetachedNode)(n)),
1576
+ expressions: props.expressions.map(n => (0, _detachedNode.asDetachedNode)(n))
1759
1577
  });
1760
1578
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1761
1579
  return node;
1762
1580
  }
1763
1581
 
1764
- function ThisExpression({
1765
- parent
1766
- } = {}) {
1767
- return (0, _detachedNode.detachedProps)(parent, {
1582
+ function ThisExpression(props = { ...null
1583
+ }) {
1584
+ return (0, _detachedNode.detachedProps)(props.parent, {
1768
1585
  type: 'ThisExpression'
1769
1586
  });
1770
1587
  }
1771
1588
 
1772
- function ThisTypeAnnotation({
1773
- parent
1774
- } = {}) {
1775
- return (0, _detachedNode.detachedProps)(parent, {
1589
+ function ThisTypeAnnotation(props = { ...null
1590
+ }) {
1591
+ return (0, _detachedNode.detachedProps)(props.parent, {
1776
1592
  type: 'ThisTypeAnnotation'
1777
1593
  });
1778
1594
  }
1779
1595
 
1780
- function ThrowStatement({
1781
- parent,
1782
- ...props
1783
- }) {
1784
- const node = (0, _detachedNode.detachedProps)(parent, {
1596
+ function ThrowStatement(props) {
1597
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1785
1598
  type: 'ThrowStatement',
1786
- ...props
1599
+ argument: (0, _detachedNode.asDetachedNode)(props.argument)
1787
1600
  });
1788
1601
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1789
1602
  return node;
1790
1603
  }
1791
1604
 
1792
- function TryStatement({
1793
- parent,
1794
- ...props
1795
- }) {
1796
- const node = (0, _detachedNode.detachedProps)(parent, {
1605
+ function TryStatement(props) {
1606
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1797
1607
  type: 'TryStatement',
1798
- ...props
1608
+ block: (0, _detachedNode.asDetachedNode)(props.block),
1609
+ handler: (0, _detachedNode.asDetachedNode)(props.handler),
1610
+ finalizer: (0, _detachedNode.asDetachedNode)(props.finalizer)
1799
1611
  });
1800
1612
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1801
1613
  return node;
1802
1614
  }
1803
1615
 
1804
- function TupleTypeAnnotation({
1805
- parent,
1806
- ...props
1807
- }) {
1808
- const node = (0, _detachedNode.detachedProps)(parent, {
1616
+ function TupleTypeAnnotation(props) {
1617
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1809
1618
  type: 'TupleTypeAnnotation',
1810
- ...props
1619
+ types: props.types.map(n => (0, _detachedNode.asDetachedNode)(n))
1811
1620
  });
1812
1621
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1813
1622
  return node;
1814
1623
  }
1815
1624
 
1816
- function TypeAlias({
1817
- parent,
1818
- ...props
1819
- }) {
1820
- const node = (0, _detachedNode.detachedProps)(parent, {
1625
+ function TypeAlias(props) {
1626
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1821
1627
  type: 'TypeAlias',
1822
- ...props
1628
+ id: (0, _detachedNode.asDetachedNode)(props.id),
1629
+ typeParameters: (0, _detachedNode.asDetachedNode)(props.typeParameters),
1630
+ right: (0, _detachedNode.asDetachedNode)(props.right)
1823
1631
  });
1824
1632
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1825
1633
  return node;
1826
1634
  }
1827
1635
 
1828
- function TypeAnnotation({
1829
- parent,
1830
- ...props
1831
- }) {
1832
- const node = (0, _detachedNode.detachedProps)(parent, {
1636
+ function TypeAnnotation(props) {
1637
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1833
1638
  type: 'TypeAnnotation',
1834
- ...props
1639
+ typeAnnotation: (0, _detachedNode.asDetachedNode)(props.typeAnnotation)
1835
1640
  });
1836
1641
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1837
1642
  return node;
1838
1643
  }
1839
1644
 
1840
- function TypeCastExpression({
1841
- parent,
1842
- ...props
1843
- }) {
1844
- const node = (0, _detachedNode.detachedProps)(parent, {
1645
+ function TypeCastExpression(props) {
1646
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1845
1647
  type: 'TypeCastExpression',
1846
- ...props
1648
+ expression: (0, _detachedNode.asDetachedNode)(props.expression),
1649
+ typeAnnotation: (0, _detachedNode.asDetachedNode)(props.typeAnnotation)
1847
1650
  });
1848
1651
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1849
1652
  return node;
1850
1653
  }
1851
1654
 
1852
- function TypeofTypeAnnotation({
1853
- parent,
1854
- ...props
1855
- }) {
1856
- const node = (0, _detachedNode.detachedProps)(parent, {
1655
+ function TypeofTypeAnnotation(props) {
1656
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1857
1657
  type: 'TypeofTypeAnnotation',
1858
- ...props
1658
+ argument: (0, _detachedNode.asDetachedNode)(props.argument)
1859
1659
  });
1860
1660
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1861
1661
  return node;
1862
1662
  }
1863
1663
 
1864
- function TypeParameter({
1865
- parent,
1866
- ...props
1867
- }) {
1868
- const node = (0, _detachedNode.detachedProps)(parent, {
1664
+ function TypeParameter(props) {
1665
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1869
1666
  type: 'TypeParameter',
1870
- ...props
1667
+ name: props.name,
1668
+ bound: (0, _detachedNode.asDetachedNode)(props.bound),
1669
+ variance: (0, _detachedNode.asDetachedNode)(props.variance),
1670
+ default: (0, _detachedNode.asDetachedNode)(props.default)
1871
1671
  });
1872
1672
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1873
1673
  return node;
1874
1674
  }
1875
1675
 
1876
- function TypeParameterDeclaration({
1877
- parent,
1878
- ...props
1879
- }) {
1880
- const node = (0, _detachedNode.detachedProps)(parent, {
1676
+ function TypeParameterDeclaration(props) {
1677
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1881
1678
  type: 'TypeParameterDeclaration',
1882
- ...props
1679
+ params: props.params.map(n => (0, _detachedNode.asDetachedNode)(n))
1883
1680
  });
1884
1681
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1885
1682
  return node;
1886
1683
  }
1887
1684
 
1888
- function TypeParameterInstantiation({
1889
- parent,
1890
- ...props
1891
- }) {
1892
- const node = (0, _detachedNode.detachedProps)(parent, {
1685
+ function TypeParameterInstantiation(props) {
1686
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1893
1687
  type: 'TypeParameterInstantiation',
1894
- ...props
1688
+ params: props.params.map(n => (0, _detachedNode.asDetachedNode)(n))
1895
1689
  });
1896
1690
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1897
1691
  return node;
1898
1692
  }
1899
1693
 
1900
- function UnaryExpression({
1901
- parent,
1902
- ...props
1903
- }) {
1904
- const node = (0, _detachedNode.detachedProps)(parent, {
1694
+ function UnaryExpression(props) {
1695
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1905
1696
  type: 'UnaryExpression',
1906
- ...props
1697
+ operator: props.operator,
1698
+ argument: (0, _detachedNode.asDetachedNode)(props.argument),
1699
+ prefix: props.prefix
1907
1700
  });
1908
1701
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1909
1702
  return node;
1910
1703
  }
1911
1704
 
1912
- function UnionTypeAnnotation({
1913
- parent,
1914
- ...props
1915
- }) {
1916
- const node = (0, _detachedNode.detachedProps)(parent, {
1705
+ function UnionTypeAnnotation(props) {
1706
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1917
1707
  type: 'UnionTypeAnnotation',
1918
- ...props
1708
+ types: props.types.map(n => (0, _detachedNode.asDetachedNode)(n))
1919
1709
  });
1920
1710
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1921
1711
  return node;
1922
1712
  }
1923
1713
 
1924
- function UpdateExpression({
1925
- parent,
1926
- ...props
1927
- }) {
1928
- const node = (0, _detachedNode.detachedProps)(parent, {
1714
+ function UpdateExpression(props) {
1715
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1929
1716
  type: 'UpdateExpression',
1930
- ...props
1717
+ operator: props.operator,
1718
+ argument: (0, _detachedNode.asDetachedNode)(props.argument),
1719
+ prefix: props.prefix
1931
1720
  });
1932
1721
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1933
1722
  return node;
1934
1723
  }
1935
1724
 
1936
- function VariableDeclaration({
1937
- parent,
1938
- ...props
1939
- }) {
1940
- const node = (0, _detachedNode.detachedProps)(parent, {
1725
+ function VariableDeclaration(props) {
1726
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1941
1727
  type: 'VariableDeclaration',
1942
- ...props
1728
+ kind: props.kind,
1729
+ declarations: props.declarations.map(n => (0, _detachedNode.asDetachedNode)(n))
1943
1730
  });
1944
1731
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1945
1732
  return node;
1946
1733
  }
1947
1734
 
1948
- function VariableDeclarator({
1949
- parent,
1950
- ...props
1951
- }) {
1952
- const node = (0, _detachedNode.detachedProps)(parent, {
1735
+ function VariableDeclarator(props) {
1736
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1953
1737
  type: 'VariableDeclarator',
1954
- ...props
1738
+ init: (0, _detachedNode.asDetachedNode)(props.init),
1739
+ id: (0, _detachedNode.asDetachedNode)(props.id)
1955
1740
  });
1956
1741
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1957
1742
  return node;
1958
1743
  }
1959
1744
 
1960
- function Variance({
1961
- parent,
1962
- ...props
1963
- }) {
1964
- const node = (0, _detachedNode.detachedProps)(parent, {
1745
+ function Variance(props) {
1746
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1965
1747
  type: 'Variance',
1966
- ...props
1748
+ kind: props.kind
1967
1749
  });
1968
1750
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1969
1751
  return node;
1970
1752
  }
1971
1753
 
1972
- function VoidTypeAnnotation({
1973
- parent
1974
- } = {}) {
1975
- return (0, _detachedNode.detachedProps)(parent, {
1754
+ function VoidTypeAnnotation(props = { ...null
1755
+ }) {
1756
+ return (0, _detachedNode.detachedProps)(props.parent, {
1976
1757
  type: 'VoidTypeAnnotation'
1977
1758
  });
1978
1759
  }
1979
1760
 
1980
- function WhileStatement({
1981
- parent,
1982
- ...props
1983
- }) {
1984
- const node = (0, _detachedNode.detachedProps)(parent, {
1761
+ function WhileStatement(props) {
1762
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1985
1763
  type: 'WhileStatement',
1986
- ...props
1764
+ body: (0, _detachedNode.asDetachedNode)(props.body),
1765
+ test: (0, _detachedNode.asDetachedNode)(props.test)
1987
1766
  });
1988
1767
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
1989
1768
  return node;
1990
1769
  }
1991
1770
 
1992
- function WithStatement({
1993
- parent,
1994
- ...props
1995
- }) {
1996
- const node = (0, _detachedNode.detachedProps)(parent, {
1771
+ function WithStatement(props) {
1772
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
1997
1773
  type: 'WithStatement',
1998
- ...props
1774
+ object: (0, _detachedNode.asDetachedNode)(props.object),
1775
+ body: (0, _detachedNode.asDetachedNode)(props.body)
1999
1776
  });
2000
1777
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
2001
1778
  return node;
2002
1779
  }
2003
1780
 
2004
- function YieldExpression({
2005
- parent,
2006
- ...props
2007
- }) {
2008
- const node = (0, _detachedNode.detachedProps)(parent, {
1781
+ function YieldExpression(props) {
1782
+ const node = (0, _detachedNode.detachedProps)(props.parent, {
2009
1783
  type: 'YieldExpression',
2010
- ...props
1784
+ argument: (0, _detachedNode.asDetachedNode)(props.argument),
1785
+ delegate: props.delegate
2011
1786
  });
2012
1787
  (0, _detachedNode.setParentPointersInDirectChildren)(node);
2013
1788
  return node;