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

128 lines
2.5 KiB
JSON
Raw Normal View History

{
"type": "Script",
"span": {
"start": 0,
"end": 45,
"ctxt": 0
},
"body": [
{
"type": "TsEnumDeclaration",
"span": {
"start": 0,
"end": 45,
"ctxt": 0
},
"declare": false,
"isConst": false,
"id": {
"type": "Identifier",
"span": {
"start": 5,
"end": 6,
"ctxt": 0
},
"value": "E",
"optional": false
},
"members": [
{
"type": "TsEnumMember",
"span": {
"start": 13,
"end": 18,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 13,
"end": 14,
"ctxt": 0
},
"value": "A",
"optional": false
},
"init": {
"type": "NumericLiteral",
"span": {
"start": 17,
"end": 18,
"ctxt": 0
},
"value": 1.0,
"raw": "1"
}
},
{
"type": "TsEnumMember",
"span": {
"start": 24,
"end": 25,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 24,
"end": 25,
"ctxt": 0
},
"value": "B",
"optional": false
},
"init": null
},
{
"type": "TsEnumMember",
"span": {
"start": 31,
"end": 36,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 31,
"end": 32,
"ctxt": 0
},
"value": "C",
"optional": false
},
"init": {
"type": "NumericLiteral",
"span": {
"start": 35,
"end": 36,
"ctxt": 0
},
"value": 2.0,
"raw": "2"
}
},
{
"type": "TsEnumMember",
"span": {
"start": 42,
"end": 43,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 42,
"end": 43,
"ctxt": 0
},
"value": "D",
"optional": false
},
"init": null
}
]
}
],
"interpreter": null
}