@putout/babel 5.3.5 → 5.3.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/README.md +1 -0
- package/bundle/index.js +125 -111
- package/bundle/metafile-esm.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
Pre-builts of [Babel 8](https://github.com/babel/babel/releases/tag/v8.0.0-rc.2).
|
|
7
7
|
Includes:
|
|
8
8
|
|
|
9
|
+
- [`[Babel 8] Remove Import from the Expression alias`](https://github.com/babel/babel/pull/17867);
|
|
9
10
|
- [`Add locations option to parser`](https://github.com/babel/babel/pull/16935);
|
|
10
11
|
- [`Improve trailing comma comment handling`](https://github.com/babel/babel/pull/117782);
|
|
11
12
|
- [`Fix: parser: async x => {} must be in leading pos`](https://github.com/babel/babel/pull/17839);
|
package/bundle/index.js
CHANGED
|
@@ -3836,16 +3836,6 @@ function isImportSpecifier(node, opts) {
|
|
|
3836
3836
|
return opts == null || shallowEqual(node, opts);
|
|
3837
3837
|
}
|
|
3838
3838
|
|
|
3839
|
-
function isImportExpression(node, opts) {
|
|
3840
|
-
if (!node)
|
|
3841
|
-
return false;
|
|
3842
|
-
|
|
3843
|
-
if (node.type !== 'ImportExpression')
|
|
3844
|
-
return false;
|
|
3845
|
-
|
|
3846
|
-
return opts == null || shallowEqual(node, opts);
|
|
3847
|
-
}
|
|
3848
|
-
|
|
3849
3839
|
function isMetaProperty(node, opts) {
|
|
3850
3840
|
if (!node)
|
|
3851
3841
|
return false;
|
|
@@ -3946,6 +3936,16 @@ function isAwaitExpression(node, opts) {
|
|
|
3946
3936
|
return opts == null || shallowEqual(node, opts);
|
|
3947
3937
|
}
|
|
3948
3938
|
|
|
3939
|
+
function isImportExpression(node, opts) {
|
|
3940
|
+
if (!node)
|
|
3941
|
+
return false;
|
|
3942
|
+
|
|
3943
|
+
if (node.type !== 'ImportExpression')
|
|
3944
|
+
return false;
|
|
3945
|
+
|
|
3946
|
+
return opts == null || shallowEqual(node, opts);
|
|
3947
|
+
}
|
|
3948
|
+
|
|
3949
3949
|
function isImport(node, opts) {
|
|
3950
3950
|
if (!node)
|
|
3951
3951
|
return false;
|
|
@@ -5727,7 +5727,6 @@ function isStandardized(node, opts) {
|
|
|
5727
5727
|
case 'ImportDefaultSpecifier':
|
|
5728
5728
|
case 'ImportNamespaceSpecifier':
|
|
5729
5729
|
case 'ImportSpecifier':
|
|
5730
|
-
case 'ImportExpression':
|
|
5731
5730
|
case 'MetaProperty':
|
|
5732
5731
|
case 'ClassMethod':
|
|
5733
5732
|
case 'ObjectPattern':
|
|
@@ -5738,6 +5737,7 @@ function isStandardized(node, opts) {
|
|
|
5738
5737
|
case 'TemplateLiteral':
|
|
5739
5738
|
case 'YieldExpression':
|
|
5740
5739
|
case 'AwaitExpression':
|
|
5740
|
+
case 'ImportExpression':
|
|
5741
5741
|
case 'Import':
|
|
5742
5742
|
case 'BigIntLiteral':
|
|
5743
5743
|
case 'ExportNamespaceSpecifier':
|
|
@@ -5801,13 +5801,12 @@ function isExpression(node, opts) {
|
|
|
5801
5801
|
case 'UpdateExpression':
|
|
5802
5802
|
case 'ArrowFunctionExpression':
|
|
5803
5803
|
case 'ClassExpression':
|
|
5804
|
-
case 'ImportExpression':
|
|
5805
5804
|
case 'MetaProperty':
|
|
5806
5805
|
case 'TaggedTemplateExpression':
|
|
5807
5806
|
case 'TemplateLiteral':
|
|
5808
5807
|
case 'YieldExpression':
|
|
5809
5808
|
case 'AwaitExpression':
|
|
5810
|
-
case '
|
|
5809
|
+
case 'ImportExpression':
|
|
5811
5810
|
case 'BigIntLiteral':
|
|
5812
5811
|
case 'OptionalMemberExpression':
|
|
5813
5812
|
case 'OptionalCallExpression':
|
|
@@ -7660,6 +7659,29 @@ var classMethodOrPropertyUnionShapeCommon = (allowPrivateName = false) => ({
|
|
|
7660
7659
|
},
|
|
7661
7660
|
});
|
|
7662
7661
|
|
|
7662
|
+
var memberExpressionUnionShapeCommon = {
|
|
7663
|
+
unionShape: {
|
|
7664
|
+
discriminator: 'computed',
|
|
7665
|
+
shapes: [{
|
|
7666
|
+
name: 'computed',
|
|
7667
|
+
value: [true],
|
|
7668
|
+
properties: {
|
|
7669
|
+
property: {
|
|
7670
|
+
validate: assertNodeType('Expression'),
|
|
7671
|
+
},
|
|
7672
|
+
},
|
|
7673
|
+
}, {
|
|
7674
|
+
name: 'nonComputed',
|
|
7675
|
+
value: [false],
|
|
7676
|
+
properties: {
|
|
7677
|
+
property: {
|
|
7678
|
+
validate: assertNodeType('Identifier', 'PrivateName'),
|
|
7679
|
+
},
|
|
7680
|
+
},
|
|
7681
|
+
}],
|
|
7682
|
+
},
|
|
7683
|
+
};
|
|
7684
|
+
|
|
7663
7685
|
var defineType$4 = defineAliasedType('Standardized');
|
|
7664
7686
|
|
|
7665
7687
|
defineType$4('ArrayExpression', {
|
|
@@ -7730,6 +7752,26 @@ defineType$4('BinaryExpression', {
|
|
|
7730
7752
|
validate: assertNodeType('Expression'),
|
|
7731
7753
|
},
|
|
7732
7754
|
},
|
|
7755
|
+
unionShape: {
|
|
7756
|
+
discriminator: 'operator',
|
|
7757
|
+
shapes: [{
|
|
7758
|
+
name: 'in',
|
|
7759
|
+
value: ['in'],
|
|
7760
|
+
properties: {
|
|
7761
|
+
left: {
|
|
7762
|
+
validate: assertNodeType('Expression', 'PrivateName'),
|
|
7763
|
+
},
|
|
7764
|
+
},
|
|
7765
|
+
}, {
|
|
7766
|
+
name: 'notIn',
|
|
7767
|
+
value: BINARY_OPERATORS.filter((op) => op !== 'in'),
|
|
7768
|
+
properties: {
|
|
7769
|
+
left: {
|
|
7770
|
+
validate: assertNodeType('Expression'),
|
|
7771
|
+
},
|
|
7772
|
+
},
|
|
7773
|
+
}],
|
|
7774
|
+
},
|
|
7733
7775
|
visitor: ['left', 'right'],
|
|
7734
7776
|
aliases: ['Binary', 'Expression'],
|
|
7735
7777
|
});
|
|
@@ -7798,7 +7840,7 @@ defineType$4('CallExpression', {
|
|
|
7798
7840
|
aliases: ['Expression'],
|
|
7799
7841
|
fields: {
|
|
7800
7842
|
callee: {
|
|
7801
|
-
validate: assertNodeType('Expression', 'Super', 'V8IntrinsicIdentifier'),
|
|
7843
|
+
validate: assertNodeType('Expression', 'Super', 'Import', 'V8IntrinsicIdentifier'),
|
|
7802
7844
|
},
|
|
7803
7845
|
arguments: validateArrayOfType('Expression', 'SpreadElement', 'ArgumentPlaceholder'),
|
|
7804
7846
|
typeArguments: {
|
|
@@ -8296,7 +8338,6 @@ defineType$4('MemberExpression', {
|
|
|
8296
8338
|
'object',
|
|
8297
8339
|
'property',
|
|
8298
8340
|
'computed',
|
|
8299
|
-
...[],
|
|
8300
8341
|
],
|
|
8301
8342
|
visitor: ['object', 'property'],
|
|
8302
8343
|
aliases: [
|
|
@@ -8304,26 +8345,7 @@ defineType$4('MemberExpression', {
|
|
|
8304
8345
|
'LVal',
|
|
8305
8346
|
'PatternLike',
|
|
8306
8347
|
],
|
|
8307
|
-
|
|
8308
|
-
discriminator: 'computed',
|
|
8309
|
-
shapes: [{
|
|
8310
|
-
name: 'computed',
|
|
8311
|
-
value: [true],
|
|
8312
|
-
properties: {
|
|
8313
|
-
property: {
|
|
8314
|
-
validate: assertNodeType('Expression'),
|
|
8315
|
-
},
|
|
8316
|
-
},
|
|
8317
|
-
}, {
|
|
8318
|
-
name: 'nonComputed',
|
|
8319
|
-
value: [false],
|
|
8320
|
-
properties: {
|
|
8321
|
-
property: {
|
|
8322
|
-
validate: assertNodeType('Identifier', 'PrivateName'),
|
|
8323
|
-
},
|
|
8324
|
-
},
|
|
8325
|
-
}],
|
|
8326
|
-
},
|
|
8348
|
+
...memberExpressionUnionShapeCommon,
|
|
8327
8349
|
fields: {
|
|
8328
8350
|
object: {
|
|
8329
8351
|
validate: assertNodeType('Expression', 'Super'),
|
|
@@ -8461,28 +8483,8 @@ defineType$4('ObjectProperty', {
|
|
|
8461
8483
|
'value',
|
|
8462
8484
|
'computed',
|
|
8463
8485
|
'shorthand',
|
|
8464
|
-
...[],
|
|
8465
8486
|
],
|
|
8466
|
-
|
|
8467
|
-
discriminator: 'computed',
|
|
8468
|
-
shapes: [{
|
|
8469
|
-
name: 'computed',
|
|
8470
|
-
value: [true],
|
|
8471
|
-
properties: {
|
|
8472
|
-
key: {
|
|
8473
|
-
validate: assertNodeType('Expression'),
|
|
8474
|
-
},
|
|
8475
|
-
},
|
|
8476
|
-
}, {
|
|
8477
|
-
name: 'nonComputed',
|
|
8478
|
-
value: [false],
|
|
8479
|
-
properties: {
|
|
8480
|
-
key: {
|
|
8481
|
-
validate: assertNodeType('Identifier', 'StringLiteral', 'NumericLiteral', 'BigIntLiteral', 'PrivateName'),
|
|
8482
|
-
},
|
|
8483
|
-
},
|
|
8484
|
-
}],
|
|
8485
|
-
},
|
|
8487
|
+
...classMethodOrPropertyUnionShapeCommon(true),
|
|
8486
8488
|
fields: {
|
|
8487
8489
|
computed: {
|
|
8488
8490
|
default: false,
|
|
@@ -9083,7 +9085,21 @@ defineType$4('ExportNamedDeclaration', {
|
|
|
9083
9085
|
throw new TypeError('Cannot export a declaration from a source');
|
|
9084
9086
|
}
|
|
9085
9087
|
}, {
|
|
9086
|
-
oneOfNodeTypes: [
|
|
9088
|
+
oneOfNodeTypes: [
|
|
9089
|
+
'VariableDeclaration',
|
|
9090
|
+
'FunctionDeclaration',
|
|
9091
|
+
'ClassDeclaration',
|
|
9092
|
+
'TSDeclareFunction',
|
|
9093
|
+
'TSEnumDeclaration',
|
|
9094
|
+
'TSImportEqualsDeclaration',
|
|
9095
|
+
'TSInterfaceDeclaration',
|
|
9096
|
+
'TSModuleDeclaration',
|
|
9097
|
+
'TSTypeAliasDeclaration',
|
|
9098
|
+
'EnumDeclaration',
|
|
9099
|
+
'InterfaceDeclaration',
|
|
9100
|
+
'OpaqueType',
|
|
9101
|
+
'TypeAlias',
|
|
9102
|
+
],
|
|
9087
9103
|
})),
|
|
9088
9104
|
},
|
|
9089
9105
|
...importAttributes,
|
|
@@ -9257,23 +9273,6 @@ defineType$4('ImportSpecifier', {
|
|
|
9257
9273
|
},
|
|
9258
9274
|
},
|
|
9259
9275
|
});
|
|
9260
|
-
defineType$4('ImportExpression', {
|
|
9261
|
-
visitor: ['source', 'options'],
|
|
9262
|
-
aliases: ['Expression'],
|
|
9263
|
-
fields: {
|
|
9264
|
-
phase: {
|
|
9265
|
-
default: null,
|
|
9266
|
-
validate: assertOneOf('source', 'defer'),
|
|
9267
|
-
},
|
|
9268
|
-
source: {
|
|
9269
|
-
validate: assertNodeType('Expression'),
|
|
9270
|
-
},
|
|
9271
|
-
options: {
|
|
9272
|
-
validate: assertNodeType('Expression'),
|
|
9273
|
-
optional: true,
|
|
9274
|
-
},
|
|
9275
|
-
},
|
|
9276
|
-
});
|
|
9277
9276
|
defineType$4('MetaProperty', {
|
|
9278
9277
|
visitor: ['meta', 'property'],
|
|
9279
9278
|
aliases: ['Expression'],
|
|
@@ -9429,7 +9428,7 @@ defineType$4('SpreadElement', {
|
|
|
9429
9428
|
},
|
|
9430
9429
|
},
|
|
9431
9430
|
});
|
|
9432
|
-
defineType$4('Super'
|
|
9431
|
+
defineType$4('Super');
|
|
9433
9432
|
defineType$4('TaggedTemplateExpression', {
|
|
9434
9433
|
visitor: [
|
|
9435
9434
|
'tag',
|
|
@@ -9542,9 +9541,24 @@ defineType$4('AwaitExpression', {
|
|
|
9542
9541
|
},
|
|
9543
9542
|
},
|
|
9544
9543
|
});
|
|
9545
|
-
defineType$4('
|
|
9544
|
+
defineType$4('ImportExpression', {
|
|
9545
|
+
visitor: ['source', 'options'],
|
|
9546
9546
|
aliases: ['Expression'],
|
|
9547
|
+
fields: {
|
|
9548
|
+
phase: {
|
|
9549
|
+
default: null,
|
|
9550
|
+
validate: assertOneOf('source', 'defer'),
|
|
9551
|
+
},
|
|
9552
|
+
source: {
|
|
9553
|
+
validate: assertNodeType('Expression'),
|
|
9554
|
+
},
|
|
9555
|
+
options: {
|
|
9556
|
+
validate: assertNodeType('Expression'),
|
|
9557
|
+
optional: true,
|
|
9558
|
+
},
|
|
9559
|
+
},
|
|
9547
9560
|
});
|
|
9561
|
+
defineType$4('Import');
|
|
9548
9562
|
defineType$4('BigIntLiteral', {
|
|
9549
9563
|
builder: ['value'],
|
|
9550
9564
|
fields: {
|
|
@@ -9577,19 +9591,20 @@ defineType$4('OptionalMemberExpression', {
|
|
|
9577
9591
|
],
|
|
9578
9592
|
visitor: ['object', 'property'],
|
|
9579
9593
|
aliases: ['Expression'],
|
|
9594
|
+
...memberExpressionUnionShapeCommon,
|
|
9580
9595
|
fields: {
|
|
9581
9596
|
object: {
|
|
9582
9597
|
validate: assertNodeType('Expression'),
|
|
9583
9598
|
},
|
|
9584
9599
|
property: {
|
|
9585
9600
|
validate: (function() {
|
|
9586
|
-
const normal = assertNodeType('Identifier');
|
|
9601
|
+
const normal = assertNodeType('Identifier', 'PrivateName');
|
|
9587
9602
|
const computed = assertNodeType('Expression');
|
|
9588
9603
|
const validator = Object.assign(function(node, key, val) {
|
|
9589
9604
|
const validator2 = node.computed ? computed : normal;
|
|
9590
9605
|
validator2(node, key, val);
|
|
9591
9606
|
}, {
|
|
9592
|
-
oneOfNodeTypes: ['Expression', '
|
|
9607
|
+
oneOfNodeTypes: ['Expression', 'PrivateName'],
|
|
9593
9608
|
});
|
|
9594
9609
|
|
|
9595
9610
|
return validator;
|
|
@@ -12404,19 +12419,6 @@ function importSpecifier(local, imported) {
|
|
|
12404
12419
|
return node;
|
|
12405
12420
|
}
|
|
12406
12421
|
|
|
12407
|
-
function importExpression(source, options = null) {
|
|
12408
|
-
const node = {
|
|
12409
|
-
type: 'ImportExpression',
|
|
12410
|
-
source,
|
|
12411
|
-
options,
|
|
12412
|
-
};
|
|
12413
|
-
|
|
12414
|
-
const defs2 = NODE_FIELDS.ImportExpression;
|
|
12415
|
-
validate(defs2.source, node, 'source', source, 1);
|
|
12416
|
-
validate(defs2.options, node, 'options', options, 1);
|
|
12417
|
-
return node;
|
|
12418
|
-
}
|
|
12419
|
-
|
|
12420
12422
|
function metaProperty(meta, property) {
|
|
12421
12423
|
const node = {
|
|
12422
12424
|
type: 'MetaProperty',
|
|
@@ -12546,6 +12548,19 @@ function awaitExpression(argument) {
|
|
|
12546
12548
|
return node;
|
|
12547
12549
|
}
|
|
12548
12550
|
|
|
12551
|
+
function importExpression(source, options = null) {
|
|
12552
|
+
const node = {
|
|
12553
|
+
type: 'ImportExpression',
|
|
12554
|
+
source,
|
|
12555
|
+
options,
|
|
12556
|
+
};
|
|
12557
|
+
|
|
12558
|
+
const defs2 = NODE_FIELDS.ImportExpression;
|
|
12559
|
+
validate(defs2.source, node, 'source', source, 1);
|
|
12560
|
+
validate(defs2.options, node, 'options', options, 1);
|
|
12561
|
+
return node;
|
|
12562
|
+
}
|
|
12563
|
+
|
|
12549
12564
|
function _import() {
|
|
12550
12565
|
return {
|
|
12551
12566
|
type: 'Import',
|
|
@@ -14930,7 +14945,6 @@ var ImportDeclaration = alias('importDeclaration');
|
|
|
14930
14945
|
var ImportDefaultSpecifier = alias('importDefaultSpecifier');
|
|
14931
14946
|
var ImportNamespaceSpecifier = alias('importNamespaceSpecifier');
|
|
14932
14947
|
var ImportSpecifier = alias('importSpecifier');
|
|
14933
|
-
var ImportExpression = alias('importExpression');
|
|
14934
14948
|
var MetaProperty = alias('metaProperty');
|
|
14935
14949
|
var ClassMethod = alias('classMethod');
|
|
14936
14950
|
var ObjectPattern = alias('objectPattern');
|
|
@@ -14941,6 +14955,7 @@ var TemplateElement = alias('templateElement');
|
|
|
14941
14955
|
var TemplateLiteral = alias('templateLiteral');
|
|
14942
14956
|
var YieldExpression = alias('yieldExpression');
|
|
14943
14957
|
var AwaitExpression = alias('awaitExpression');
|
|
14958
|
+
var ImportExpression = alias('importExpression');
|
|
14944
14959
|
var Import = alias('import');
|
|
14945
14960
|
var BigIntLiteral = alias('bigIntLiteral');
|
|
14946
14961
|
var ExportNamespaceSpecifier = alias('exportNamespaceSpecifier');
|
|
@@ -15457,10 +15472,6 @@ function assertImportSpecifier(node, opts) {
|
|
|
15457
15472
|
assert('ImportSpecifier', node, opts);
|
|
15458
15473
|
}
|
|
15459
15474
|
|
|
15460
|
-
function assertImportExpression(node, opts) {
|
|
15461
|
-
assert('ImportExpression', node, opts);
|
|
15462
|
-
}
|
|
15463
|
-
|
|
15464
15475
|
function assertMetaProperty(node, opts) {
|
|
15465
15476
|
assert('MetaProperty', node, opts);
|
|
15466
15477
|
}
|
|
@@ -15501,6 +15512,10 @@ function assertAwaitExpression(node, opts) {
|
|
|
15501
15512
|
assert('AwaitExpression', node, opts);
|
|
15502
15513
|
}
|
|
15503
15514
|
|
|
15515
|
+
function assertImportExpression(node, opts) {
|
|
15516
|
+
assert('ImportExpression', node, opts);
|
|
15517
|
+
}
|
|
15518
|
+
|
|
15504
15519
|
function assertImport(node, opts) {
|
|
15505
15520
|
assert('Import', node, opts);
|
|
15506
15521
|
}
|
|
@@ -21232,31 +21247,33 @@ var jsx = (superClass) => class JSXParserMixin extends superClass {
|
|
|
21232
21247
|
}
|
|
21233
21248
|
|
|
21234
21249
|
jsxParseAttribute() {
|
|
21235
|
-
const node = this.startNode();
|
|
21236
|
-
|
|
21237
21250
|
if (this.match(2)) {
|
|
21251
|
+
const node2 = this.startNode();
|
|
21238
21252
|
this.setContext(types.brace);
|
|
21239
21253
|
this.next();
|
|
21240
21254
|
this.expect(17);
|
|
21241
|
-
|
|
21255
|
+
node2.argument = this.parseMaybeAssignAllowIn();
|
|
21242
21256
|
this.setContext(types.j_oTag);
|
|
21243
21257
|
this.state.canStartJSXElement = true;
|
|
21244
21258
|
this.expect(4);
|
|
21245
|
-
return this.finishNode(
|
|
21259
|
+
return this.finishNode(node2, 'JSXSpreadAttribute');
|
|
21246
21260
|
}
|
|
21247
21261
|
|
|
21262
|
+
const node = this.startNode();
|
|
21263
|
+
|
|
21248
21264
|
node.name = this.jsxParseNamespacedName();
|
|
21249
21265
|
node.value = this.eat(25) ? this.jsxParseAttributeValue() : null;
|
|
21250
21266
|
return this.finishNode(node, 'JSXAttribute');
|
|
21251
21267
|
}
|
|
21252
21268
|
|
|
21253
21269
|
jsxParseOpeningElementAt(startLoc) {
|
|
21254
|
-
const node = this.startNodeAt(startLoc);
|
|
21255
|
-
|
|
21256
21270
|
if (this.eat(139)) {
|
|
21257
|
-
|
|
21271
|
+
const node2 = this.startNodeAt(startLoc);
|
|
21272
|
+
return this.finishNode(node2, 'JSXOpeningFragment');
|
|
21258
21273
|
}
|
|
21259
21274
|
|
|
21275
|
+
const node = this.startNodeAt(startLoc);
|
|
21276
|
+
|
|
21260
21277
|
node.name = this.jsxParseElementName();
|
|
21261
21278
|
return this.jsxParseOpeningElementAfterName(node);
|
|
21262
21279
|
}
|
|
@@ -21275,12 +21292,13 @@ var jsx = (superClass) => class JSXParserMixin extends superClass {
|
|
|
21275
21292
|
}
|
|
21276
21293
|
|
|
21277
21294
|
jsxParseClosingElementAt(startLoc) {
|
|
21278
|
-
const node = this.startNodeAt(startLoc);
|
|
21279
|
-
|
|
21280
21295
|
if (this.eat(139)) {
|
|
21281
|
-
|
|
21296
|
+
const node2 = this.startNodeAt(startLoc);
|
|
21297
|
+
return this.finishNode(node2, 'JSXClosingFragment');
|
|
21282
21298
|
}
|
|
21283
21299
|
|
|
21300
|
+
const node = this.startNodeAt(startLoc);
|
|
21301
|
+
|
|
21284
21302
|
node.name = this.jsxParseElementName();
|
|
21285
21303
|
this.expect(139);
|
|
21286
21304
|
return this.finishNode(node, 'JSXClosingElement');
|
|
@@ -21745,7 +21763,7 @@ var CommentsParser = class extends BaseParser {
|
|
|
21745
21763
|
i--;
|
|
21746
21764
|
}
|
|
21747
21765
|
|
|
21748
|
-
const
|
|
21766
|
+
const nodeStart = node.start;
|
|
21749
21767
|
|
|
21750
21768
|
for (; i >= 0; i--) {
|
|
21751
21769
|
const commentWS = commentStack[i];
|
|
@@ -24316,10 +24334,6 @@ var NodeUtils = class extends UtilParser {
|
|
|
24316
24334
|
}
|
|
24317
24335
|
|
|
24318
24336
|
finishNodeAtNode(node, type, endNode) {
|
|
24319
|
-
if (process.env.NODE_ENV !== 'production' && node.end > 0) {
|
|
24320
|
-
throw new Error('Do not call finishNode*() twice on the same node. Instead use resetEndLocation() or change type directly.');
|
|
24321
|
-
}
|
|
24322
|
-
|
|
24323
24337
|
node.type = type;
|
|
24324
24338
|
node.end = endNode.end;
|
|
24325
24339
|
const {optionFlags} = this;
|
package/bundle/metafile-esm.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"inputs":{"../babel-babel/packages/babel-helper-validator-identifier/lib/index.js":{"bytes":13639,"imports":[],"format":"esm"},"../babel-babel/packages/babel-helper-string-parser/lib/index.js":{"bytes":7680,"imports":[],"format":"esm"},"../babel-babel/packages/babel-types/lib/index.js":{"bytes":
|
|
1
|
+
{"inputs":{"../babel-babel/packages/babel-helper-validator-identifier/lib/index.js":{"bytes":13639,"imports":[],"format":"esm"},"../babel-babel/packages/babel-helper-string-parser/lib/index.js":{"bytes":7680,"imports":[],"format":"esm"},"../babel-babel/packages/babel-types/lib/index.js":{"bytes":353741,"imports":[{"path":"../babel-babel/packages/babel-helper-validator-identifier/lib/index.js","kind":"import-statement","original":"@babel/helper-validator-identifier"},{"path":"../babel-babel/packages/babel-helper-string-parser/lib/index.js","kind":"import-statement","original":"@babel/helper-string-parser"}],"format":"esm"},"../babel-babel/packages/babel-parser/lib/index.js":{"bytes":484811,"imports":[],"format":"esm"},"../babel-babel/packages/babel-code-frame/lib/common-BO7XIBW3.js":{"bytes":3594,"imports":[],"format":"esm"},"../babel-babel/node_modules/js-tokens/index.js":{"bytes":12672,"imports":[],"format":"esm"},"../babel-babel/packages/babel-code-frame/lib/index.js":{"bytes":4080,"imports":[{"path":"../babel-babel/packages/babel-code-frame/lib/common-BO7XIBW3.js","kind":"import-statement","original":"./common-BO7XIBW3.js"},{"path":"util","kind":"import-statement","external":true},{"path":"../babel-babel/node_modules/js-tokens/index.js","kind":"import-statement","original":"js-tokens"},{"path":"../babel-babel/packages/babel-helper-validator-identifier/lib/index.js","kind":"import-statement","original":"@babel/helper-validator-identifier"}],"format":"esm"},"../babel-babel/packages/babel-template/lib/index.js":{"bytes":16579,"imports":[{"path":"../babel-babel/packages/babel-types/lib/index.js","kind":"import-statement","original":"@babel/types"},{"path":"../babel-babel/packages/babel-parser/lib/index.js","kind":"import-statement","original":"@babel/parser"},{"path":"../babel-babel/packages/babel-code-frame/lib/index.js","kind":"import-statement","original":"@babel/code-frame"}],"format":"esm"},"../babel-babel/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.mjs":{"bytes":12869,"imports":[],"format":"esm"},"../babel-babel/node_modules/@jridgewell/resolve-uri/dist/resolve-uri.mjs":{"bytes":8609,"imports":[],"format":"esm"},"../babel-babel/node_modules/@jridgewell/trace-mapping/dist/trace-mapping.mjs":{"bytes":15571,"imports":[{"path":"../babel-babel/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.mjs","kind":"import-statement","original":"@jridgewell/sourcemap-codec"},{"path":"../babel-babel/node_modules/@jridgewell/resolve-uri/dist/resolve-uri.mjs","kind":"import-statement","original":"@jridgewell/resolve-uri"}],"format":"esm"},"../babel-babel/node_modules/@jridgewell/gen-mapping/dist/gen-mapping.mjs":{"bytes":7969,"imports":[{"path":"../babel-babel/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.mjs","kind":"import-statement","original":"@jridgewell/sourcemap-codec"},{"path":"../babel-babel/node_modules/@jridgewell/trace-mapping/dist/trace-mapping.mjs","kind":"import-statement","original":"@jridgewell/trace-mapping"}],"format":"esm"},"../babel-babel/node_modules/jsesc/jsesc.js":{"bytes":8104,"imports":[],"format":"cjs"},"../babel-babel/packages/babel-generator/lib/index.js":{"bytes":128371,"imports":[{"path":"../babel-babel/node_modules/@jridgewell/gen-mapping/dist/gen-mapping.mjs","kind":"import-statement","original":"@jridgewell/gen-mapping"},{"path":"../babel-babel/node_modules/@jridgewell/trace-mapping/dist/trace-mapping.mjs","kind":"import-statement","original":"@jridgewell/trace-mapping"},{"path":"../babel-babel/packages/babel-types/lib/index.js","kind":"import-statement","original":"@babel/types"},{"path":"../babel-babel/node_modules/jsesc/jsesc.js","kind":"import-statement","original":"jsesc"}],"format":"esm"},"../babel-babel/node_modules/obug/dist/core.js":{"bytes":3557,"imports":[],"format":"esm"},"../babel-babel/node_modules/obug/dist/node.js":{"bytes":3091,"imports":[{"path":"../babel-babel/node_modules/obug/dist/core.js","kind":"import-statement","original":"./core.js"},{"path":"tty","kind":"import-statement","external":true},{"path":"util","kind":"import-statement","external":true}],"format":"esm"},"../babel-babel/packages/babel-helper-globals/data/builtin-lower.json":{"bytes":203,"imports":[],"format":"esm","with":{"type":"json"}},"../babel-babel/packages/babel-helper-globals/data/builtin-upper.json":{"bytes":718,"imports":[],"format":"esm","with":{"type":"json"}},"../babel-babel/packages/babel-traverse/lib/index.js":{"bytes":152692,"imports":[{"path":"../babel-babel/node_modules/obug/dist/node.js","kind":"import-statement","original":"obug"},{"path":"../babel-babel/packages/babel-code-frame/lib/index.js","kind":"import-statement","original":"@babel/code-frame"},{"path":"../babel-babel/packages/babel-types/lib/index.js","kind":"import-statement","original":"@babel/types"},{"path":"../babel-babel/packages/babel-parser/lib/index.js","kind":"import-statement","original":"@babel/parser"},{"path":"../babel-babel/packages/babel-helper-globals/data/builtin-lower.json","kind":"import-statement","original":"@babel/helper-globals/data/builtin-lower.json","with":{"type":"json"}},{"path":"../babel-babel/packages/babel-helper-globals/data/builtin-upper.json","kind":"import-statement","original":"@babel/helper-globals/data/builtin-upper.json","with":{"type":"json"}},{"path":"../babel-babel/packages/babel-generator/lib/index.js","kind":"import-statement","original":"@babel/generator"},{"path":"../babel-babel/packages/babel-template/lib/index.js","kind":"import-statement","original":"@babel/template"}],"format":"esm"},"lib/index.js":{"bytes":300,"imports":[{"path":"../babel-babel/packages/babel-template/lib/index.js","kind":"import-statement","original":"@babel/template"},{"path":"../babel-babel/packages/babel-generator/lib/index.js","kind":"import-statement","original":"@babel/generator"},{"path":"../babel-babel/packages/babel-types/lib/index.js","kind":"import-statement","original":"@babel/types"},{"path":"../babel-babel/packages/babel-traverse/lib/index.js","kind":"import-statement","original":"@babel/traverse"},{"path":"../babel-babel/packages/babel-parser/lib/index.js","kind":"import-statement","original":"@babel/parser"},{"path":"../babel-babel/packages/babel-code-frame/lib/index.js","kind":"import-statement","original":"@babel/code-frame"}],"format":"esm"}},"outputs":{"bundle/index.js":{"imports":[{"path":"util","kind":"import-statement","external":true},{"path":"tty","kind":"import-statement","external":true},{"path":"util","kind":"import-statement","external":true}],"exports":["codeFrameColumns","generate","getColumn","getLine","parse","parseExpression","template","tokTypes","traverse","types"],"entryPoint":"lib/index.js","inputs":{"../babel-babel/node_modules/jsesc/jsesc.js":{"bytesInOutput":8976},"../babel-babel/packages/babel-types/lib/index.js":{"bytesInOutput":385161},"../babel-babel/packages/babel-helper-validator-identifier/lib/index.js":{"bytesInOutput":13192},"../babel-babel/packages/babel-helper-string-parser/lib/index.js":{"bytesInOutput":7645},"../babel-babel/packages/babel-parser/lib/index.js":{"bytesInOutput":484567},"../babel-babel/packages/babel-code-frame/lib/common-BO7XIBW3.js":{"bytesInOutput":3540},"../babel-babel/packages/babel-code-frame/lib/index.js":{"bytesInOutput":3834},"../babel-babel/node_modules/js-tokens/index.js":{"bytesInOutput":14697},"../babel-babel/packages/babel-template/lib/index.js":{"bytesInOutput":16926},"../babel-babel/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.mjs":{"bytesInOutput":4609},"../babel-babel/node_modules/@jridgewell/resolve-uri/dist/resolve-uri.mjs":{"bytesInOutput":4373},"../babel-babel/node_modules/@jridgewell/trace-mapping/dist/trace-mapping.mjs":{"bytesInOutput":5805},"../babel-babel/node_modules/@jridgewell/gen-mapping/dist/gen-mapping.mjs":{"bytesInOutput":5767},"../babel-babel/packages/babel-generator/lib/index.js":{"bytesInOutput":129135},"lib/index.js":{"bytesInOutput":0},"../babel-babel/node_modules/obug/dist/core.js":{"bytesInOutput":3434},"../babel-babel/node_modules/obug/dist/node.js":{"bytesInOutput":2805},"../babel-babel/packages/babel-helper-globals/data/builtin-lower.json":{"bytesInOutput":232},"../babel-babel/packages/babel-helper-globals/data/builtin-upper.json":{"bytesInOutput":747},"../babel-babel/packages/babel-traverse/lib/index.js":{"bytesInOutput":154505}},"bytes":1252895}}}
|