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

211 lines
4.7 KiB
JSON

{
"type": "Script",
"span": {
"start": 1,
"end": 95,
"ctxt": 0
},
"body": [
{
"type": "TsModuleDeclaration",
"span": {
"start": 1,
"end": 76,
"ctxt": 0
},
"declare": false,
"global": false,
"id": {
"type": "Identifier",
"span": {
"start": 8,
"end": 9,
"ctxt": 0
},
"value": "M",
"optional": false
},
"body": {
"type": "TsModuleBlock",
"span": {
"start": 10,
"end": 76,
"ctxt": 0
},
"body": [
{
"type": "ExportDeclaration",
"span": {
"start": 16,
"end": 42,
"ctxt": 0
},
"declaration": {
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 38,
"end": 39,
"ctxt": 0
},
"value": "A",
"optional": false
},
"declare": false,
"span": {
"start": 23,
"end": 42,
"ctxt": 0
},
"decorators": [],
"body": [],
"superClass": null,
"isAbstract": true,
"typeParams": null,
"superTypeParams": null,
"implements": []
}
},
{
"type": "ExportDeclaration",
"span": {
"start": 47,
"end": 74,
"ctxt": 0
},
"declaration": {
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 60,
"end": 61,
"ctxt": 0
},
"value": "B",
"optional": false
},
"declare": false,
"span": {
"start": 54,
"end": 74,
"ctxt": 0
},
"decorators": [],
"body": [],
"superClass": {
"type": "Identifier",
"span": {
"start": 70,
"end": 71,
"ctxt": 0
},
"value": "A",
"optional": false
},
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
}
}
]
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 78,
"end": 86,
"ctxt": 0
},
"expression": {
"type": "NewExpression",
"span": {
"start": 78,
"end": 85,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 82,
"end": 85,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 82,
"end": 83,
"ctxt": 0
},
"value": "M",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 84,
"end": 85,
"ctxt": 0
},
"value": "A",
"optional": false
}
},
"arguments": null,
"typeArguments": null
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 87,
"end": 95,
"ctxt": 0
},
"expression": {
"type": "NewExpression",
"span": {
"start": 87,
"end": 94,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 91,
"end": 94,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 91,
"end": 92,
"ctxt": 0
},
"value": "M",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 93,
"end": 94,
"ctxt": 0
},
"value": "B",
"optional": false
}
},
"arguments": null,
"typeArguments": null
}
}
],
"interpreter": null
}