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

166 lines
7.3 KiB
JSON

{
"type": "File",
"start":0,"end":70,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":70}},
"program": {
"type": "Program",
"start":0,"end":70,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":70}},
"sourceType": "script",
"interpreter": null,
"body": [
{
"type": "FunctionDeclaration",
"start":0,"end":70,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":70}},
"id": {
"type": "Identifier",
"start":9,"end":31,"loc":{"start":{"line":1,"column":9},"end":{"line":1,"column":31},"identifierName":"multiElementWithObject"},
"name": "multiElementWithObject"
},
"generator": false,
"async": false,
"params": [
{
"type": "RestElement",
"start":32,"end":66,"loc":{"start":{"line":1,"column":32},"end":{"line":1,"column":66}},
"argument": {
"type": "ObjectPattern",
"start":35,"end":66,"loc":{"start":{"line":1,"column":35},"end":{"line":1,"column":66}},
"properties": [
{
"type": "ObjectProperty",
"start":36,"end":45,"loc":{"start":{"line":1,"column":36},"end":{"line":1,"column":45}},
"method": false,
"key": {
"type": "Identifier",
"start":36,"end":37,"loc":{"start":{"line":1,"column":36},"end":{"line":1,"column":37},"identifierName":"a"},
"name": "a"
},
"computed": false,
"shorthand": false,
"value": {
"type": "ObjectPattern",
"start":39,"end":45,"loc":{"start":{"line":1,"column":39},"end":{"line":1,"column":45}},
"properties": [
{
"type": "ObjectProperty",
"start":40,"end":44,"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":44}},
"method": false,
"key": {
"type": "Identifier",
"start":40,"end":41,"loc":{"start":{"line":1,"column":40},"end":{"line":1,"column":41},"identifierName":"p"},
"name": "p"
},
"computed": false,
"shorthand": false,
"value": {
"type": "Identifier",
"start":43,"end":44,"loc":{"start":{"line":1,"column":43},"end":{"line":1,"column":44},"identifierName":"q"},
"name": "q"
}
}
]
}
},
{
"type": "ObjectProperty",
"start":47,"end":53,"loc":{"start":{"line":1,"column":47},"end":{"line":1,"column":53}},
"method": false,
"key": {
"type": "Identifier",
"start":47,"end":48,"loc":{"start":{"line":1,"column":47},"end":{"line":1,"column":48},"identifierName":"b"},
"name": "b"
},
"computed": false,
"shorthand": false,
"value": {
"type": "ObjectPattern",
"start":50,"end":53,"loc":{"start":{"line":1,"column":50},"end":{"line":1,"column":53}},
"properties": [
{
"type": "ObjectProperty",
"start":51,"end":52,"loc":{"start":{"line":1,"column":51},"end":{"line":1,"column":52}},
"method": false,
"key": {
"type": "Identifier",
"start":51,"end":52,"loc":{"start":{"line":1,"column":51},"end":{"line":1,"column":52},"identifierName":"r"},
"name": "r"
},
"computed": false,
"shorthand": true,
"value": {
"type": "Identifier",
"start":51,"end":52,"loc":{"start":{"line":1,"column":51},"end":{"line":1,"column":52},"identifierName":"r"},
"name": "r"
},
"extra": {
"shorthand": true
}
}
]
}
},
{
"type": "ObjectProperty",
"start":55,"end":65,"loc":{"start":{"line":1,"column":55},"end":{"line":1,"column":65}},
"method": false,
"key": {
"type": "Identifier",
"start":55,"end":56,"loc":{"start":{"line":1,"column":55},"end":{"line":1,"column":56},"identifierName":"c"},
"name": "c"
},
"computed": false,
"shorthand": false,
"value": {
"type": "ObjectPattern",
"start":58,"end":65,"loc":{"start":{"line":1,"column":58},"end":{"line":1,"column":65}},
"properties": [
{
"type": "ObjectProperty",
"start":59,"end":64,"loc":{"start":{"line":1,"column":59},"end":{"line":1,"column":64}},
"method": false,
"key": {
"type": "Identifier",
"start":59,"end":60,"loc":{"start":{"line":1,"column":59},"end":{"line":1,"column":60},"identifierName":"s"},
"name": "s"
},
"computed": false,
"shorthand": true,
"value": {
"type": "AssignmentPattern",
"start":59,"end":64,"loc":{"start":{"line":1,"column":59},"end":{"line":1,"column":64}},
"left": {
"type": "Identifier",
"start":59,"end":60,"loc":{"start":{"line":1,"column":59},"end":{"line":1,"column":60},"identifierName":"s"},
"name": "s"
},
"right": {
"type": "NumericLiteral",
"start":63,"end":64,"loc":{"start":{"line":1,"column":63},"end":{"line":1,"column":64}},
"extra": {
"rawValue": 0,
"raw": "0"
},
"value": 0
}
},
"extra": {
"shorthand": true
}
}
]
}
}
]
}
}
],
"body": {
"type": "BlockStatement",
"start":68,"end":70,"loc":{"start":{"line":1,"column":68},"end":{"line":1,"column":70}},
"body": [],
"directives": []
}
}
],
"directives": []
}
}