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

215 lines
4.9 KiB
JSON

{
"type": "Module",
"span": {
"start": 38,
"end": 150,
"ctxt": 0
},
"body": [
{
"type": "ExportDefaultDeclaration",
"span": {
"start": 38,
"end": 66,
"ctxt": 0
},
"decl": {
"type": "FunctionExpression",
"identifier": {
"type": "Identifier",
"span": {
"start": 62,
"end": 63,
"ctxt": 0
},
"value": "f",
"optional": false
},
"params": [],
"decorators": [],
"span": {
"start": 53,
"end": 66,
"ctxt": 0
},
"body": null,
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
}
},
{
"type": "ExportDefaultDeclaration",
"span": {
"start": 67,
"end": 104,
"ctxt": 0
},
"decl": {
"type": "FunctionExpression",
"identifier": {
"type": "Identifier",
"span": {
"start": 91,
"end": 92,
"ctxt": 0
},
"value": "f",
"optional": false
},
"params": [
{
"type": "Parameter",
"span": {
"start": 93,
"end": 102,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "Identifier",
"span": {
"start": 93,
"end": 102,
"ctxt": 0
},
"value": "x",
"optional": false,
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 94,
"end": 102,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsKeywordType",
"span": {
"start": 96,
"end": 102,
"ctxt": 0
},
"kind": "string"
}
}
}
}
],
"decorators": [],
"span": {
"start": 82,
"end": 104,
"ctxt": 0
},
"body": null,
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
}
},
{
"type": "ExportDefaultDeclaration",
"span": {
"start": 105,
"end": 150,
"ctxt": 0
},
"decl": {
"type": "FunctionExpression",
"identifier": {
"type": "Identifier",
"span": {
"start": 129,
"end": 130,
"ctxt": 0
},
"value": "f",
"optional": false
},
"params": [
{
"type": "Parameter",
"span": {
"start": 131,
"end": 145,
"ctxt": 0
},
"decorators": [],
"pat": {
"type": "RestElement",
"span": {
"start": 131,
"end": 145,
"ctxt": 0
},
"rest": {
"start": 131,
"end": 134,
"ctxt": 0
},
"argument": {
"type": "Identifier",
"span": {
"start": 134,
"end": 138,
"ctxt": 0
},
"value": "args",
"optional": false,
"typeAnnotation": null
},
"typeAnnotation": {
"type": "TsTypeAnnotation",
"span": {
"start": 138,
"end": 145,
"ctxt": 0
},
"typeAnnotation": {
"type": "TsArrayType",
"span": {
"start": 140,
"end": 145,
"ctxt": 0
},
"elemType": {
"type": "TsKeywordType",
"span": {
"start": 140,
"end": 143,
"ctxt": 0
},
"kind": "any"
}
}
}
}
}
],
"decorators": [],
"span": {
"start": 120,
"end": 150,
"ctxt": 0
},
"body": {
"type": "BlockStatement",
"span": {
"start": 147,
"end": 150,
"ctxt": 0
},
"stmts": []
},
"generator": false,
"async": false,
"typeParameters": null,
"returnType": null
}
}
],
"interpreter": null
}