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

147 lines
3.9 KiB
JSON
Raw Normal View History

{
"type": "Script",
"span": {
"start": 41,
"end": 116,
"ctxt": 0
},
"body": [
{
"type": "ClassDeclaration",
"identifier": {
"type": "Identifier",
"span": {
"start": 47,
"end": 48,
"ctxt": 0
},
"value": "C",
"optional": false
},
"declare": false,
"span": {
"start": 41,
"end": 116,
"ctxt": 0
},
"decorators": [],
"body": [
{
"type": "ClassMethod",
"span": {
"start": 54,
"end": 114,
"ctxt": 0
},
"key": {
"type": "Identifier",
"span": {
"start": 54,
"end": 60,
"ctxt": 0
},
"value": "method",
"optional": false
},
"function": {
"params": [],
"decorators": [],
"span": {
"start": 54,
"end": 114,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 63,
"end": 114,
"ctxt": 0
},
"stmts": [
{
"type": "VariableDeclaration",
"span": {
"start": 71,
"end": 103,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 75,
"end": 102,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 75,
"end": 77,
"ctxt": 0
},
"value": "fn",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "ArrowFunctionExpression",
"span": {
"start": 80,
"end": 102,
"ctxt": 0
},
"params": [],
"body": {
"type": "AwaitExpression",
"span": {
"start": 92,
"end": 102,
"ctxt": 0
},
"argument": {
"type": "ThisExpression",
"span": {
"start": 98,
"end": 102,
"ctxt": 0
}
}
},
"async": true,
"generator": false,
"typeParameters": null,
"returnType": null
},
"definite": false
}
]
}
]
},
"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": []
}
],
"interpreter": null
}