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

142 lines
3.1 KiB
JSON

{
"type": "Script",
"span": {
"start": 0,
"end": 50,
"ctxt": 0
},
"body": [
{
"type": "VariableDeclaration",
"span": {
"start": 0,
"end": 16,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 4,
"end": 15,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 4,
"end": 5,
"ctxt": 0
},
"value": "a",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "StringLiteral",
"span": {
"start": 8,
"end": 15,
"ctxt": 0
},
"value": "Hello",
"hasEscape": false,
"kind": {
"type": "normal",
"containsQuote": true
}
},
"definite": false
}
]
},
{
"type": "VariableDeclaration",
"span": {
"start": 17,
"end": 50,
"ctxt": 0
},
"kind": "var",
"declare": false,
"declarations": [
{
"type": "VariableDeclarator",
"span": {
"start": 21,
"end": 49,
"ctxt": 0
},
"id": {
"type": "Identifier",
"span": {
"start": 21,
"end": 22,
"ctxt": 0
},
"value": "b",
"optional": false,
"typeAnnotation": null
},
"init": {
"type": "CallExpression",
"span": {
"start": 25,
"end": 49,
"ctxt": 0
},
"callee": {
"type": "MemberExpression",
"span": {
"start": 25,
"end": 32,
"ctxt": 0
},
"object": {
"type": "Identifier",
"span": {
"start": 25,
"end": 26,
"ctxt": 0
},
"value": "a",
"optional": false
},
"property": {
"type": "Identifier",
"span": {
"start": 27,
"end": 32,
"ctxt": 0
},
"value": "match",
"optional": false
}
},
"arguments": [
{
"spread": null,
"expression": {
"type": "RegExpLiteral",
"span": {
"start": 33,
"end": 48,
"ctxt": 0
},
"pattern": "\\/ver=([^/]+)",
"flags": ""
}
}
],
"typeArguments": null
},
"definite": false
}
]
}
],
"interpreter": null
}