swc/crates/swc_ecma_parser/tests/tsc/ES5SymbolProperty2.json
2022-02-04 17:08:38 +09:00

376 lines
10 KiB
JSON

{
"type": "Script",
"span": {
"start": 15,
"end": 167,
"ctxt": 0
},
"body": [
{
"type": "TsModuleDeclaration",
"span": {
"start": 15,
"end": 138,
"ctxt": 0
},
"declare": false,
"global": false,
"id": {
"type": "Identifier",
"span": {
"start": 22,
"end": 23,
"ctxt": 0
},
"value": "M",
"optional": false
},
"body": {
"type": "TsModuleBlock",
"span": {
"start": 24,
"end": 138,
"ctxt": 0
},
"body": [
{
"type": "VariableDeclaration",
"span": {
"start": 30,
"end": 46,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 34,
"end": 45,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 34,
"end": 40,
"ctxt": 0
},
"value": "Symbol",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 40,
"end": 45,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 42,
"end": 45,
"ctxt": 0
},
"kind": "any"
}
}
},
"init": null,
"definite": false
}
]
},
{
"type": "ExportDeclaration",
"span": {
"start": 52,
"end": 106,
"ctxt": 0
},
"declaration": {
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 65,
"end": 66,
"ctxt": 0
},
"value": "C",
"optional": false
},
"declare": false,
"span": {
"start": 59,
"end": 106,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "ClassMethod",
"span": {
"start": 77,
"end": 100,
"ctxt": 0
},
"key": {
"type": "Computed",
"span": {
"start": 77,
"end": 94,
"ctxt": 0
},
"expression": {
"type": "MemberExpression",
"span": {
"start": 78,
"end": 93,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 78,
"end": 84,
"ctxt": 0
},
"value": "Symbol",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 85,
"end": 93,
"ctxt": 0
},
"value": "iterator",
"optional": false
}
}
},
"function": {
"params": [],
"decorators": [],
"span": {
"start": 77,
"end": 100,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 97,
"end": 100,
"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": 111,
"end": 136,
"ctxt": 0
},
"expression": {
"type": "MemberExpression",
"span": {
"start": 111,
"end": 135,
"ctxt": 0
},
"object": {
"type": "ParenthesisExpression",
"span": {
"start": 111,
"end": 118,
"ctxt": 0
},
"expression": {
"type": "NewExpression",
"span": {
"start": 112,
"end": 117,
"ctxt": 0
},
"callee": {
"type": "Identifier",
"span": {
"start": 116,
"end": 117,
"ctxt": 0
},
"value": "C",
"optional": false
},
"arguments": null,
"typeArguments": null
}
},
"property": {
"type": "Computed",
"span": {
"start": 118,
"end": 135,
"ctxt": 0
},
"expression": {
"type": "MemberExpression",
"span": {
"start": 119,
"end": 134,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 119,
"end": 125,
"ctxt": 0
},
"value": "Symbol",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 126,
"end": 134,
"ctxt": 0
},
"value": "iterator",
"optional": false
}
}
}
}
}
]
}
},
{
"type": "ExpressionStatement",
"span": {
"start": 140,
"end": 167,
"ctxt": 0
},
"expression": {
"type": "MemberExpression",
"span": {
"start": 140,
"end": 166,
"ctxt": 0
},
"object": {
"type": "ParenthesisExpression",
"span": {
"start": 140,
"end": 149,
"ctxt": 0
},
"expression": {
"type": "NewExpression",
"span": {
"start": 141,
"end": 148,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 145,
"end": 148,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 145,
"end": 146,
"ctxt": 0
},
"value": "M",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 147,
"end": 148,
"ctxt": 0
},
"value": "C",
"optional": false
}
},
"arguments": null,
"typeArguments": null
}
},
"property": {
"type": "Computed",
"span": {
"start": 149,
"end": 166,
"ctxt": 0
},
"expression": {
"type": "MemberExpression",
"span": {
"start": 150,
"end": 165,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 150,
"end": 156,
"ctxt": 0
},
"value": "Symbol",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 157,
"end": 165,
"ctxt": 0
},
"value": "iterator",
"optional": false
}
}
}
}
}
],
"interpreter": null
}