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

375 lines
8.3 KiB
JSON

{
"type": "Script",
"span": {
"start": 1,
"end": 93,
"ctxt": 0
},
"body": [
{
"type": "VariableDeclaration",
"span": {
"start": 1,
"end": 12,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 5,
"end": 11,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 5,
"end": 6,
"ctxt": 0
},
"value": "a",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 6,
"end": 11,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 8,
"end": 11,
"ctxt": 0
},
"kind": "any"
}
}
},
"init": null,
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 13,
"end": 24,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 17,
"end": 23,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 17,
"end": 18,
"ctxt": 0
},
"value": "b",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 18,
"end": 23,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 20,
"end": 23,
"ctxt": 0
},
"kind": "any"
}
}
},
"init": null,
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 25,
"end": 36,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 29,
"end": 35,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 29,
"end": 30,
"ctxt": 0
},
"value": "c",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 30,
"end": 35,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 32,
"end": 35,
"ctxt": 0
},
"kind": "any"
}
}
},
"init": null,
"definite": false
}
]
},
{
"type": "ExpressionStatement",
"span": {
"start": 37,
"end": 53,
"ctxt": 0
},
"expression": {
"type": "BinaryExpression",
"span": {
"start": 37,
"end": 52,
"ctxt": 0
},
"operator": "**",
"left": {
"type": "NewExpression",
"span": {
"start": 37,
"end": 42,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 41,
"end": 42,
"ctxt": 0
},
"value": "a",
"optional": false
},
"arguments": null,
"typeArguments": null
},
"right": {
"type": "BinaryExpression",
"span": {
"start": 46,
"end": 52,
"ctxt": 0
},
"operator": "**",
"left": {
"type": "Identifier",
"span": {
"start": 46,
"end": 47,
"ctxt": 0
},
"value": "b",
"optional": false
},
"right": {
"type": "Identifier",
"span": {
"start": 51,
"end": 52,
"ctxt": 0
},
"value": "c",
"optional": false
}
}
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 54,
"end": 74,
"ctxt": 0
},
"expression": {
"type": "BinaryExpression",
"span": {
"start": 54,
"end": 73,
"ctxt": 0
},
"operator": "**",
"left": {
"type": "NewExpression",
"span": {
"start": 54,
"end": 59,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 58,
"end": 59,
"ctxt": 0
},
"value": "a",
"optional": false
},
"arguments": null,
"typeArguments": null
},
"right": {
"type": "BinaryExpression",
"span": {
"start": 63,
"end": 73,
"ctxt": 0
},
"operator": "**",
"left": {
"type": "NewExpression",
"span": {
"start": 63,
"end": 68,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 67,
"end": 68,
"ctxt": 0
},
"value": "b",
"optional": false
},
"arguments": null,
"typeArguments": null
},
"right": {
"type": "Identifier",
"span": {
"start": 72,
"end": 73,
"ctxt": 0
},
"value": "c",
"optional": false
}
}
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 75,
"end": 93,
"ctxt": 0
},
"expression": {
"type": "NewExpression",
"span": {
"start": 75,
"end": 92,
"ctxt": 0
},
"callee": {
"type": "ParenthesisExpression",
"span": {
"start": 79,
"end": 92,
"ctxt": 0
},
"expression": {
"type": "BinaryExpression",
"span": {
"start": 80,
"end": 91,
"ctxt": 0
},
"operator": "**",
"left": {
"type": "Identifier",
"span": {
"start": 80,
"end": 81,
"ctxt": 0
},
"value": "a",
"optional": false
},
"right": {
"type": "BinaryExpression",
"span": {
"start": 85,
"end": 91,
"ctxt": 0
},
"operator": "**",
"left": {
"type": "Identifier",
"span": {
"start": 85,
"end": 86,
"ctxt": 0
},
"value": "b",
"optional": false
},
"right": {
"type": "Identifier",
"span": {
"start": 90,
"end": 91,
"ctxt": 0
},
"value": "c",
"optional": false
}
}
}
},
"arguments": null,
"typeArguments": null
}
}
],
"interpreter": null
}