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

240 lines
5.4 KiB
JSON

{
"type": "Script",
"span": {
"start": 16,
"end": 99,
"ctxt": 0
},
"body": [
{
"type": "VariableDeclaration",
"span": {
"start": 16,
"end": 32,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 20,
"end": 31,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 20,
"end": 26,
"ctxt": 0
},
"value": "Symbol",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 26,
"end": 31,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 28,
"end": 31,
"ctxt": 0
},
"kind": "any"
}
}
},
"init": null,
"definite": false
}
]
},
{
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 40,
"end": 41,
"ctxt": 0
},
"value": "C",
"optional": false
},
"declare": false,
"span": {
"start": 34,
"end": 73,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "ClassMethod",
"span": {
"start": 48,
"end": 71,
"ctxt": 0
},
"key": {
"type": "Computed",
"span": {
"start": 48,
"end": 65,
"ctxt": 0
},
"expression": {
"type": "MemberExpression",
"span": {
"start": 49,
"end": 64,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 49,
"end": 55,
"ctxt": 0
},
"value": "Symbol",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 56,
"end": 64,
"ctxt": 0
},
"value": "iterator",
"optional": false
}
}
},
"function": {
"params": [],
"decorators": [],
"span": {
"start": 48,
"end": 71,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 68,
"end": 71,
"ctxt": 0
},
"stmts": []
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
},
"kind": "method",
"isStatic": false,
"accessibility": null,
"isAbstract": false,
"isOptional": false,
"isOverride": false
}
],
"superClass": null,
"isAbstract": false,
"typeParams": null,
"superTypeParams": null,
"implements": []
},
{
"type": "ExpressionStatement",
"span": {
"start": 75,
"end": 99,
"ctxt": 0
},
"expression": {
"type": "MemberExpression",
"span": {
"start": 75,
"end": 99,
"ctxt": 0
},
"object": {
"type": "ParenthesisExpression",
"span": {
"start": 75,
"end": 82,
"ctxt": 0
},
"expression": {
"type": "NewExpression",
"span": {
"start": 76,
"end": 81,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 80,
"end": 81,
"ctxt": 0
},
"value": "C",
"optional": false
},
"arguments": null,
"typeArguments": null
}
},
"property": {
"type": "Computed",
"span": {
"start": 82,
"end": 99,
"ctxt": 0
},
"expression": {
"type": "MemberExpression",
"span": {
"start": 83,
"end": 98,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 83,
"end": 89,
"ctxt": 0
},
"value": "Symbol",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 90,
"end": 98,
"ctxt": 0
},
"value": "iterator",
"optional": false
}
}
}
}
}
],
"interpreter": null
}