swc/crates/swc_ecma_parser/tests/tsc/autoAccessor10.json
2023-02-28 06:39:25 +00:00

503 lines
12 KiB
JSON

{
"type": "Script",
"span": {
"start": 21,
"end": 420,
"ctxt": 0
},
"body": [
{
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 27,
"end": 29,
"ctxt": 0
},
"value": "C1",
"optional": false
},
"declare": false,
"span": {
"start": 21,
"end": 54,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "AutoAccessor",
"span": {
"start": 36,
"end": 52,
"ctxt": 0
},
"key": {
"type": "Identifier",
"span": {
"start": 45,
"end": 47,
"ctxt": 0
},
"value": "a0",
"optional": false
},
"value": {
"type": "NumericLiteral",
"span": {
"start": 50,
"end": 51,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
},
"typeAnnotation": null,
"isStatic": false,
"decorators": [],
"accessibility": null
}
],
"superClass": null,
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
},
{
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 62,
"end": 64,
"ctxt": 0
},
"value": "C2",
"optional": false
},
"declare": false,
"span": {
"start": 56,
"end": 119,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "PrivateProperty",
"span": {
"start": 71,
"end": 96,
"ctxt": 0
},
"key": {
"type": "PrivateName",
"span": {
"start": 71,
"end": 91,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 72,
"end": 91,
"ctxt": 0
},
"value": "a1_accessor_storage",
"optional": false
}
},
"value": {
"type": "NumericLiteral",
"span": {
"start": 94,
"end": 95,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
},
"typeAnnotation": null,
"isStatic": false,
"decorators": [],
"accessibility": null,
"isOptional": false,
"isOverride": false,
"readonly": false,
"definite": false
},
{
"type": "AutoAccessor",
"span": {
"start": 101,
"end": 117,
"ctxt": 0
},
"key": {
"type": "Identifier",
"span": {
"start": 110,
"end": 112,
"ctxt": 0
},
"value": "a1",
"optional": false
},
"value": {
"type": "NumericLiteral",
"span": {
"start": 115,
"end": 116,
"ctxt": 0
},
"value": 2.0,
"raw": "2"
},
"typeAnnotation": null,
"isStatic": false,
"decorators": [],
"accessibility": null
}
],
"superClass": null,
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
},
{
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 127,
"end": 129,
"ctxt": 0
},
"value": "C3",
"optional": false
},
"declare": false,
"span": {
"start": 121,
"end": 332,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "PrivateProperty",
"span": {
"start": 136,
"end": 168,
"ctxt": 0
},
"key": {
"type": "PrivateName",
"span": {
"start": 143,
"end": 163,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 144,
"end": 163,
"ctxt": 0
},
"value": "a2_accessor_storage",
"optional": false
}
},
"value": {
"type": "NumericLiteral",
"span": {
"start": 166,
"end": 167,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
},
"typeAnnotation": null,
"isStatic": true,
"decorators": [],
"accessibility": null,
"isOptional": false,
"isOverride": false,
"readonly": false,
"definite": false
},
{
"type": "StaticBlock",
"span": {
"start": 173,
"end": 330,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 180,
"end": 330,
"ctxt": 0
},
"stmts": [
{
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 196,
"end": 204,
"ctxt": 0
},
"value": "C3_Inner",
"optional": false
},
"declare": false,
"span": {
"start": 190,
"end": 324,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "AutoAccessor",
"span": {
"start": 219,
"end": 235,
"ctxt": 0
},
"key": {
"type": "Identifier",
"span": {
"start": 228,
"end": 230,
"ctxt": 0
},
"value": "a2",
"optional": false
},
"value": {
"type": "NumericLiteral",
"span": {
"start": 233,
"end": 234,
"ctxt": 0
},
"value": 2.0,
"raw": "2"
},
"typeAnnotation": null,
"isStatic": false,
"decorators": [],
"accessibility": null
},
{
"type": "StaticBlock",
"span": {
"start": 248,
"end": 314,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 255,
"end": 314,
"ctxt": 0
},
"stmts": [
{
"type": "ExpressionStatement",
"span": {
"start": 273,
"end": 300,
"ctxt": 0
},
"expression": {
"type": "BinaryExpression",
"span": {
"start": 273,
"end": 299,
"ctxt": 0
},
"operator": "in",
"left": {
"type": "PrivateName",
"span": {
"start": 273,
"end": 293,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 274,
"end": 293,
"ctxt": 0
},
"value": "a2_accessor_storage",
"optional": false
}
},
"right": {
"type": "Identifier",
"span": {
"start": 297,
"end": 299,
"ctxt": 0
},
"value": "C3",
"optional": false
}
}
}
]
}
}
],
"superClass": null,
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
}
]
}
}
],
"superClass": null,
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
},
{
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 340,
"end": 344,
"ctxt": 0
},
"value": "C4_1",
"optional": false
},
"declare": false,
"span": {
"start": 334,
"end": 376,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "AutoAccessor",
"span": {
"start": 351,
"end": 374,
"ctxt": 0
},
"key": {
"type": "Identifier",
"span": {
"start": 367,
"end": 369,
"ctxt": 0
},
"value": "a3",
"optional": false
},
"value": {
"type": "NumericLiteral",
"span": {
"start": 372,
"end": 373,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
},
"typeAnnotation": null,
"isStatic": true,
"decorators": [],
"accessibility": null
}
],
"superClass": null,
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
},
{
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 384,
"end": 388,
"ctxt": 0
},
"value": "C4_2",
"optional": false
},
"declare": false,
"span": {
"start": 378,
"end": 420,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "AutoAccessor",
"span": {
"start": 395,
"end": 418,
"ctxt": 0
},
"key": {
"type": "Identifier",
"span": {
"start": 411,
"end": 413,
"ctxt": 0
},
"value": "a3",
"optional": false
},
"value": {
"type": "NumericLiteral",
"span": {
"start": 416,
"end": 417,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
},
"typeAnnotation": null,
"isStatic": true,
"decorators": [],
"accessibility": null
}
],
"superClass": null,
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
}
],
"interpreter": null
}