mirror of
https://github.com/swc-project/swc.git
synced 2024-11-28 02:29:04 +03:00
b887b30092
**Description:** This is required for https://github.com/swc-project/swc/pull/6981 and https://github.com/swc-project/swc/pull/6950
378 lines
7.8 KiB
JSON
378 lines
7.8 KiB
JSON
{
|
|
"type": "Module",
|
|
"span": {
|
|
"start": 20,
|
|
"end": 236,
|
|
"ctxt": 0
|
|
},
|
|
"body": [
|
|
{
|
|
"type": "FunctionDeclaration",
|
|
"identifier": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 29,
|
|
"end": 30,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"declare": false,
|
|
"params": [],
|
|
"decorators": [],
|
|
"span": {
|
|
"start": 20,
|
|
"end": 35,
|
|
"ctxt": 0
|
|
},
|
|
"body": {
|
|
"type": "BlockStatement",
|
|
"span": {
|
|
"start": 33,
|
|
"end": 35,
|
|
"ctxt": 0
|
|
},
|
|
"stmts": []
|
|
},
|
|
"generator": false,
|
|
"async": false,
|
|
"typeParameters": null,
|
|
"returnType": null
|
|
},
|
|
{
|
|
"type": "ExportNamedDeclaration",
|
|
"span": {
|
|
"start": 36,
|
|
"end": 49,
|
|
"ctxt": 0
|
|
},
|
|
"specifiers": [
|
|
{
|
|
"type": "ExportSpecifier",
|
|
"span": {
|
|
"start": 45,
|
|
"end": 46,
|
|
"ctxt": 0
|
|
},
|
|
"orig": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 45,
|
|
"end": 46,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"exported": null,
|
|
"isTypeOnly": false
|
|
}
|
|
],
|
|
"source": null,
|
|
"typeOnly": false,
|
|
"asserts": null
|
|
},
|
|
{
|
|
"type": "ImportDeclaration",
|
|
"span": {
|
|
"start": 70,
|
|
"end": 94,
|
|
"ctxt": 0
|
|
},
|
|
"specifiers": [
|
|
{
|
|
"type": "ImportSpecifier",
|
|
"span": {
|
|
"start": 79,
|
|
"end": 80,
|
|
"ctxt": 0
|
|
},
|
|
"local": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 79,
|
|
"end": 80,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"imported": null,
|
|
"isTypeOnly": false
|
|
}
|
|
],
|
|
"source": {
|
|
"type": "StringLiteral",
|
|
"span": {
|
|
"start": 88,
|
|
"end": 93,
|
|
"ctxt": 0
|
|
},
|
|
"value": "./a",
|
|
"raw": "\"./a\""
|
|
},
|
|
"typeOnly": false,
|
|
"asserts": null
|
|
},
|
|
{
|
|
"type": "TsTypeAliasDeclaration",
|
|
"span": {
|
|
"start": 95,
|
|
"end": 106,
|
|
"ctxt": 0
|
|
},
|
|
"declare": false,
|
|
"id": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 100,
|
|
"end": 101,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"typeParams": null,
|
|
"typeAnnotation": {
|
|
"type": "TsLiteralType",
|
|
"span": {
|
|
"start": 104,
|
|
"end": 105,
|
|
"ctxt": 0
|
|
},
|
|
"literal": {
|
|
"type": "NumericLiteral",
|
|
"span": {
|
|
"start": 104,
|
|
"end": 105,
|
|
"ctxt": 0
|
|
},
|
|
"value": 0.0,
|
|
"raw": "0"
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"type": "ExportNamedDeclaration",
|
|
"span": {
|
|
"start": 107,
|
|
"end": 120,
|
|
"ctxt": 0
|
|
},
|
|
"specifiers": [
|
|
{
|
|
"type": "ExportSpecifier",
|
|
"span": {
|
|
"start": 116,
|
|
"end": 117,
|
|
"ctxt": 0
|
|
},
|
|
"orig": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 116,
|
|
"end": 117,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"exported": null,
|
|
"isTypeOnly": false
|
|
}
|
|
],
|
|
"source": null,
|
|
"typeOnly": false,
|
|
"asserts": null
|
|
},
|
|
{
|
|
"type": "ImportDeclaration",
|
|
"span": {
|
|
"start": 141,
|
|
"end": 165,
|
|
"ctxt": 0
|
|
},
|
|
"specifiers": [
|
|
{
|
|
"type": "ImportSpecifier",
|
|
"span": {
|
|
"start": 150,
|
|
"end": 151,
|
|
"ctxt": 0
|
|
},
|
|
"local": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 150,
|
|
"end": 151,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"imported": null,
|
|
"isTypeOnly": false
|
|
}
|
|
],
|
|
"source": {
|
|
"type": "StringLiteral",
|
|
"span": {
|
|
"start": 159,
|
|
"end": 164,
|
|
"ctxt": 0
|
|
},
|
|
"value": "./b",
|
|
"raw": "\"./b\""
|
|
},
|
|
"typeOnly": false,
|
|
"asserts": null
|
|
},
|
|
{
|
|
"type": "TsModuleDeclaration",
|
|
"span": {
|
|
"start": 166,
|
|
"end": 215,
|
|
"ctxt": 0
|
|
},
|
|
"declare": false,
|
|
"global": false,
|
|
"id": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 176,
|
|
"end": 177,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"body": {
|
|
"type": "TsModuleBlock",
|
|
"span": {
|
|
"start": 178,
|
|
"end": 215,
|
|
"ctxt": 0
|
|
},
|
|
"body": [
|
|
{
|
|
"type": "ExportDeclaration",
|
|
"span": {
|
|
"start": 182,
|
|
"end": 213,
|
|
"ctxt": 0
|
|
},
|
|
"declaration": {
|
|
"type": "VariableDeclaration",
|
|
"span": {
|
|
"start": 189,
|
|
"end": 213,
|
|
"ctxt": 0
|
|
},
|
|
"kind": "const",
|
|
"declare": false,
|
|
"declarations": [
|
|
{
|
|
"type": "VariableDeclarator",
|
|
"span": {
|
|
"start": 195,
|
|
"end": 212,
|
|
"ctxt": 0
|
|
},
|
|
"id": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 195,
|
|
"end": 206,
|
|
"ctxt": 0
|
|
},
|
|
"value": "displayName",
|
|
"optional": false,
|
|
"typeAnnotation": null
|
|
},
|
|
"init": {
|
|
"type": "StringLiteral",
|
|
"span": {
|
|
"start": 209,
|
|
"end": 212,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"raw": "\"A\""
|
|
},
|
|
"definite": false
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"span": {
|
|
"start": 217,
|
|
"end": 221,
|
|
"ctxt": 0
|
|
},
|
|
"expression": {
|
|
"type": "CallExpression",
|
|
"span": {
|
|
"start": 217,
|
|
"end": 220,
|
|
"ctxt": 0
|
|
},
|
|
"callee": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 217,
|
|
"end": 218,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"arguments": [],
|
|
"typeArguments": null
|
|
}
|
|
},
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"span": {
|
|
"start": 222,
|
|
"end": 236,
|
|
"ctxt": 0
|
|
},
|
|
"expression": {
|
|
"type": "MemberExpression",
|
|
"span": {
|
|
"start": 222,
|
|
"end": 235,
|
|
"ctxt": 0
|
|
},
|
|
"object": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 222,
|
|
"end": 223,
|
|
"ctxt": 0
|
|
},
|
|
"value": "A",
|
|
"optional": false
|
|
},
|
|
"property": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 224,
|
|
"end": 235,
|
|
"ctxt": 0
|
|
},
|
|
"value": "displayName",
|
|
"optional": false
|
|
}
|
|
}
|
|
}
|
|
],
|
|
"interpreter": null
|
|
}
|