Huáng Jùnliàng dc7c5640e9
Compact parser fixture loc info (#11322)
* chore: compact loc information in parser fixtures

* chore: update test fixtures
2020-03-23 20:10:29 -04:00

80 lines
3.3 KiB
JSON

{
"type": "File",
"start":0,"end":53,"loc":{"start":{"line":1,"column":0},"end":{"line":5,"column":1}},
"errors": [
"SyntaxError: super can only be used with function calls (i.e. super()) or in property accesses (i.e. super.prop or super[prop]) (3:15)"
],
"program": {
"type": "Program",
"start":0,"end":53,"loc":{"start":{"line":1,"column":0},"end":{"line":5,"column":1}},
"sourceType": "script",
"interpreter": null,
"body": [
{
"type": "VariableDeclaration",
"start":0,"end":53,"loc":{"start":{"line":1,"column":0},"end":{"line":5,"column":1}},
"declarations": [
{
"type": "VariableDeclarator",
"start":6,"end":53,"loc":{"start":{"line":1,"column":6},"end":{"line":5,"column":1}},
"id": {
"type": "Identifier",
"start":6,"end":7,"loc":{"start":{"line":1,"column":6},"end":{"line":1,"column":7},"identifierName":"a"},
"name": "a"
},
"init": {
"type": "ObjectExpression",
"start":10,"end":53,"loc":{"start":{"line":1,"column":10},"end":{"line":5,"column":1}},
"properties": [
{
"type": "ObjectMethod",
"start":16,"end":51,"loc":{"start":{"line":2,"column":4},"end":{"line":4,"column":5}},
"method": true,
"key": {
"type": "Identifier",
"start":16,"end":17,"loc":{"start":{"line":2,"column":4},"end":{"line":2,"column":5},"identifierName":"b"},
"name": "b"
},
"computed": false,
"kind": "method",
"id": null,
"generator": false,
"async": false,
"params": [],
"body": {
"type": "BlockStatement",
"start":19,"end":51,"loc":{"start":{"line":2,"column":7},"end":{"line":4,"column":5}},
"body": [
{
"type": "ReturnStatement",
"start":29,"end":45,"loc":{"start":{"line":3,"column":8},"end":{"line":3,"column":24}},
"argument": {
"type": "OptionalMemberExpression",
"start":36,"end":44,"loc":{"start":{"line":3,"column":15},"end":{"line":3,"column":23}},
"object": {
"type": "Super",
"start":36,"end":41,"loc":{"start":{"line":3,"column":15},"end":{"line":3,"column":20}}
},
"property": {
"type": "Identifier",
"start":43,"end":44,"loc":{"start":{"line":3,"column":22},"end":{"line":3,"column":23},"identifierName":"c"},
"name": "c"
},
"computed": false,
"optional": true
}
}
],
"directives": []
}
}
]
}
}
],
"kind": "const"
}
],
"directives": []
}
}