mirror of
https://github.com/swc-project/swc.git
synced 2024-11-28 11:13:43 +03:00
565 lines
12 KiB
JSON
565 lines
12 KiB
JSON
{
|
|
"type": "Module",
|
|
"span": {
|
|
"start": 117,
|
|
"end": 745,
|
|
"ctxt": 0
|
|
},
|
|
"body": [
|
|
{
|
|
"type": "ExportDefaultExpression",
|
|
"span": {
|
|
"start": 117,
|
|
"end": 135,
|
|
"ctxt": 0
|
|
},
|
|
"expression": {
|
|
"type": "NumericLiteral",
|
|
"span": {
|
|
"start": 132,
|
|
"end": 134,
|
|
"ctxt": 0
|
|
},
|
|
"value": 12.0,
|
|
"raw": "12"
|
|
}
|
|
},
|
|
{
|
|
"type": "ExportDefaultDeclaration",
|
|
"span": {
|
|
"start": 161,
|
|
"end": 210,
|
|
"ctxt": 0
|
|
},
|
|
"decl": {
|
|
"type": "FunctionExpression",
|
|
"identifier": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 185,
|
|
"end": 188,
|
|
"ctxt": 0
|
|
},
|
|
"value": "foo",
|
|
"optional": false
|
|
},
|
|
"params": [],
|
|
"decorators": [],
|
|
"span": {
|
|
"start": 176,
|
|
"end": 210,
|
|
"ctxt": 0
|
|
},
|
|
"body": {
|
|
"type": "BlockStatement",
|
|
"span": {
|
|
"start": 191,
|
|
"end": 210,
|
|
"ctxt": 0
|
|
},
|
|
"stmts": [
|
|
{
|
|
"type": "ReturnStatement",
|
|
"span": {
|
|
"start": 197,
|
|
"end": 208,
|
|
"ctxt": 0
|
|
},
|
|
"argument": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 204,
|
|
"end": 207,
|
|
"ctxt": 0
|
|
},
|
|
"value": "foo",
|
|
"optional": false
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"generator": false,
|
|
"async": false,
|
|
"typeParameters": null,
|
|
"returnType": null
|
|
}
|
|
},
|
|
{
|
|
"type": "ExportDeclaration",
|
|
"span": {
|
|
"start": 211,
|
|
"end": 232,
|
|
"ctxt": 0
|
|
},
|
|
"declaration": {
|
|
"type": "VariableDeclaration",
|
|
"span": {
|
|
"start": 218,
|
|
"end": 232,
|
|
"ctxt": 0
|
|
},
|
|
"kind": "const",
|
|
"declare": false,
|
|
"declarations": [
|
|
{
|
|
"type": "VariableDeclarator",
|
|
"span": {
|
|
"start": 224,
|
|
"end": 231,
|
|
"ctxt": 0
|
|
},
|
|
"id": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 224,
|
|
"end": 225,
|
|
"ctxt": 0
|
|
},
|
|
"value": "x",
|
|
"optional": false,
|
|
"typeAnnotation": null
|
|
},
|
|
"init": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 228,
|
|
"end": 231,
|
|
"ctxt": 0
|
|
},
|
|
"value": "foo",
|
|
"optional": false
|
|
},
|
|
"definite": false
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"type": "ExportNamedDeclaration",
|
|
"span": {
|
|
"start": 233,
|
|
"end": 255,
|
|
"ctxt": 0
|
|
},
|
|
"specifiers": [
|
|
{
|
|
"type": "ExportSpecifier",
|
|
"span": {
|
|
"start": 242,
|
|
"end": 252,
|
|
"ctxt": 0
|
|
},
|
|
"orig": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 242,
|
|
"end": 245,
|
|
"ctxt": 0
|
|
},
|
|
"value": "foo",
|
|
"optional": false
|
|
},
|
|
"exported": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 249,
|
|
"end": 252,
|
|
"ctxt": 0
|
|
},
|
|
"value": "bar",
|
|
"optional": false
|
|
},
|
|
"isTypeOnly": false
|
|
}
|
|
],
|
|
"source": null,
|
|
"typeOnly": false,
|
|
"asserts": null
|
|
},
|
|
{
|
|
"type": "ExportDefaultDeclaration",
|
|
"span": {
|
|
"start": 281,
|
|
"end": 343,
|
|
"ctxt": 0
|
|
},
|
|
"decl": {
|
|
"type": "ClassExpression",
|
|
"identifier": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 302,
|
|
"end": 305,
|
|
"ctxt": 0
|
|
},
|
|
"value": "Foo",
|
|
"optional": false
|
|
},
|
|
"span": {
|
|
"start": 296,
|
|
"end": 343,
|
|
"ctxt": 0
|
|
},
|
|
"decorators": [],
|
|
"body": [
|
|
{
|
|
"type": "ClassProperty",
|
|
"span": {
|
|
"start": 312,
|
|
"end": 341,
|
|
"ctxt": 0
|
|
},
|
|
"key": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 312,
|
|
"end": 313,
|
|
"ctxt": 0
|
|
},
|
|
"value": "a",
|
|
"optional": false
|
|
},
|
|
"value": {
|
|
"type": "ParenthesisExpression",
|
|
"span": {
|
|
"start": 334,
|
|
"end": 340,
|
|
"ctxt": 0
|
|
},
|
|
"expression": {
|
|
"type": "NullLiteral",
|
|
"span": {
|
|
"start": 335,
|
|
"end": 339,
|
|
"ctxt": 0
|
|
}
|
|
}
|
|
},
|
|
"typeAnnotation": null,
|
|
"isStatic": false,
|
|
"decorators": [],
|
|
"accessibility": null,
|
|
"isAbstract": false,
|
|
"isOptional": false,
|
|
"isOverride": false,
|
|
"readonly": false,
|
|
"declare": false,
|
|
"definite": false
|
|
}
|
|
],
|
|
"superClass": null,
|
|
"isAbstract": false,
|
|
"typeParams": null,
|
|
"superTypeParams": null,
|
|
"implements": []
|
|
}
|
|
},
|
|
{
|
|
"type": "EmptyStatement",
|
|
"span": {
|
|
"start": 343,
|
|
"end": 344,
|
|
"ctxt": 0
|
|
}
|
|
},
|
|
{
|
|
"type": "ExportDeclaration",
|
|
"span": {
|
|
"start": 345,
|
|
"end": 366,
|
|
"ctxt": 0
|
|
},
|
|
"declaration": {
|
|
"type": "VariableDeclaration",
|
|
"span": {
|
|
"start": 352,
|
|
"end": 366,
|
|
"ctxt": 0
|
|
},
|
|
"kind": "const",
|
|
"declare": false,
|
|
"declarations": [
|
|
{
|
|
"type": "VariableDeclarator",
|
|
"span": {
|
|
"start": 358,
|
|
"end": 365,
|
|
"ctxt": 0
|
|
},
|
|
"id": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 358,
|
|
"end": 359,
|
|
"ctxt": 0
|
|
},
|
|
"value": "X",
|
|
"optional": false,
|
|
"typeAnnotation": null
|
|
},
|
|
"init": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 362,
|
|
"end": 365,
|
|
"ctxt": 0
|
|
},
|
|
"value": "Foo",
|
|
"optional": false
|
|
},
|
|
"definite": false
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"type": "ExportNamedDeclaration",
|
|
"span": {
|
|
"start": 367,
|
|
"end": 389,
|
|
"ctxt": 0
|
|
},
|
|
"specifiers": [
|
|
{
|
|
"type": "ExportSpecifier",
|
|
"span": {
|
|
"start": 376,
|
|
"end": 386,
|
|
"ctxt": 0
|
|
},
|
|
"orig": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 376,
|
|
"end": 379,
|
|
"ctxt": 0
|
|
},
|
|
"value": "Foo",
|
|
"optional": false
|
|
},
|
|
"exported": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 383,
|
|
"end": 386,
|
|
"ctxt": 0
|
|
},
|
|
"value": "Bar",
|
|
"optional": false
|
|
},
|
|
"isTypeOnly": false
|
|
}
|
|
],
|
|
"source": null,
|
|
"typeOnly": false,
|
|
"asserts": null
|
|
},
|
|
{
|
|
"type": "ImportDeclaration",
|
|
"span": {
|
|
"start": 415,
|
|
"end": 442,
|
|
"ctxt": 0
|
|
},
|
|
"specifiers": [
|
|
{
|
|
"type": "ImportDefaultSpecifier",
|
|
"span": {
|
|
"start": 422,
|
|
"end": 425,
|
|
"ctxt": 0
|
|
},
|
|
"local": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 422,
|
|
"end": 425,
|
|
"ctxt": 0
|
|
},
|
|
"value": "Fab",
|
|
"optional": false
|
|
}
|
|
}
|
|
],
|
|
"source": {
|
|
"type": "StringLiteral",
|
|
"span": {
|
|
"start": 431,
|
|
"end": 441,
|
|
"ctxt": 0
|
|
},
|
|
"value": "./index3",
|
|
"raw": "\"./index3\""
|
|
},
|
|
"typeOnly": false,
|
|
"asserts": null
|
|
},
|
|
{
|
|
"type": "ClassDeclaration",
|
|
"identifier": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 449,
|
|
"end": 452,
|
|
"ctxt": 0
|
|
},
|
|
"value": "Bar",
|
|
"optional": false
|
|
},
|
|
"declare": false,
|
|
"span": {
|
|
"start": 443,
|
|
"end": 502,
|
|
"ctxt": 0
|
|
},
|
|
"decorators": [],
|
|
"body": [
|
|
{
|
|
"type": "ClassProperty",
|
|
"span": {
|
|
"start": 471,
|
|
"end": 500,
|
|
"ctxt": 0
|
|
},
|
|
"key": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 471,
|
|
"end": 472,
|
|
"ctxt": 0
|
|
},
|
|
"value": "x",
|
|
"optional": false
|
|
},
|
|
"value": {
|
|
"type": "ParenthesisExpression",
|
|
"span": {
|
|
"start": 493,
|
|
"end": 499,
|
|
"ctxt": 0
|
|
},
|
|
"expression": {
|
|
"type": "NullLiteral",
|
|
"span": {
|
|
"start": 494,
|
|
"end": 498,
|
|
"ctxt": 0
|
|
}
|
|
}
|
|
},
|
|
"typeAnnotation": null,
|
|
"isStatic": false,
|
|
"decorators": [],
|
|
"accessibility": null,
|
|
"isAbstract": false,
|
|
"isOptional": false,
|
|
"isOverride": false,
|
|
"readonly": false,
|
|
"declare": false,
|
|
"definite": false
|
|
}
|
|
],
|
|
"superClass": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 461,
|
|
"end": 464,
|
|
"ctxt": 0
|
|
},
|
|
"value": "Fab",
|
|
"optional": false
|
|
},
|
|
"isAbstract": false,
|
|
"typeParams": null,
|
|
"superTypeParams": null,
|
|
"implements": []
|
|
},
|
|
{
|
|
"type": "ExportDefaultExpression",
|
|
"span": {
|
|
"start": 503,
|
|
"end": 522,
|
|
"ctxt": 0
|
|
},
|
|
"expression": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 518,
|
|
"end": 521,
|
|
"ctxt": 0
|
|
},
|
|
"value": "Bar",
|
|
"optional": false
|
|
}
|
|
},
|
|
{
|
|
"type": "ExportDefaultExpression",
|
|
"span": {
|
|
"start": 583,
|
|
"end": 601,
|
|
"ctxt": 0
|
|
},
|
|
"expression": {
|
|
"type": "NumericLiteral",
|
|
"span": {
|
|
"start": 598,
|
|
"end": 600,
|
|
"ctxt": 0
|
|
},
|
|
"value": 12.0,
|
|
"raw": "12"
|
|
}
|
|
},
|
|
{
|
|
"type": "ExportDefaultDeclaration",
|
|
"span": {
|
|
"start": 711,
|
|
"end": 744,
|
|
"ctxt": 0
|
|
},
|
|
"decl": {
|
|
"type": "FunctionExpression",
|
|
"identifier": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 735,
|
|
"end": 739,
|
|
"ctxt": 0
|
|
},
|
|
"value": "func",
|
|
"optional": false
|
|
},
|
|
"params": [],
|
|
"decorators": [],
|
|
"span": {
|
|
"start": 726,
|
|
"end": 744,
|
|
"ctxt": 0
|
|
},
|
|
"body": {
|
|
"type": "BlockStatement",
|
|
"span": {
|
|
"start": 742,
|
|
"end": 744,
|
|
"ctxt": 0
|
|
},
|
|
"stmts": []
|
|
},
|
|
"generator": false,
|
|
"async": false,
|
|
"typeParameters": null,
|
|
"returnType": null
|
|
}
|
|
},
|
|
{
|
|
"type": "EmptyStatement",
|
|
"span": {
|
|
"start": 744,
|
|
"end": 745,
|
|
"ctxt": 0
|
|
}
|
|
}
|
|
],
|
|
"interpreter": null
|
|
}
|