* Create parser plugin "topLevelAwait" * Update test262 whitelist * Update ts typings * Fix "sourceType: unambiguous" with TLA * Ambiguous tokens after await * Update await %x(0) * typo [skip ci] * Typo [skip ci] Co-Authored-By: Brian Ng <bng412@gmail.com>
476 lines
10 KiB
JSON
476 lines
10 KiB
JSON
{
|
|
"type": "File",
|
|
"start": 0,
|
|
"end": 65,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 8,
|
|
"column": 12
|
|
}
|
|
},
|
|
"program": {
|
|
"type": "Program",
|
|
"start": 0,
|
|
"end": 65,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 8,
|
|
"column": 12
|
|
}
|
|
},
|
|
"sourceType": "script",
|
|
"interpreter": null,
|
|
"body": [
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"start": 0,
|
|
"end": 5,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 5
|
|
}
|
|
},
|
|
"expression": {
|
|
"type": "Identifier",
|
|
"start": 0,
|
|
"end": 5,
|
|
"loc": {
|
|
"start": {
|
|
"line": 1,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 1,
|
|
"column": 5
|
|
},
|
|
"identifierName": "await"
|
|
},
|
|
"name": "await"
|
|
}
|
|
},
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"start": 6,
|
|
"end": 7,
|
|
"loc": {
|
|
"start": {
|
|
"line": 2,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 2,
|
|
"column": 1
|
|
}
|
|
},
|
|
"expression": {
|
|
"type": "NumericLiteral",
|
|
"start": 6,
|
|
"end": 7,
|
|
"loc": {
|
|
"start": {
|
|
"line": 2,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 2,
|
|
"column": 1
|
|
}
|
|
},
|
|
"extra": {
|
|
"rawValue": 0,
|
|
"raw": "0"
|
|
},
|
|
"value": 0
|
|
}
|
|
},
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"start": 9,
|
|
"end": 18,
|
|
"loc": {
|
|
"start": {
|
|
"line": 4,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 4,
|
|
"column": 9
|
|
}
|
|
},
|
|
"expression": {
|
|
"type": "BinaryExpression",
|
|
"start": 9,
|
|
"end": 18,
|
|
"loc": {
|
|
"start": {
|
|
"line": 4,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 4,
|
|
"column": 9
|
|
}
|
|
},
|
|
"left": {
|
|
"type": "Identifier",
|
|
"start": 9,
|
|
"end": 14,
|
|
"loc": {
|
|
"start": {
|
|
"line": 4,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 4,
|
|
"column": 5
|
|
},
|
|
"identifierName": "await"
|
|
},
|
|
"name": "await"
|
|
},
|
|
"operator": "+",
|
|
"right": {
|
|
"type": "NumericLiteral",
|
|
"start": 17,
|
|
"end": 18,
|
|
"loc": {
|
|
"start": {
|
|
"line": 4,
|
|
"column": 8
|
|
},
|
|
"end": {
|
|
"line": 4,
|
|
"column": 9
|
|
}
|
|
},
|
|
"extra": {
|
|
"rawValue": 0,
|
|
"raw": "0"
|
|
},
|
|
"value": 0
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"start": 19,
|
|
"end": 28,
|
|
"loc": {
|
|
"start": {
|
|
"line": 5,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 5,
|
|
"column": 9
|
|
}
|
|
},
|
|
"expression": {
|
|
"type": "BinaryExpression",
|
|
"start": 19,
|
|
"end": 28,
|
|
"loc": {
|
|
"start": {
|
|
"line": 5,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 5,
|
|
"column": 9
|
|
}
|
|
},
|
|
"left": {
|
|
"type": "Identifier",
|
|
"start": 19,
|
|
"end": 24,
|
|
"loc": {
|
|
"start": {
|
|
"line": 5,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 5,
|
|
"column": 5
|
|
},
|
|
"identifierName": "await"
|
|
},
|
|
"name": "await"
|
|
},
|
|
"operator": "-",
|
|
"right": {
|
|
"type": "NumericLiteral",
|
|
"start": 27,
|
|
"end": 28,
|
|
"loc": {
|
|
"start": {
|
|
"line": 5,
|
|
"column": 8
|
|
},
|
|
"end": {
|
|
"line": 5,
|
|
"column": 9
|
|
}
|
|
},
|
|
"extra": {
|
|
"rawValue": 0,
|
|
"raw": "0"
|
|
},
|
|
"value": 0
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"start": 29,
|
|
"end": 40,
|
|
"loc": {
|
|
"start": {
|
|
"line": 6,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 6,
|
|
"column": 11
|
|
}
|
|
},
|
|
"expression": {
|
|
"type": "CallExpression",
|
|
"start": 29,
|
|
"end": 40,
|
|
"loc": {
|
|
"start": {
|
|
"line": 6,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 6,
|
|
"column": 11
|
|
}
|
|
},
|
|
"callee": {
|
|
"type": "Identifier",
|
|
"start": 29,
|
|
"end": 34,
|
|
"loc": {
|
|
"start": {
|
|
"line": 6,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 6,
|
|
"column": 5
|
|
},
|
|
"identifierName": "await"
|
|
},
|
|
"name": "await"
|
|
},
|
|
"arguments": [
|
|
{
|
|
"type": "NumericLiteral",
|
|
"start": 37,
|
|
"end": 38,
|
|
"loc": {
|
|
"start": {
|
|
"line": 6,
|
|
"column": 8
|
|
},
|
|
"end": {
|
|
"line": 6,
|
|
"column": 9
|
|
}
|
|
},
|
|
"extra": {
|
|
"rawValue": 0,
|
|
"raw": "0"
|
|
},
|
|
"value": 0
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"start": 41,
|
|
"end": 52,
|
|
"loc": {
|
|
"start": {
|
|
"line": 7,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 7,
|
|
"column": 11
|
|
}
|
|
},
|
|
"expression": {
|
|
"type": "MemberExpression",
|
|
"start": 41,
|
|
"end": 52,
|
|
"loc": {
|
|
"start": {
|
|
"line": 7,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 7,
|
|
"column": 11
|
|
}
|
|
},
|
|
"object": {
|
|
"type": "Identifier",
|
|
"start": 41,
|
|
"end": 46,
|
|
"loc": {
|
|
"start": {
|
|
"line": 7,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 7,
|
|
"column": 5
|
|
},
|
|
"identifierName": "await"
|
|
},
|
|
"name": "await"
|
|
},
|
|
"property": {
|
|
"type": "NumericLiteral",
|
|
"start": 49,
|
|
"end": 50,
|
|
"loc": {
|
|
"start": {
|
|
"line": 7,
|
|
"column": 8
|
|
},
|
|
"end": {
|
|
"line": 7,
|
|
"column": 9
|
|
}
|
|
},
|
|
"extra": {
|
|
"rawValue": 0,
|
|
"raw": "0"
|
|
},
|
|
"value": 0
|
|
},
|
|
"computed": true
|
|
}
|
|
},
|
|
{
|
|
"type": "ExpressionStatement",
|
|
"start": 53,
|
|
"end": 65,
|
|
"loc": {
|
|
"start": {
|
|
"line": 8,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 8,
|
|
"column": 12
|
|
}
|
|
},
|
|
"expression": {
|
|
"type": "BinaryExpression",
|
|
"start": 53,
|
|
"end": 65,
|
|
"loc": {
|
|
"start": {
|
|
"line": 8,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 8,
|
|
"column": 12
|
|
}
|
|
},
|
|
"left": {
|
|
"type": "BinaryExpression",
|
|
"start": 53,
|
|
"end": 62,
|
|
"loc": {
|
|
"start": {
|
|
"line": 8,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 8,
|
|
"column": 9
|
|
}
|
|
},
|
|
"left": {
|
|
"type": "Identifier",
|
|
"start": 53,
|
|
"end": 58,
|
|
"loc": {
|
|
"start": {
|
|
"line": 8,
|
|
"column": 0
|
|
},
|
|
"end": {
|
|
"line": 8,
|
|
"column": 5
|
|
},
|
|
"identifierName": "await"
|
|
},
|
|
"name": "await"
|
|
},
|
|
"operator": "/",
|
|
"right": {
|
|
"type": "NumericLiteral",
|
|
"start": 61,
|
|
"end": 62,
|
|
"loc": {
|
|
"start": {
|
|
"line": 8,
|
|
"column": 8
|
|
},
|
|
"end": {
|
|
"line": 8,
|
|
"column": 9
|
|
}
|
|
},
|
|
"extra": {
|
|
"rawValue": 0,
|
|
"raw": "0"
|
|
},
|
|
"value": 0
|
|
}
|
|
},
|
|
"operator": "/",
|
|
"right": {
|
|
"type": "Identifier",
|
|
"start": 64,
|
|
"end": 65,
|
|
"loc": {
|
|
"start": {
|
|
"line": 8,
|
|
"column": 11
|
|
},
|
|
"end": {
|
|
"line": 8,
|
|
"column": 12
|
|
},
|
|
"identifierName": "u"
|
|
},
|
|
"name": "u"
|
|
}
|
|
}
|
|
}
|
|
],
|
|
"directives": []
|
|
}
|
|
} |