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

92 lines
3.4 KiB
JSON

{
"type": "File",
"start":0,"end":43,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":43}},
"program": {
"type": "Program",
"start":0,"end":43,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":43}},
"sourceType": "script",
"interpreter": null,
"body": [
{
"type": "VariableDeclaration",
"start":14,"end":43,"loc":{"start":{"line":1,"column":14},"end":{"line":1,"column":43}},
"declarations": [
{
"type": "VariableDeclarator",
"start":18,"end":43,"loc":{"start":{"line":1,"column":18},"end":{"line":1,"column":43}},
"id": {
"type": "Identifier",
"start":18,"end":19,"loc":{"start":{"line":1,"column":18},"end":{"line":1,"column":19},"identifierName":"x"},
"name": "x"
},
"init": {
"type": "ObjectExpression",
"start":22,"end":43,"loc":{"start":{"line":1,"column":22},"end":{"line":1,"column":43}},
"properties": [
{
"type": "ObjectProperty",
"start":24,"end":29,"loc":{"start":{"line":1,"column":24},"end":{"line":1,"column":29}},
"method": false,
"key": {
"type": "Identifier",
"start":24,"end":25,"loc":{"start":{"line":1,"column":24},"end":{"line":1,"column":25},"identifierName":"i"},
"name": "i"
},
"computed": false,
"shorthand": false,
"value": {
"type": "NumericLiteral",
"start":27,"end":29,"loc":{"start":{"line":1,"column":27},"end":{"line":1,"column":29}},
"extra": {
"rawValue": 42,
"raw": "42"
},
"value": 42
}
},
{
"type": "ObjectMethod",
"start":31,"end":41,"loc":{"start":{"line":1,"column":31},"end":{"line":1,"column":41}},
"method": false,
"key": {
"type": "Identifier",
"start":35,"end":36,"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":36},"identifierName":"i"},
"name": "i"
},
"computed": false,
"kind": "get",
"id": null,
"generator": false,
"async": false,
"params": [],
"body": {
"type": "BlockStatement",
"start":39,"end":41,"loc":{"start":{"line":1,"column":39},"end":{"line":1,"column":41}},
"body": [],
"directives": []
}
}
]
}
}
],
"kind": "var"
}
],
"directives": [
{
"type": "Directive",
"start":0,"end":13,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":13}},
"value": {
"type": "DirectiveLiteral",
"start":0,"end":12,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":12}},
"value": "use strict",
"extra": {
"raw": "\"use strict\"",
"rawValue": "use strict"
}
}
}
]
}
}