* [babel 8] Enable ESTree classFeatures by default in @babel/parser * Fix `visitorKeys` * Update tests
107 lines
4.3 KiB
JSON
107 lines
4.3 KiB
JSON
{
|
|
"type": "File",
|
|
"start":0,"end":81,"loc":{"start":{"line":1,"column":0},"end":{"line":8,"column":1}},
|
|
"program": {
|
|
"type": "Program",
|
|
"start":0,"end":81,"loc":{"start":{"line":1,"column":0},"end":{"line":8,"column":1}},
|
|
"sourceType": "script",
|
|
"interpreter": null,
|
|
"body": [
|
|
{
|
|
"type": "ClassDeclaration",
|
|
"start":0,"end":81,"loc":{"start":{"line":1,"column":0},"end":{"line":8,"column":1}},
|
|
"id": {
|
|
"type": "Identifier",
|
|
"start":6,"end":7,"loc":{"start":{"line":1,"column":6},"end":{"line":1,"column":7},"identifierName":"A"},
|
|
"name": "A"
|
|
},
|
|
"superClass": null,
|
|
"body": {
|
|
"type": "ClassBody",
|
|
"start":8,"end":81,"loc":{"start":{"line":1,"column":8},"end":{"line":8,"column":1}},
|
|
"body": [
|
|
{
|
|
"type": "PropertyDefinition",
|
|
"start":12,"end":25,"loc":{"start":{"line":2,"column":2},"end":{"line":2,"column":15}},
|
|
"static": false,
|
|
"key": {
|
|
"type": "PrivateIdentifier",
|
|
"start":12,"end":16,"loc":{"start":{"line":2,"column":2},"end":{"line":2,"column":6}},
|
|
"name": "foo"
|
|
},
|
|
"value": {
|
|
"type": "Literal",
|
|
"start":19,"end":24,"loc":{"start":{"line":2,"column":9},"end":{"line":2,"column":14}},
|
|
"value": "bar",
|
|
"raw": "\"bar\""
|
|
},
|
|
"computed": false
|
|
},
|
|
{
|
|
"type": "PropertyDefinition",
|
|
"start":28,"end":46,"loc":{"start":{"line":3,"column":2},"end":{"line":3,"column":20}},
|
|
"static": true,
|
|
"key": {
|
|
"type": "PrivateIdentifier",
|
|
"start":35,"end":39,"loc":{"start":{"line":3,"column":9},"end":{"line":3,"column":13}},
|
|
"name": "bar"
|
|
},
|
|
"value": {
|
|
"type": "Identifier",
|
|
"start":42,"end":45,"loc":{"start":{"line":3,"column":16},"end":{"line":3,"column":19},"identifierName":"foo"},
|
|
"name": "foo"
|
|
},
|
|
"computed": false
|
|
},
|
|
{
|
|
"type": "MethodDefinition",
|
|
"start":50,"end":79,"loc":{"start":{"line":5,"column":2},"end":{"line":7,"column":3}},
|
|
"static": false,
|
|
"key": {
|
|
"type": "Identifier",
|
|
"start":50,"end":56,"loc":{"start":{"line":5,"column":2},"end":{"line":5,"column":8},"identifierName":"method"},
|
|
"name": "method"
|
|
},
|
|
"computed": false,
|
|
"kind": "method",
|
|
"value": {
|
|
"type": "FunctionExpression",
|
|
"start":56,"end":79,"loc":{"start":{"line":5,"column":8},"end":{"line":7,"column":3}},
|
|
"id": null,
|
|
"generator": false,
|
|
"async": false,
|
|
"expression": false,
|
|
"params": [],
|
|
"body": {
|
|
"type": "BlockStatement",
|
|
"start":59,"end":79,"loc":{"start":{"line":5,"column":11},"end":{"line":7,"column":3}},
|
|
"body": [
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"start":65,"end":75,"loc":{"start":{"line":6,"column":4},"end":{"line":6,"column":14}},
|
|
"expression": {
|
|
"type": "MemberExpression",
|
|
"start":65,"end":74,"loc":{"start":{"line":6,"column":4},"end":{"line":6,"column":13}},
|
|
"object": {
|
|
"type": "ThisExpression",
|
|
"start":65,"end":69,"loc":{"start":{"line":6,"column":4},"end":{"line":6,"column":8}}
|
|
},
|
|
"computed": false,
|
|
"property": {
|
|
"type": "PrivateIdentifier",
|
|
"start":70,"end":74,"loc":{"start":{"line":6,"column":9},"end":{"line":6,"column":13}},
|
|
"name": "foo"
|
|
},
|
|
"optional": false
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
}
|
|
} |