swc/crates/swc_ecma_parser/tests/tsc/moduleExportDuplicateAlias.json
2022-03-22 07:54:08 +00:00

362 lines
7.9 KiB
JSON

{
"type": "Script",
"span": {
"start": 122,
"end": 310,
"ctxt": 0
},
"body": [
{
"type": "ExpressionStatement",
"span": {
"start": 122,
"end": 148,
"ctxt": 0
},
"expression": {
"type": "AssignmentExpression",
"span": {
"start": 122,
"end": 147,
"ctxt": 0
},
"operator": "=",
"left": {
"type": "MemberExpression",
"span": {
"start": 122,
"end": 135,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 122,
"end": 129,
"ctxt": 0
},
"value": "exports",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 130,
"end": 135,
"ctxt": 0
},
"value": "apply",
"optional": false
}
},
"right": {
"type": "Identifier",
"span": {
"start": 138,
"end": 147,
"ctxt": 0
},
"value": "undefined",
"optional": false
}
}
},
{
"type": "FunctionDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 158,
"end": 159,
"ctxt": 0
},
"value": "a",
"optional": false
},
"declare": false,
"params": [],
"decorators": [],
"span": {
"start": 149,
"end": 165,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 162,
"end": 165,
"ctxt": 0
},
"stmts": []
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
},
{
"type": "ExpressionStatement",
"span": {
"start": 166,
"end": 181,
"ctxt": 0
},
"expression": {
"type": "CallExpression",
"span": {
"start": 166,
"end": 181,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 166,
"end": 179,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 166,
"end": 173,
"ctxt": 0
},
"value": "exports",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 174,
"end": 179,
"ctxt": 0
},
"value": "apply",
"optional": false
}
},
"arguments": [],
"typeArguments": null
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 182,
"end": 200,
"ctxt": 0
},
"expression": {
"type": "AssignmentExpression",
"span": {
"start": 182,
"end": 199,
"ctxt": 0
},
"operator": "=",
"left": {
"type": "MemberExpression",
"span": {
"start": 182,
"end": 195,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 182,
"end": 189,
"ctxt": 0
},
"value": "exports",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 190,
"end": 195,
"ctxt": 0
},
"value": "apply",
"optional": false
}
},
"right": {
"type": "Identifier",
"span": {
"start": 198,
"end": 199,
"ctxt": 0
},
"value": "a",
"optional": false
}
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 201,
"end": 216,
"ctxt": 0
},
"expression": {
"type": "CallExpression",
"span": {
"start": 201,
"end": 216,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 201,
"end": 214,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 201,
"end": 208,
"ctxt": 0
},
"value": "exports",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 209,
"end": 214,
"ctxt": 0
},
"value": "apply",
"optional": false
}
},
"arguments": [],
"typeArguments": null
}
},
{
"type": "VariableDeclaration",
"span": {
"start": 240,
"end": 302,
"ctxt": 0
},
"kind": "const",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 246,
"end": 302,
"ctxt": 0
},
"id": {
"type": "ObjectPattern",
"span": {
"start": 246,
"end": 255,
"ctxt": 0
},
"properties": [
{
"type": "AssignmentPatternProperty",
"span": {
"start": 248,
"end": 253,
"ctxt": 0
},
"key": {
"type": "Identifier",
"span": {
"start": 248,
"end": 253,
"ctxt": 0
},
"value": "apply",
"optional": false
},
"value": null
}
],
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "CallExpression",
"span": {
"start": 258,
"end": 302,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 258,
"end": 265,
"ctxt": 0
},
"value": "require",
"optional": false
},
"arguments": [
{
"spread": null,
"expression": {
"type": "StringLiteral",
"span": {
"start": 266,
"end": 301,
"ctxt": 0
},
"value": "./moduleExportAliasDuplicateAlias",
"raw": "'./moduleExportAliasDuplicateAlias'"
}
}
],
"typeArguments": null
},
"definite": false
}
]
},
{
"type": "ExpressionStatement",
"span": {
"start": 303,
"end": 310,
"ctxt": 0
},
"expression": {
"type": "CallExpression",
"span": {
"start": 303,
"end": 310,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 303,
"end": 308,
"ctxt": 0
},
"value": "apply",
"optional": false
},
"arguments": [],
"typeArguments": null
}
}
],
"interpreter": null
}