swc/crates/swc_ecma_parser/tests/tsc/plainJSRedeclare3.json

160 lines
3.4 KiB
JSON
Raw Normal View History

{
"type": "Script",
"span": {
"start": 89,
"end": 154,
"ctxt": 0
},
"body": [
{
"type": "VariableDeclaration",
"span": {
"start": 89,
"end": 106,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 95,
"end": 106,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 95,
"end": 102,
"ctxt": 0
},
"value": "orbitol",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "NumericLiteral",
"span": {
"start": 105,
"end": 106,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 107,
"end": 130,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 111,
"end": 130,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 111,
"end": 118,
"ctxt": 0
},
"value": "orbitol",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "BinaryExpression",
"span": {
"start": 121,
"end": 130,
"ctxt": 0
},
"operator": "+",
"left": {
"type": "NumericLiteral",
"span": {
"start": 121,
"end": 122,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
},
"right": {
"type": "BooleanLiteral",
"span": {
"start": 125,
"end": 130,
"ctxt": 0
},
"value": false
}
},
"definite": false
}
]
},
{
"type": "ExpressionStatement",
"span": {
"start": 131,
"end": 154,
"ctxt": 0
},
"expression": {
"type": "CallExpression",
"span": {
"start": 131,
"end": 154,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 131,
"end": 152,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 131,
"end": 138,
"ctxt": 0
},
"value": "orbitol",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 139,
"end": 152,
"ctxt": 0
},
"value": "toExponential",
"optional": false
}
},
"arguments": [],
"typeArguments": null
}
}
],
"interpreter": null
}