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

111 lines
2.2 KiB
JSON

{
"type": "Script",
"span": {
"start": 1,
"end": 87,
"ctxt": 0
},
"body": [
{
"type": "IfStatement",
"span": {
"start": 1,
"end": 87,
"ctxt": 0
},
"test": {
"type": "NumericLiteral",
"span": {
"start": 5,
"end": 6,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
},
"consequent": {
"type": "TsEnumDeclaration",
"span": {
"start": 12,
"end": 28,
"ctxt": 0
},
"declare": false,
"isConst": true,
"id": {
"type": "Identifier",
"span": {
"start": 23,
"end": 24,
"ctxt": 0
},
"value": "A",
"optional": false
},
"members": []
},
"alternate": {
"type": "IfStatement",
"span": {
"start": 34,
"end": 87,
"ctxt": 0
},
"test": {
"type": "NumericLiteral",
"span": {
"start": 38,
"end": 39,
"ctxt": 0
},
"value": 2.0,
"raw": "2"
},
"consequent": {
"type": "TsEnumDeclaration",
"span": {
"start": 45,
"end": 61,
"ctxt": 0
},
"declare": false,
"isConst": true,
"id": {
"type": "Identifier",
"span": {
"start": 56,
"end": 57,
"ctxt": 0
},
"value": "B",
"optional": false
},
"members": []
},
"alternate": {
"type": "TsEnumDeclaration",
"span": {
"start": 71,
"end": 87,
"ctxt": 0
},
"declare": false,
"isConst": true,
"id": {
"type": "Identifier",
"span": {
"start": 82,
"end": 83,
"ctxt": 0
},
"value": "C",
"optional": false
},
"members": []
}
}
}
],
"interpreter": null
}