mirror of
https://github.com/swc-project/swc.git
synced 2024-12-23 05:32:09 +03:00
b44da9dbe4
swc_common: - don't emit `loc` for dummy spans swc_ecma_transforms: - prevent hygiene from changing key in object pattern (#369) - fix module tests (iteration order of FxHashSet is changed) swc_ecma_parser: - fix parsing of arrow function (#370)
197 lines
4.0 KiB
JSON
197 lines
4.0 KiB
JSON
{
|
|
"type": "Module",
|
|
"span": {
|
|
"start": 0,
|
|
"end": 41,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 41
|
|
}
|
|
}
|
|
},
|
|
"body": [
|
|
{
|
|
"type": "JSXElement",
|
|
"span": {
|
|
"start": 0,
|
|
"end": 41,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 41
|
|
}
|
|
}
|
|
},
|
|
"opening": {
|
|
"type": "JSXOpeningElement",
|
|
"name": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 1,
|
|
"end": 4,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 1
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 4
|
|
}
|
|
}
|
|
},
|
|
"value": "div",
|
|
"optional": false
|
|
},
|
|
"span": {
|
|
"start": 1,
|
|
"end": 5,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 1
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 5
|
|
}
|
|
}
|
|
},
|
|
"selfClosing": false
|
|
},
|
|
"children": [
|
|
{
|
|
"type": "JSXElement",
|
|
"span": {
|
|
"start": 5,
|
|
"end": 11,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 5
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 11
|
|
}
|
|
}
|
|
},
|
|
"opening": {
|
|
"type": "JSXOpeningElement",
|
|
"name": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 6,
|
|
"end": 8,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 6
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 8
|
|
}
|
|
}
|
|
},
|
|
"value": "br",
|
|
"optional": false
|
|
},
|
|
"span": {
|
|
"start": 6,
|
|
"end": 11,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 6
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 11
|
|
}
|
|
}
|
|
},
|
|
"selfClosing": true
|
|
},
|
|
"children": [],
|
|
"closing": null
|
|
},
|
|
{
|
|
"type": "JSXText",
|
|
"span": {
|
|
"start": 11,
|
|
"end": 35,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 11
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 35
|
|
}
|
|
}
|
|
},
|
|
"value": "7x invalid-js-identifier",
|
|
"raw": "7x invalid-js-identifier"
|
|
}
|
|
],
|
|
"closing": {
|
|
"type": "JSXClosingElement",
|
|
"span": {
|
|
"start": 37,
|
|
"end": 41,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 37
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 41
|
|
}
|
|
}
|
|
},
|
|
"name": {
|
|
"type": "Identifier",
|
|
"span": {
|
|
"start": 37,
|
|
"end": 40,
|
|
"ctxt": 0,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 37
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 40
|
|
}
|
|
}
|
|
},
|
|
"value": "div",
|
|
"optional": false
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|