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

110 lines
2.6 KiB
JSON
Raw Normal View History

{
"type": "Script",
"span": {
"start": 70,
"end": 111,
"ctxt": 0
},
"body": [
{
"type": "VariableDeclaration",
"span": {
"start": 70,
"end": 111,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 74,
"end": 110,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 74,
"end": 77,
"ctxt": 0
},
"value": "foo",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "ArrowFunctionExpression",
"span": {
"start": 80,
"end": 110,
"ctxt": 0
},
"params": [],
"body": {
"type": "BlockStatement",
"span": {
"start": 107,
"end": 110,
"ctxt": 0
},
"stmts": []
},
"async": true,
"generator": false,
"typeParameters": null,
"returnType": {
"type": "TsTypeAnnotation",
"span": {
"start": 88,
"end": 103,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsTypeReference",
"span": {
"start": 90,
"end": 103,
"ctxt": 0
},
"typeName": {
"type": "Identifier",
"span": {
"start": 90,
"end": 97,
"ctxt": 0
},
"value": "Promise",
"optional": false
},
"typeParams": {
"type": "TsTypeParameterInstantiation",
"span": {
"start": 97,
"end": 103,
"ctxt": 0
},
"params": [
{
"type": "TsKeywordType",
"span": {
"start": 98,
"end": 102,
"ctxt": 0
},
"kind": "void"
}
]
}
}
}
},
"definite": false
}
]
}
],
"interpreter": null
}