meriyah 7.3.3 → 7.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +27 -0
- package/dist/meriyah.cjs +130 -72
- package/dist/meriyah.min.mjs +1 -1
- package/dist/meriyah.mjs +130 -72
- package/dist/meriyah.umd.js +130 -72
- package/dist/meriyah.umd.min.js +1 -1
- package/dist/types/common.d.ts +8 -6
- package/dist/types/estree.d.ts +37 -25
- package/dist/types/parser/parser.d.ts +4 -0
- package/package.json +1 -1
package/dist/meriyah.umd.js
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.meriyah = {}));
|
|
5
5
|
})(this, (function (exports) { 'use strict';
|
|
6
6
|
|
|
7
|
-
var version$1 = "7.
|
|
7
|
+
var version$1 = "7.4.1";
|
|
8
8
|
var packageJson = {
|
|
9
9
|
version: version$1};
|
|
10
10
|
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
const result = new Uint32Array(69632);
|
|
13
13
|
let index = 0;
|
|
14
14
|
let subIndex = 0;
|
|
15
|
-
while (index <
|
|
15
|
+
while (index < 2661) {
|
|
16
16
|
const inst = compressed[index++];
|
|
17
17
|
if (inst < 0) {
|
|
18
18
|
subIndex -= inst;
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
32
|
return result;
|
|
33
|
-
})([-1, 2, 26, 2, 27, 2, 5, -1, 0, 77595648, 3, 44, 2, 3, 0, 14, 2, 61, 2, 62, 3, 0, 3, 0, 3168796671, 0, 4294956992, 2, 1, 2, 0, 2, 41, 3, 0, 4, 0, 4294966523, 3, 0, 4, 2, 16, 2, 63, 2, 0, 0, 4294836735, 0, 3221225471, 0, 4294901942, 2, 64, 0, 134152192, 3, 0, 2, 0, 4294951935, 3, 0, 2, 0, 2683305983, 0, 2684354047, 2, 17, 2, 0, 0, 4294961151, 3, 0, 2, 2, 19, 2, 0, 0, 608174079, 2, 0, 2, 58, 2, 7, 2, 6, 0, 4286643967, 3, 0, 2, 2, 1, 3, 0, 3, 0, 4294901711, 2, 40, 0, 4089839103, 0, 2961209759, 0, 1342439375, 0, 4294543342, 0, 3547201023, 0, 1577204103, 0, 4194240, 0, 4294688750, 2, 2, 0, 80831, 0, 4261478351, 0, 4294549486, 2, 2, 0, 2967484831, 0, 196559, 0, 3594373100, 0, 3288319768, 0, 8469959, 0, 65472, 2, 3, 0, 4093640191, 0, 929054175, 0, 65487, 0, 4294828015, 0, 4092591615, 0, 1885355487, 0, 982991, 2, 3, 2, 0, 0, 2163244511, 0, 4227923919, 0, 4236247022, 2, 69, 0, 4284449919, 0, 851904, 2, 4, 2, 12, 0, 67076095, -1, 2, 70, 0, 1073741743, 0, 4093607775, -1, 0, 50331649, 0, 3265266687, 2, 33, 0, 4294844415, 0, 4278190047, 2, 20, 2, 137, -1, 3, 0, 2, 2, 23, 2, 0, 2, 9, 2, 0, 2, 15, 2, 22, 3, 0, 10, 2, 72, 2, 0, 2, 73, 2, 74, 2, 75, 2, 0, 2, 76, 2, 0, 2, 11, 0, 261632, 2, 25, 3, 0, 2, 2, 13, 2, 4, 3, 0, 18, 2, 77, 2, 5, 3, 0, 2, 2, 78, 0, 2151677951, 2, 29, 2, 10, 0, 909311, 3, 0, 2, 0, 814743551, 2, 48, 0, 67090432, 3, 0, 2, 2, 42, 2, 0, 2, 6, 2, 0, 2, 30, 2, 8, 0, 268374015, 2, 108, 2, 51, 2, 0, 2, 79, 0, 134153215, -1, 2, 7, 2, 0, 2, 8, 0, 2684354559, 0, 67044351, 0, 3221160064, 2, 9, 2, 18, 3, 0, 2, 2, 53, 0, 1046528, 3, 0, 3, 2, 10, 2, 0, 2, 127, 0, 4294960127, 2, 9, 2, 6, 2, 11, 0, 4294377472, 2, 12, 3, 0, 16, 2, 13, 2, 0, 2, 80, 2, 9, 2, 0, 2, 81, 2, 82, 2, 83, 0, 12288, 2, 54, 0, 1048577, 2, 84, 2, 14, -1, 2, 14, 0, 131042, 2, 85, 2, 86, 2, 87, 2, 0, 2, 34, -83, 3, 0, 7, 0, 1046559, 2, 0, 2, 15, 2, 0, 0, 2147516671, 2, 21, 3, 88, 2, 2, 0, -16, 2, 89, 0, 524222462, 2, 4, 2, 0, 0, 4269801471, 2, 4, 3, 0, 2, 2, 28, 2, 16, 3, 0, 2, 2, 49, 2, 0, -1, 2, 17, -16, 3, 0, 206, -2, 3, 0, 692, 2, 71, -1, 2, 17, 2, 9, 3, 0, 8, 2, 91, 2, 18, 2, 0, 0, 3220242431, 3, 0, 3, 2, 19, 2, 92, 2, 93, 3, 0, 2, 2, 94, 2, 0, 2, 20, 2, 95, 2, 0, 0, 4351, 2, 0, 2, 10, 3, 0, 2, 0, 67043391, 0, 3909091327, 2, 0, 2, 24, 2, 10, 2, 20, 3, 0, 2, 0, 67076097, 2, 8, 2, 0, 2, 21, 0, 67059711, 0, 4236247039, 3, 0, 2, 0, 939524103, 0, 8191999, 2, 99, 2, 100, 2, 22, 2, 23, 3, 0, 3, 0, 67057663, 3, 0, 349, 2, 101, 2, 102, 2, 7, -264, 3, 0, 11, 2, 24, 3, 0, 2, 2, 32, -1, 0, 3774349439, 2, 103, 2, 104, 3, 0, 2, 2, 19, 2, 105, 3, 0, 10, 2, 9, 2, 17, 2, 0, 2, 46, 2, 0, 2, 31, 2, 106, 2, 25, 0, 1638399, 0, 57344, 2, 107, 3, 0, 3, 2, 20, 2, 26, 2, 27, 2, 5, 2, 28, 2, 0, 2, 8, 2, 109, -1, 2, 110, 2, 111, 2, 112, -1, 3, 0, 3, 2, 12, -2, 2, 0, 2, 29, -3, 0, 536870912, -4, 2, 20, 2, 0, 2, 36, 0, 1, 2, 0, 2, 65, 2, 6, 2, 12, 2, 9, 2, 0, 2, 113, -1, 3, 0, 4, 2, 9, 2, 23, 2, 114, 2, 7, 2, 0, 2, 115, 2, 0, 2, 116, 2, 117, 2, 118, 2, 0, 2, 10, 3, 0, 9, 2, 21, 2, 30, 2, 31, 2, 119, 2, 120, -2, 2, 121, 2, 122, 2, 30, 2, 21, 2, 8, -2, 2, 123, 2, 30, 3, 32, 2, -1, 2, 0, 2, 39, -2, 0, 4277137519, 0, 2269118463, -1, 3, 20, 2, -1, 2, 33, 2, 38, 2, 0, 3, 30, 2, 2, 35, 2, 19, -3, 3, 0, 2, 2, 34, -1, 2, 0, 2, 35, 2, 0, 2, 35, 2, 0, 2, 47, 2, 0, 0, 4294950463, 2, 37, -7, 2, 0, 0, 203775, 2, 125, 0, 4227858432, 2, 20, 2, 43, 2, 36, 2, 17, 2, 37, 2, 17, 2, 124, 2, 21, 3, 0, 2, 2, 38, 0, 2151677888, 2, 0, 2, 12, 0, 4294901764, 2, 145, 2, 0, 2, 56, 2, 55, 0, 5242879, 3, 0, 2, 0, 402644511, -1, 2, 128, 2, 39, 0, 3, -1, 2, 129, 2, 130, 2, 0, 0, 67045375, 2, 40, 0, 4226678271, 0, 3766565279, 0, 2039759, 2, 132, 2, 41, 0, 1046437, 0, 6, 3, 0, 2, 0, 3288270847, 0, 3, 3, 0, 2, 0, 67043519, -5, 2, 0, 0, 4282384383, 0, 1056964609, -1, 3, 0, 2, 0, 67043345, -1, 2, 0, 2, 42, 2, 23, 2, 50, 2, 11, 2, 59, 2, 38, -5, 2, 0, 2, 12, -3, 3, 0, 2, 0, 2147484671, 2, 133, 0, 4190109695, 2, 52, -2, 2, 134, 0, 4244635647, 0, 27, 2, 0, 2, 8, 2, 43, 2, 0, 2, 66, 2, 17, 2, 0, 2, 42, -3, 2, 31, -2, 2, 0, 2, 45, 2, 57, 2, 44, 2, 45, 2, 135, 2, 46, 0, 8388351, -2, 2, 136, 0, 3028287487, 2, 47, 2, 138, 0, 33259519, 2, 23, 2, 7, 2, 48, -7, 2, 21, 0, 4294836223, 0, 3355443199, 0, 134152199, -2, 2, 67, -2, 3, 0, 28, 2, 32, -3, 3, 0, 3, 2, 49, 3, 0, 6, 2, 50, -81, 2, 17, 3, 0, 2, 2, 36, 3, 0, 33, 2, 25, 2, 30, 3, 0, 124, 2, 12, 3, 0, 18, 2, 38, -213, 2, 0, 2, 32, -54, 3, 0, 17, 2, 42, 2, 8, 2, 23, 2, 0, 2, 8, 2, 23, 2, 51, 2, 0, 2, 21, 2, 52, 2, 139, 2, 25, -13, 2, 0, 2, 53, -6, 3, 0, 2, -1, 2, 140, 2, 10, -1, 3, 0, 2, 0, 4294936575, 2, 0, 0, 4294934783, -2, 0, 8323099, 3, 0, 230, 2, 30, 2, 54, 2, 8, -3, 3, 0, 3, 2, 35, -271, 2, 141, 3, 0, 9, 2, 142, 2, 143, 2, 55, 3, 0, 11, 2, 7, -72, 3, 0, 3, 2, 144, 0, 1677656575, -130, 2, 26, -16, 2, 0, 2, 24, 2, 38, -16, 0, 4161266656, 0, 4071, 0, 15360, -4, 0, 28, -13, 3, 0, 2, 2, 56, 2, 0, 2, 146, 2, 147, 2, 60, 2, 0, 2, 148, 2, 149, 2, 150, 3, 0, 10, 2, 151, 2, 152, 2, 22, 3, 56, 2, 3, 153, 2, 3, 57, 2, 0, 4294954999, 2, 0, -16, 2, 0, 2, 90, 2, 0, 0, 2105343, 0, 4160749584, 0, 65534, -34, 2, 8, 2, 155, -6, 0, 4194303871, 0, 4294903771, 2, 0, 2, 58, 2, 98, -3, 2, 0, 0, 1073684479, 0, 17407, -9, 2, 17, 2, 49, 2, 0, 2, 32, -14, 2, 17, 2, 32, -6, 2, 17, 2, 12, -6, 2, 8, 0, 3225419775, -7, 2, 156, 3, 0, 6, 0, 8323103, -1, 3, 0, 2, 2, 59, -37, 2, 60, 2, 157, 2, 158, 2, 159, 2, 160, 2, 161, -105, 2, 26, -32, 3, 0, 1335, -1, 3, 0, 136, 2, 9, 3, 0, 180, 2, 24, 3, 0, 233, 2, 162, 3, 0, 18, 2, 9, -77, 3, 0, 16, 2, 9, -47, 3, 0, 154, 2, 6, 3, 0, 264, 2, 32, -22116, 3, 0, 7, 2, 25, -6130, 3, 5, 2, -1, 0, 69207040, 3, 44, 2, 3, 0, 14, 2, 61, 2, 62, -3, 0, 3168731136, 0, 4294956864, 2, 1, 2, 0, 2, 41, 3, 0, 4, 0, 4294966275, 3, 0, 4, 2, 16, 2, 63, 2, 0, 2, 34, -1, 2, 17, 2, 64, -1, 2, 0, 0, 2047, 0, 4294885376, 3, 0, 2, 0, 3145727, 0, 2617294944, 0, 4294770688, 2, 25, 2, 65, 3, 0, 2, 0, 131135, 2, 96, 0, 70256639, 0, 71303167, 0, 272, 2, 42, 2, 6, 0, 65279, 2, 0, 2, 48, -1, 2, 97, 2, 66, 0, 4278255616, 0, 4294836227, 0, 4294549473, 0, 600178175, 0, 2952806400, 0, 268632067, 0, 4294543328, 0, 57540095, 0, 1577058304, 0, 1835008, 0, 4294688736, 2, 68, 2, 67, 0, 33554435, 2, 131, 2, 68, 0, 2952790016, 0, 131075, 0, 3594373096, 0, 67094296, 2, 67, -1, 0, 4294828000, 0, 603979263, 0, 922746880, 0, 3, 0, 4294828001, 0, 602930687, 0, 1879048192, 0, 393219, 0, 4294828016, 0, 671088639, 0, 2154840064, 0, 4227858435, 0, 4236247008, 2, 69, 2, 38, -1, 2, 4, 0, 917503, 2, 38, -1, 2, 70, 0, 537788335, 0, 4026531935, -1, 0, 1, -1, 2, 33, 2, 71, 0, 7936, -3, 2, 0, 0, 2147485695, 0, 1010761728, 0, 4292984930, 0, 16387, 2, 0, 2, 15, 2, 22, 3, 0, 10, 2, 72, 2, 0, 2, 73, 2, 74, 2, 75, 2, 0, 2, 76, 2, 0, 2, 12, -1, 2, 25, 3, 0, 2, 2, 13, 2, 4, 3, 0, 18, 2, 77, 2, 5, 3, 0, 2, 2, 78, 0, 2147745791, 3, 19, 2, 0, 122879, 2, 0, 2, 10, 0, 276824064, -2, 3, 0, 2, 2, 42, 2, 0, 0, 4294903295, 2, 0, 2, 30, 2, 8, -1, 2, 17, 2, 51, 2, 0, 2, 79, 2, 48, -1, 2, 21, 2, 0, 2, 29, -2, 0, 128, -2, 2, 28, 2, 10, 0, 8160, -1, 2, 126, 0, 4227907585, 2, 0, 2, 37, 2, 0, 2, 50, 0, 4227915776, 2, 9, 2, 6, 2, 11, -1, 0, 74440192, 3, 0, 6, -2, 3, 0, 8, 2, 13, 2, 0, 2, 80, 2, 9, 2, 0, 2, 81, 2, 82, 2, 83, -3, 2, 84, 2, 14, -3, 2, 85, 2, 86, 2, 87, 2, 0, 2, 34, -83, 3, 0, 7, 0, 817183, 2, 0, 2, 15, 2, 0, 0, 33023, 2, 21, 3, 88, 2, -17, 2, 89, 0, 524157950, 2, 4, 2, 0, 2, 90, 2, 4, 2, 0, 2, 22, 2, 28, 2, 16, 3, 0, 2, 2, 49, 2, 0, -1, 2, 17, -16, 3, 0, 206, -2, 3, 0, 692, 2, 71, -1, 2, 17, 2, 9, 3, 0, 8, 2, 91, 0, 3072, 2, 0, 0, 2147516415, 2, 9, 3, 0, 2, 2, 25, 2, 92, 2, 93, 3, 0, 2, 2, 94, 2, 0, 2, 20, 2, 95, 0, 4294965179, 0, 7, 2, 0, 2, 10, 2, 93, 2, 10, -1, 0, 1761345536, 2, 96, 0, 4294901823, 2, 38, 2, 20, 2, 97, 2, 35, 2, 98, 0, 2080440287, 2, 0, 2, 34, 2, 154, 0, 3296722943, 2, 0, 0, 1046675455, 0, 939524101, 0, 1837055, 2, 99, 2, 100, 2, 22, 2, 23, 3, 0, 3, 0, 7, 3, 0, 349, 2, 101, 2, 102, 2, 7, -264, 3, 0, 11, 2, 24, 3, 0, 2, 2, 32, -1, 0, 2700607615, 2, 103, 2, 104, 3, 0, 2, 2, 19, 2, 105, 3, 0, 10, 2, 9, 2, 17, 2, 0, 2, 46, 2, 0, 2, 31, 2, 106, -3, 2, 107, 3, 0, 3, 2, 20, -1, 3, 5, 2, 2, 108, 2, 0, 2, 8, 2, 109, -1, 2, 110, 2, 111, 2, 112, -1, 3, 0, 3, 2, 12, -2, 2, 0, 2, 29, -8, 2, 20, 2, 0, 2, 36, -1, 2, 0, 2, 65, 2, 6, 2, 30, 2, 9, 2, 0, 2, 113, -1, 3, 0, 4, 2, 9, 2, 17, 2, 114, 2, 7, 2, 0, 2, 115, 2, 0, 2, 116, 2, 117, 2, 118, 2, 0, 2, 10, 3, 0, 9, 2, 21, 2, 30, 2, 31, 2, 119, 2, 120, -2, 2, 121, 2, 122, 2, 30, 2, 21, 2, 8, -2, 2, 123, 2, 30, 3, 32, 2, -1, 2, 0, 2, 39, -2, 0, 4277075969, 2, 30, -1, 3, 20, 2, -1, 2, 33, 2, 124, 2, 0, 3, 30, 2, 2, 35, 2, 19, -3, 3, 0, 2, 2, 34, -1, 2, 0, 2, 35, 2, 0, 2, 35, 2, 0, 2, 50, 2, 96, 0, 4294934591, 2, 37, -7, 2, 0, 0, 197631, 2, 125, -1, 2, 20, 2, 43, 2, 37, 2, 17, 0, 3, 2, 17, 2, 124, 2, 21, 2, 126, 2, 127, -1, 0, 2490368, 2, 126, 2, 25, 2, 17, 2, 34, 2, 126, 2, 38, 0, 4294901904, 0, 4718591, 2, 126, 2, 35, 0, 335544350, -1, 2, 128, 0, 2147487743, 0, 1, -1, 2, 129, 2, 130, 2, 8, -1, 2, 131, 2, 68, 0, 3758161920, 0, 3, 2, 132, 0, 12582911, 0, 655360, -1, 2, 0, 2, 29, 0, 2147485568, 0, 3, 2, 0, 2, 25, 0, 176, -5, 2, 0, 2, 49, 0, 251658240, -1, 2, 0, 2, 25, 0, 16, -1, 2, 0, 0, 16779263, -2, 2, 12, -1, 2, 38, -5, 2, 0, 2, 18, -3, 3, 0, 2, 2, 54, 2, 133, 0, 2147549183, 0, 2, -2, 2, 134, 2, 36, 0, 10, 0, 4294965249, 0, 67633151, 0, 4026597376, 2, 0, 0, 536871935, 2, 17, 2, 0, 2, 42, -6, 2, 0, 0, 1, 2, 57, 2, 49, 0, 1, 2, 135, 2, 25, -3, 2, 136, 2, 36, 2, 137, 2, 138, 0, 16778239, 2, 17, 2, 7, -8, 2, 35, 0, 4294836212, 2, 10, -3, 2, 67, -2, 3, 0, 28, 2, 32, -3, 3, 0, 3, 2, 49, 3, 0, 6, 2, 50, -81, 2, 17, 3, 0, 2, 2, 36, 3, 0, 33, 2, 25, 0, 126, 3, 0, 124, 2, 12, 3, 0, 18, 2, 38, -213, 2, 9, -55, 3, 0, 17, 2, 42, 2, 8, 2, 17, 2, 0, 2, 8, 2, 17, 2, 58, 2, 0, 2, 25, 2, 50, 2, 139, 2, 25, -13, 2, 0, 2, 71, -6, 3, 0, 2, -1, 2, 140, 2, 10, -1, 3, 0, 2, 0, 67583, -1, 2, 105, -2, 0, 8126475, 3, 0, 230, 2, 30, 2, 54, 2, 8, -3, 3, 0, 3, 2, 35, -271, 2, 141, 3, 0, 9, 2, 142, 2, 143, 2, 55, 3, 0, 11, 2, 7, -72, 3, 0, 3, 2, 144, 2, 145, -187, 3, 0, 2, 2, 56, 2, 0, 2, 146, 2, 147, 2, 60, 2, 0, 2, 148, 2, 149, 2, 150, 3, 0, 10, 2, 151, 2, 152, 2, 22, 3, 56, 2, 3, 153, 2, 3, 57, 2, 2, 154, -57, 2, 8, 2, 155, -7, 2, 17, 2, 0, 2, 58, -4, 2, 0, 0, 1065361407, 0, 16384, -9, 2, 17, 2, 58, 2, 0, 2, 18, -14, 2, 17, 2, 18, -6, 2, 17, 0, 81919, -6, 2, 8, 0, 3223273399, -7, 2, 156, 3, 0, 6, 2, 124, -1, 3, 0, 2, 0, 2063, -37, 2, 60, 2, 157, 2, 158, 2, 159, 2, 160, 2, 161, -138, 3, 0, 1335, -1, 3, 0, 136, 2, 9, 3, 0, 180, 2, 24, 3, 0, 233, 2, 162, 3, 0, 18, 2, 9, -77, 3, 0, 16, 2, 9, -47, 3, 0, 154, 2, 6, 3, 0, 264, 2, 32, -28252], [4294967295, 4294967291, 4092460543, 4294828031, 4294967294, 134217726, 4294903807, 268435455, 2147483647, 1073741823, 1048575, 3892314111, 134217727, 1061158911, 536805376, 4294910143, 4294901759, 4294901760, 4095, 262143, 536870911, 8388607, 4160749567, 4294902783, 4294918143, 65535, 67043328, 2281701374, 4294967264, 2097151, 4194303, 255, 67108863, 4294967039, 511, 524287, 131071, 63, 127, 3238002687, 4294549487, 4290772991, 33554431, 4294901888, 4286578687, 67043329, 4294770687, 67043583, 1023, 32767, 15, 2047999, 67043343, 67051519, 2147483648, 4294902000, 4292870143, 4294966783, 16383, 67047423, 4294967279, 262083, 20511, 41943039, 493567, 4294959104, 603979775, 65536, 602799615, 805044223, 4294965206, 8191, 1031749119, 4294917631, 2134769663, 4286578493, 4282253311, 4294942719, 33540095, 4294905855, 2868854591, 1608515583, 265232348, 534519807, 2147614720, 1060109444, 4093640016, 17376, 2139062143, 224, 4169138175, 4294909951, 4286578688, 4294967292, 4294965759, 4294836224, 4294966272, 4294967280, 32768, 8289918, 4294934399, 4294901775, 4294965375, 1602223615, 4294967259, 4294443008, 268369920, 4292804608, 4294967232, 486341884, 4294963199, 3087007615, 1073692671, 4128527, 4279238655, 4294902015, 4160684047, 4290246655, 469499899, 4294967231, 134086655, 4294966591, 2445279231, 3670015, 31, 252, 4294967288, 16777215, 4294705151, 3221208447, 4294902271, 4294549472, 4294921215, 4285526655, 4294966527, 4294705152, 4294966143, 64, 4294966719, 3774873592, 4194303999, 1877934080, 262151, 2555904, 536807423, 67043839, 3758096383, 3959414372, 3755993023, 2080374783, 4294835295, 4294967103, 4160749565, 4294934527, 4087, 2016, 2147446655, 184024726, 2862017156, 1593309078, 268434431, 268434414, 4294901761]);
|
|
33
|
+
})([-1, 2, 23, 2, 24, 2, 5, -1, 0, 77595648, 3, 42, 2, 3, 0, 14, 2, 60, 2, 61, 3, 0, 3, 0, 3168796671, 0, 4294956992, 2, 1, 2, 0, 2, 39, 3, 0, 4, 0, 4294966523, 3, 0, 4, 2, 15, 2, 62, 2, 0, 0, 4294842879, 0, 3221225471, 0, 4294902710, 2, 63, 0, 134152192, 3, 0, 2, 0, 4294951935, 3, 0, 2, 0, 2683305983, 0, 2684354047, 2, 16, 2, 0, 0, 4294961151, 3, 0, 2, 2, 17, 2, 0, 0, 608174079, 2, 0, 2, 56, 2, 7, 2, 6, 0, 4286643967, 3, 0, 2, 2, 1, 3, 0, 3, 0, 4294901711, 2, 38, 0, 4089839103, 0, 2961209759, 0, 1342439375, 0, 4294543342, 0, 3547201023, 0, 1577204103, 0, 4194240, 0, 4294688750, 2, 2, 0, 80831, 0, 4261478351, 0, 4294549486, 2, 2, 0, 2969057695, 0, 196559, 0, 3594373100, 0, 3288319768, 0, 8469959, 0, 65472, 2, 3, 0, 4093640191, 0, 929054175, 0, 65487, 0, 4294828015, 0, 4092591615, 0, 1885355487, 0, 982991, 2, 3, 2, 0, 0, 2163244511, 0, 4227923919, 0, 4236247022, 2, 68, 0, 4284449919, 0, 851904, 2, 4, 2, 12, 0, 67076095, -1, 2, 69, 0, 1073741743, 0, 4093607775, -1, 0, 50331649, 0, 3265266687, 2, 32, 0, 4294844415, 0, 4278190047, 2, 18, 2, 139, -1, 3, 0, 2, 2, 28, 2, 0, 2, 10, 2, 0, 2, 14, 2, 20, 3, 0, 10, 2, 71, 2, 0, 2, 72, 2, 73, 2, 74, 2, 0, 2, 75, 2, 0, 2, 11, 0, 261632, 2, 22, 3, 0, 2, 2, 13, 2, 4, 3, 0, 18, 2, 76, 2, 5, 3, 0, 2, 2, 77, 0, 2151677951, 2, 26, 2, 9, 0, 909311, 3, 0, 2, 0, 814743551, 2, 64, 0, 67090432, 3, 0, 2, 2, 40, 2, 0, 2, 6, 2, 0, 2, 29, 2, 8, 0, 268374015, 2, 109, 2, 48, 2, 0, 2, 78, 0, 134153215, -1, 2, 7, 2, 0, 2, 8, 0, 2684354559, 0, 67044351, 0, 3221160064, 2, 0, 2, 27, 3, 0, 2, 2, 50, 0, 1046528, 3, 0, 3, 2, 9, 2, 0, 2, 127, 0, 4294960127, 2, 10, 2, 6, 2, 11, 0, 4294377472, 2, 12, 3, 0, 16, 2, 13, 2, 0, 2, 80, 2, 10, 2, 0, 2, 81, 2, 82, 2, 83, 0, 12288, 2, 51, 0, 1048577, 2, 84, 2, 85, -1, 0, 536805376, 0, 131042, 2, 86, 2, 87, 2, 88, 2, 0, 2, 33, -83, 3, 0, 7, 0, 1046559, 2, 0, 2, 14, 2, 0, 0, 2147516671, 2, 19, 3, 89, 2, 2, 0, -16, 2, 90, 0, 524222462, 2, 4, 2, 0, 0, 4269801471, 2, 4, 3, 0, 2, 2, 25, 2, 15, 3, 0, 2, 2, 57, 2, 0, -1, 2, 16, -16, 3, 0, 206, -2, 3, 0, 692, 2, 70, -1, 2, 16, 2, 10, 3, 0, 8, 2, 92, 2, 133, 2, 0, 0, 3220242431, 3, 0, 3, 2, 17, 2, 93, 2, 94, 3, 0, 2, 2, 95, 2, 0, 2, 10, 2, 96, 2, 0, 0, 4351, 2, 0, 2, 9, 3, 0, 2, 0, 67043391, 0, 3909091327, 2, 0, 2, 21, 2, 9, 2, 18, 3, 0, 2, 0, 67076097, 2, 8, 2, 0, 2, 19, 0, 67059711, 0, 4236247039, 3, 0, 2, 0, 939524103, 0, 8191999, 2, 100, 2, 101, 2, 20, 2, 102, 3, 0, 3, 0, 67057663, 3, 0, 349, 2, 47, 2, 103, 2, 7, -264, 3, 0, 11, 2, 21, 3, 0, 2, 2, 31, -1, 0, 3774349439, 2, 104, 2, 105, 3, 0, 2, 2, 17, 2, 106, 3, 0, 10, 2, 10, 2, 16, 2, 0, 2, 44, 2, 0, 2, 30, 2, 107, 2, 22, 0, 1638399, 0, 57344, 2, 108, 3, 0, 3, 2, 18, 2, 23, 2, 24, 2, 5, 2, 25, 2, 0, 2, 8, 2, 110, -1, 2, 111, 2, 112, 2, 113, -1, 3, 0, 3, 2, 12, -2, 2, 0, 2, 26, -3, 0, 536870912, -4, 2, 18, 2, 0, 2, 27, 0, 1, 2, 0, 2, 55, 2, 6, 2, 12, 2, 10, 2, 0, 2, 114, -1, 3, 0, 4, 2, 10, 2, 28, 2, 115, 2, 7, 2, 0, 2, 116, 2, 0, 2, 117, 2, 118, 2, 119, 2, 0, 2, 9, 3, 0, 9, 2, 19, 2, 29, 2, 30, 2, 120, 2, 46, -2, 2, 121, 2, 122, 2, 29, 2, 19, 2, 8, -2, 2, 123, 2, 29, 3, 31, 2, -1, 2, 0, 2, 37, -2, 0, 4277137519, 0, 2269118463, -1, 3, 18, 2, -1, 2, 32, 2, 36, 2, 0, 3, 29, 2, 2, 34, 2, 17, -3, 3, 0, 2, 2, 33, -1, 2, 0, 2, 34, 2, 0, 2, 34, 2, 0, 2, 45, 2, 0, 0, 4294950463, 2, 35, -7, 2, 0, 0, 203775, 0, 4261476604, 2, 53, 2, 18, 2, 41, 2, 27, 2, 16, 2, 35, 2, 16, 2, 124, 2, 19, 3, 0, 2, 2, 36, 0, 2151677888, 2, 0, 2, 12, 0, 4294901764, 2, 149, 2, 0, 2, 52, 0, 4294902000, 0, 5242879, 3, 0, 2, 0, 402644511, -1, 2, 128, 2, 37, 0, 3, -1, 2, 129, 2, 130, 2, 0, 0, 67045375, 2, 38, 0, 4226678271, 0, 3766565279, 0, 2039759, 2, 132, 2, 39, 0, 1046437, 0, 6, 3, 0, 2, 0, 3288270847, 0, 3, 3, 0, 2, 0, 67043519, -5, 2, 0, 0, 4282384383, 0, 1056964609, -1, 3, 0, 2, 0, 67043345, -1, 2, 0, 2, 40, 2, 28, 2, 79, 2, 11, 2, 58, 2, 36, -5, 2, 0, 2, 12, -3, 3, 0, 2, 0, 2147484671, 2, 134, 0, 4190109695, 2, 49, -2, 2, 135, 0, 4244635647, 0, 27, 2, 0, 2, 8, 2, 41, 2, 0, 2, 65, 2, 16, 2, 0, 2, 40, 2, 136, -2, 2, 30, -2, 2, 0, 2, 43, 2, 54, 2, 42, 2, 43, 2, 137, 2, 44, 0, 8388351, -2, 2, 138, 0, 3028287487, 2, 45, 2, 140, 0, 33259519, 2, 28, 2, 7, 2, 125, -7, 2, 19, 2, 46, 0, 3355443199, 0, 134152199, -2, 2, 66, -2, 3, 0, 28, 2, 31, -3, 3, 0, 3, 2, 141, 3, 0, 6, 2, 47, 3, 0, 9, 2, 36, -71, 2, 16, 3, 0, 2, 2, 27, 3, 0, 33, 2, 22, 2, 29, 3, 0, 124, 2, 12, 3, 0, 18, 2, 36, -213, 2, 0, 2, 31, -54, 3, 0, 17, 2, 40, 2, 8, 2, 28, 2, 0, 2, 8, 2, 28, 2, 48, 2, 0, 2, 19, 2, 49, 2, 142, 2, 22, -13, 2, 0, 2, 50, -6, 3, 0, 2, -1, 2, 143, 2, 9, -1, 3, 0, 2, 0, 4294936575, 2, 0, 0, 4294934783, -2, 0, 8323099, 3, 0, 230, 2, 12, 2, 51, 2, 0, 0, 1, -2, 3, 0, 3, 2, 34, 3, 0, 28, 2, 17, 2, 0, 2, 34, -240, 2, 144, 3, 0, 9, 2, 145, 2, 146, 2, 147, 3, 0, 11, 2, 7, -72, 3, 0, 3, 2, 148, 0, 1677656575, -130, 2, 23, -16, 2, 0, 2, 21, 2, 36, -14, 0, 384, -1, 0, 4161266656, 0, 4071, 0, 15360, -4, 0, 2550595612, -1, 0, 3, -11, 3, 0, 2, 2, 52, 2, 0, 2, 150, 2, 151, 2, 59, 2, 0, 2, 152, 2, 153, 2, 154, 3, 0, 10, 2, 155, 2, 156, 2, 20, 3, 52, 2, 3, 53, 2, 3, 54, 2, 0, 4294954999, 2, 0, -16, 2, 0, 2, 91, 2, 0, 0, 2105343, 0, 4160749584, 0, 65534, -34, 3, 0, 4, 2, 158, -1, 2, 55, 2, 0, 0, 4194303871, 0, 4294903771, 2, 0, 2, 56, 2, 99, -3, 2, 0, 0, 1073684479, 0, 17407, -9, 2, 16, 2, 57, 2, 0, 2, 31, -14, 2, 16, 2, 31, -6, 2, 16, 2, 12, -6, 2, 8, 0, 3225419775, -7, 2, 159, 3, 0, 6, 0, 8323103, -1, 3, 0, 2, 2, 58, -37, 2, 59, 2, 160, 2, 161, 2, 162, 2, 163, 2, 164, -105, 2, 23, -32, 3, 0, 1335, -1, 3, 0, 136, 2, 8, 3, 0, 180, 2, 21, 3, 0, 233, 2, 165, 3, 0, 18, 2, 10, -77, 3, 0, 16, 2, 10, -47, 3, 0, 154, 2, 6, 3, 0, 264, 2, 31, -1244, 3, 0, 354, -20518, 3, 0, 7, 2, 22, -6130, 3, 5, 2, -1, 0, 69207040, 3, 42, 2, 3, 0, 14, 2, 60, 2, 61, -3, 0, 3168731136, 0, 4294956864, 2, 1, 2, 0, 2, 39, 3, 0, 4, 0, 4294966275, 3, 0, 4, 2, 15, 2, 62, 2, 0, 0, 6655, -1, 2, 16, 2, 63, -1, 2, 0, 0, 2047, 0, 4294885376, 3, 0, 2, 0, 3145727, 0, 2617294944, 0, 4294770688, 2, 22, 2, 55, 3, 0, 2, 0, 131135, 2, 97, 0, 70256639, 0, 71303167, 0, 272, 2, 40, 2, 6, 0, 65279, 2, 0, 2, 64, -1, 2, 98, 2, 65, 0, 4278255616, 0, 4294836227, 0, 4294549473, 0, 600178175, 0, 2952806400, 0, 268632067, 0, 4294543328, 0, 57540095, 0, 1577058304, 0, 1835008, 0, 4294688736, 2, 67, 2, 66, 0, 33554435, 2, 131, 2, 67, 0, 2952790016, 0, 131075, 0, 3594373096, 0, 67094296, 2, 66, -1, 0, 4294828000, 0, 603979263, 0, 922746880, 0, 3, 0, 4294828001, 0, 602930687, 0, 1879048192, 0, 393219, 0, 4294828016, 0, 671088639, 0, 2154840064, 0, 4227858435, 0, 4236247008, 2, 68, 2, 36, -1, 2, 4, 0, 917503, 2, 36, -1, 2, 69, 0, 537788335, 0, 4026531935, -1, 0, 1, -1, 2, 32, 2, 70, 0, 7936, -3, 2, 0, 0, 2147485695, 0, 1010761728, 0, 4292984930, 0, 16387, 2, 0, 2, 14, 2, 20, 3, 0, 10, 2, 71, 2, 0, 2, 72, 2, 73, 2, 74, 2, 0, 2, 75, 2, 0, 2, 12, -1, 2, 22, 3, 0, 2, 2, 13, 2, 4, 3, 0, 18, 2, 76, 2, 5, 3, 0, 2, 2, 77, 0, 2147745791, 3, 17, 2, 0, 122879, 2, 0, 2, 9, 0, 276824064, -2, 3, 0, 2, 2, 40, 2, 0, 0, 4294903295, 2, 0, 2, 29, 2, 8, -1, 2, 16, 2, 48, 2, 0, 2, 78, 2, 64, -1, 2, 19, 2, 0, 2, 26, -2, 0, 128, -2, 2, 25, 2, 9, 0, 8160, -1, 2, 126, 0, 4227907585, 2, 0, 2, 35, 2, 0, 2, 79, 0, 4227915776, 2, 10, 2, 6, 2, 11, -1, 0, 74440192, 3, 0, 6, -2, 3, 0, 8, 2, 13, 2, 0, 2, 80, 2, 10, 2, 0, 2, 81, 2, 82, 2, 83, -3, 2, 84, 2, 85, -3, 2, 86, 2, 87, 2, 88, 2, 0, 2, 33, -83, 3, 0, 7, 0, 817183, 2, 0, 2, 14, 2, 0, 0, 33023, 2, 19, 3, 89, 2, -17, 2, 90, 0, 524157950, 2, 4, 2, 0, 2, 91, 2, 4, 2, 0, 2, 20, 2, 25, 2, 15, 3, 0, 2, 2, 57, 2, 0, -1, 2, 16, -16, 3, 0, 206, -2, 3, 0, 692, 2, 70, -1, 2, 16, 2, 10, 3, 0, 8, 2, 92, 0, 3072, 2, 0, 0, 2147516415, 2, 10, 3, 0, 2, 2, 22, 2, 93, 2, 94, 3, 0, 2, 2, 95, 2, 0, 2, 10, 2, 96, 0, 4294965179, 0, 7, 2, 0, 2, 9, 2, 94, 2, 9, -1, 0, 1761345536, 2, 97, 0, 4294901823, 2, 36, 2, 18, 2, 98, 2, 34, 2, 99, 0, 2080440287, 2, 0, 2, 33, 2, 157, 0, 3296722943, 2, 0, 0, 1046675455, 0, 939524101, 0, 1837055, 2, 100, 2, 101, 2, 20, 2, 102, 3, 0, 3, 0, 7, 3, 0, 349, 2, 47, 2, 103, 2, 7, -264, 3, 0, 11, 2, 21, 3, 0, 2, 2, 31, -1, 0, 2700607615, 2, 104, 2, 105, 3, 0, 2, 2, 17, 2, 106, 3, 0, 10, 2, 10, 2, 16, 2, 0, 2, 44, 2, 0, 2, 30, 2, 107, -3, 2, 108, 3, 0, 3, 2, 18, -1, 3, 5, 2, 2, 109, 2, 0, 2, 8, 2, 110, -1, 2, 111, 2, 112, 2, 113, -1, 3, 0, 3, 2, 12, -2, 2, 0, 2, 26, -8, 2, 18, 2, 0, 2, 27, -1, 2, 0, 2, 55, 2, 6, 2, 29, 2, 10, 2, 0, 2, 114, -1, 3, 0, 4, 2, 10, 2, 16, 2, 115, 2, 7, 2, 0, 2, 116, 2, 0, 2, 117, 2, 118, 2, 119, 2, 0, 2, 9, 3, 0, 9, 2, 19, 2, 29, 2, 30, 2, 120, 2, 46, -2, 2, 121, 2, 122, 2, 29, 2, 19, 2, 8, -2, 2, 123, 2, 29, 3, 31, 2, -1, 2, 0, 2, 37, -2, 0, 4277075969, 2, 29, -1, 3, 18, 2, -1, 2, 32, 2, 124, 2, 0, 3, 29, 2, 2, 34, 2, 17, -3, 3, 0, 2, 2, 33, -1, 2, 0, 2, 34, 2, 0, 2, 34, 2, 0, 2, 79, 2, 97, 0, 4294934591, 2, 35, -7, 2, 0, 2, 125, 0, 4261413116, 2, 57, 2, 18, 2, 41, 2, 35, 2, 16, 0, 3, 2, 16, 2, 124, 2, 19, 2, 126, 2, 127, -1, 0, 2490368, 2, 126, 2, 22, 2, 16, 2, 33, 2, 126, 2, 36, 0, 4294901904, 0, 4718591, 2, 126, 2, 34, 0, 335544350, -1, 2, 128, 0, 2147487743, 0, 1, -1, 2, 129, 2, 130, 2, 8, -1, 2, 131, 2, 67, 0, 3758161920, 0, 3, 2, 132, 0, 12582911, 0, 655360, -1, 2, 0, 2, 26, 0, 2147485568, 0, 3, 2, 0, 2, 22, 0, 176, -5, 2, 0, 2, 57, 0, 251658240, -1, 2, 0, 2, 22, 0, 16, -1, 2, 0, 0, 16779263, -2, 2, 12, -1, 2, 36, -5, 2, 0, 2, 133, -3, 3, 0, 2, 2, 51, 2, 134, 0, 2147549183, 0, 2, -2, 2, 135, 2, 27, 0, 10, 0, 4294965249, 0, 67633151, 0, 4026597376, 2, 0, 0, 536871935, 2, 16, 2, 0, 2, 40, 2, 136, -5, 2, 0, 0, 1, 2, 54, 2, 57, 0, 1, 2, 137, 2, 22, -3, 2, 138, 2, 27, 2, 139, 2, 140, 0, 16778239, 2, 16, 2, 7, 0, 131072, -7, 2, 34, 0, 4294836212, 2, 9, -3, 2, 66, -2, 3, 0, 28, 2, 31, -3, 3, 0, 3, 2, 141, 3, 0, 6, 2, 47, 3, 0, 9, 2, 36, -71, 2, 16, 3, 0, 2, 2, 27, 3, 0, 33, 2, 22, 0, 126, 3, 0, 124, 2, 12, 3, 0, 18, 2, 36, -213, 2, 10, -55, 3, 0, 17, 2, 40, 2, 8, 2, 16, 2, 0, 2, 8, 2, 16, 2, 56, 2, 0, 2, 22, 2, 79, 2, 142, 2, 22, -13, 2, 0, 2, 70, -6, 3, 0, 2, -1, 2, 143, 2, 9, -1, 3, 0, 2, 0, 67583, -1, 2, 106, -2, 0, 8126475, 3, 0, 230, 2, 12, 2, 51, 2, 0, 0, 1, -2, 3, 0, 3, 2, 34, 3, 0, 28, 2, 17, 2, 0, 2, 34, -240, 2, 144, 3, 0, 9, 2, 145, 2, 146, 2, 147, 3, 0, 11, 2, 7, -72, 3, 0, 3, 2, 148, 2, 149, -187, 3, 0, 2, 2, 52, 2, 0, 2, 150, 2, 151, 2, 59, 2, 0, 2, 152, 2, 153, 2, 154, 3, 0, 10, 2, 155, 2, 156, 2, 20, 3, 52, 2, 3, 53, 2, 3, 54, 2, 2, 157, -57, 3, 0, 4, 2, 158, -1, 2, 55, 2, 0, -1, 2, 16, 2, 0, 2, 56, -4, 2, 0, 0, 1065361407, 0, 16384, -9, 2, 16, 2, 56, 2, 0, 2, 133, -14, 2, 16, 2, 133, -6, 2, 16, 0, 81919, -6, 2, 8, 0, 3223273399, -7, 2, 159, 3, 0, 6, 2, 124, -1, 3, 0, 2, 0, 2063, -37, 2, 59, 2, 160, 2, 161, 2, 162, 2, 163, 2, 164, -138, 3, 0, 1335, -1, 3, 0, 136, 2, 8, 3, 0, 180, 2, 21, 3, 0, 233, 2, 165, 3, 0, 18, 2, 10, -77, 3, 0, 16, 2, 10, -47, 3, 0, 154, 2, 6, 3, 0, 264, 2, 31, -1244, 3, 0, 354, -26654], [4294967295, 4294967291, 4092460543, 4294828031, 4294967294, 134217726, 4294903807, 268435455, 2147483647, 1048575, 1073741823, 3892314111, 134217727, 1061158911, 4294910143, 4294901759, 4294901760, 262143, 536870911, 8388607, 4160749567, 4294918143, 65535, 67043328, 2281701374, 4294967264, 2097151, 131071, 4294902783, 4194303, 255, 67108863, 4294967039, 511, 524287, 63, 127, 3238002687, 4294549487, 4290772991, 33554431, 4294901888, 4286578687, 67043329, 4294770687, 67043583, 4294836223, 4294901775, 2047999, 67043343, 67051519, 2147483648, 4292870143, 4294934527, 4294966783, 4294959104, 16383, 32767, 67047423, 4294967279, 262083, 20511, 58720255, 493567, 1023, 603979775, 65536, 602799615, 805044223, 4294965206, 8191, 1031749119, 4294917631, 2134769663, 4286578493, 4282253311, 4294942719, 33540095, 4294905855, 15, 2868854591, 1608515583, 265232348, 534519807, 2147614720, 4294934528, 1060109444, 4093640016, 17376, 2139062143, 224, 4169138175, 4294909951, 4286578688, 4294967292, 4294965759, 4294836228, 4294966272, 4294967280, 32768, 8289918, 4294934399, 4294915071, 4294965375, 1602223615, 4294967259, 4294443008, 268369920, 4292804608, 4294967232, 486341884, 4294963199, 3087007615, 1073692671, 4128527, 4279238655, 4294902015, 4160684047, 4290246655, 469499899, 4294967231, 4294966591, 2445279231, 3670015, 31, 197631, 4294967288, 16777215, 4294705151, 3221208447, 4294902271, 4294549472, 4294921215, 4095, 4285526655, 4294966527, 1024, 4294705152, 4294966143, 64, 4294966719, 4292935679, 3774873592, 4194303999, 1877934080, 262655, 2555904, 4294902256, 536807423, 67043839, 3758096383, 3959414372, 3755993023, 2080374783, 4294835295, 4294967167, 4160749565, 4087, 8323075, 2147446655, 184024726, 2862017156, 1593309078, 268434431, 268434414, 4294901761]);
|
|
34
34
|
const isIDContinue = (code) => (unicodeLookup[(code >>> 5) + 0] >>> code & 31 & 1) !== 0;
|
|
35
35
|
const isIDStart = (code) => (unicodeLookup[(code >>> 5) + 34816] >>> code & 31 & 1) !== 0;
|
|
36
36
|
|
|
@@ -754,7 +754,7 @@
|
|
|
754
754
|
[135]: 'Unexpected character after object literal property name',
|
|
755
755
|
[137]: 'Invalid key token',
|
|
756
756
|
[138]: "Label '%0' has already been declared",
|
|
757
|
-
[139]: '
|
|
757
|
+
[139]: "Label '%0' does not denote an iteration statement",
|
|
758
758
|
[140]: "Undefined label '%0'",
|
|
759
759
|
[141]: 'Trailing comma is disallowed inside import(...) arguments',
|
|
760
760
|
[142]: 'Invalid binding in JSON import',
|
|
@@ -1604,7 +1604,7 @@
|
|
|
1604
1604
|
char = advanceChar(parser);
|
|
1605
1605
|
if (char === 13)
|
|
1606
1606
|
hasCarriageReturn = true;
|
|
1607
|
-
if (char > 0x7e) {
|
|
1607
|
+
if (char > 0x7e && char !== 8232 && char !== 8233) {
|
|
1608
1608
|
ret += String.fromCodePoint(char);
|
|
1609
1609
|
}
|
|
1610
1610
|
else {
|
|
@@ -2171,9 +2171,10 @@
|
|
|
2171
2171
|
nextToken(parser, context);
|
|
2172
2172
|
}
|
|
2173
2173
|
function reinterpretToPattern(parser, node) {
|
|
2174
|
+
const rewritten = node;
|
|
2174
2175
|
switch (node.type) {
|
|
2175
2176
|
case 'ArrayExpression': {
|
|
2176
|
-
|
|
2177
|
+
rewritten.type = 'ArrayPattern';
|
|
2177
2178
|
const { elements } = node;
|
|
2178
2179
|
for (let i = 0, n = elements.length; i < n; ++i) {
|
|
2179
2180
|
const element = elements[i];
|
|
@@ -2183,7 +2184,7 @@
|
|
|
2183
2184
|
return;
|
|
2184
2185
|
}
|
|
2185
2186
|
case 'ObjectExpression': {
|
|
2186
|
-
|
|
2187
|
+
rewritten.type = 'ObjectPattern';
|
|
2187
2188
|
const { properties } = node;
|
|
2188
2189
|
for (let i = 0, n = properties.length; i < n; ++i) {
|
|
2189
2190
|
reinterpretToPattern(parser, properties[i]);
|
|
@@ -2191,17 +2192,17 @@
|
|
|
2191
2192
|
return;
|
|
2192
2193
|
}
|
|
2193
2194
|
case 'AssignmentExpression':
|
|
2194
|
-
|
|
2195
|
+
rewritten.type = 'AssignmentPattern';
|
|
2195
2196
|
if (node.operator !== '=')
|
|
2196
2197
|
parser.report(71);
|
|
2197
|
-
delete
|
|
2198
|
+
delete rewritten.operator;
|
|
2198
2199
|
reinterpretToPattern(parser, node.left);
|
|
2199
2200
|
return;
|
|
2200
2201
|
case 'Property':
|
|
2201
2202
|
reinterpretToPattern(parser, node.value);
|
|
2202
2203
|
return;
|
|
2203
2204
|
case 'SpreadElement':
|
|
2204
|
-
|
|
2205
|
+
rewritten.type = 'RestElement';
|
|
2205
2206
|
reinterpretToPattern(parser, node.argument);
|
|
2206
2207
|
}
|
|
2207
2208
|
}
|
|
@@ -2253,7 +2254,7 @@
|
|
|
2253
2254
|
}
|
|
2254
2255
|
}
|
|
2255
2256
|
function isStrictReservedWord(parser, context, t) {
|
|
2256
|
-
if (t === 209006) {
|
|
2257
|
+
if ((t & 255) === (209006 & 255)) {
|
|
2257
2258
|
if (context & (2048 | 2))
|
|
2258
2259
|
parser.report(112);
|
|
2259
2260
|
if ((parser.destructible & 128) === 0) {
|
|
@@ -2268,36 +2269,36 @@
|
|
|
2268
2269
|
t == -2147483526);
|
|
2269
2270
|
}
|
|
2270
2271
|
function isPropertyWithPrivateFieldKey(expr) {
|
|
2271
|
-
return
|
|
2272
|
+
return expr.type === 'MemberExpression' && expr.property.type === 'PrivateIdentifier';
|
|
2272
2273
|
}
|
|
2273
2274
|
function isValidLabel(parser, labels, name, isIterationStatement) {
|
|
2275
|
+
let isIterationLabelSet = 0;
|
|
2274
2276
|
while (labels) {
|
|
2275
|
-
if (labels
|
|
2276
|
-
if (isIterationStatement)
|
|
2277
|
-
parser.report(139);
|
|
2277
|
+
if (labels.names?.has(name)) {
|
|
2278
|
+
if (isIterationStatement && !isIterationLabelSet)
|
|
2279
|
+
parser.report(139, name);
|
|
2278
2280
|
return 1;
|
|
2279
2281
|
}
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
labels = labels['$'];
|
|
2282
|
+
isIterationLabelSet = labels.loop ? 1 : 0;
|
|
2283
|
+
labels = labels.parent;
|
|
2283
2284
|
}
|
|
2284
2285
|
return 0;
|
|
2285
2286
|
}
|
|
2286
2287
|
function validateAndDeclareLabel(parser, labels, name) {
|
|
2287
2288
|
let set = labels;
|
|
2288
2289
|
while (set) {
|
|
2289
|
-
if (set
|
|
2290
|
+
if (set.names?.has(name))
|
|
2290
2291
|
parser.report(138, name);
|
|
2291
|
-
set = set
|
|
2292
|
+
set = set.parent;
|
|
2292
2293
|
}
|
|
2293
|
-
labels
|
|
2294
|
+
(labels.names ??= new Set()).add(name);
|
|
2294
2295
|
}
|
|
2295
2296
|
function isEqualTagName(elementName) {
|
|
2296
2297
|
switch (elementName.type) {
|
|
2297
2298
|
case 'JSXIdentifier':
|
|
2298
2299
|
return elementName.name;
|
|
2299
2300
|
case 'JSXNamespacedName':
|
|
2300
|
-
return elementName.namespace + ':' + elementName.name;
|
|
2301
|
+
return isEqualTagName(elementName.namespace) + ':' + elementName.name.name;
|
|
2301
2302
|
case 'JSXMemberExpression':
|
|
2302
2303
|
return isEqualTagName(elementName.object) + '.' + isEqualTagName(elementName.property);
|
|
2303
2304
|
}
|
|
@@ -2318,6 +2319,9 @@
|
|
|
2318
2319
|
parser.report(121);
|
|
2319
2320
|
parser.flags |= 512;
|
|
2320
2321
|
}
|
|
2322
|
+
if (context & 1 && (t & 255) === (241737 & 255)) {
|
|
2323
|
+
parser.report(99);
|
|
2324
|
+
}
|
|
2321
2325
|
if (!isValidIdentifier(context, t))
|
|
2322
2326
|
parser.report(0);
|
|
2323
2327
|
}
|
|
@@ -2912,6 +2916,7 @@
|
|
|
2912
2916
|
destructible = 0;
|
|
2913
2917
|
strictReservedRange = null;
|
|
2914
2918
|
firstAwaitLocation = null;
|
|
2919
|
+
firstYieldLocation = null;
|
|
2915
2920
|
leadingDecorators = { decorators: [] };
|
|
2916
2921
|
constructor(source, rawOptions = {}) {
|
|
2917
2922
|
this.source = source;
|
|
@@ -3293,7 +3298,7 @@
|
|
|
3293
3298
|
const body = [];
|
|
3294
3299
|
consume(parser, context | 32, 2162700);
|
|
3295
3300
|
while (parser.getToken() !== 1074790415) {
|
|
3296
|
-
body.push(parseStatementListItem(parser, context, scope, privateScope, {
|
|
3301
|
+
body.push(parseStatementListItem(parser, context, scope, privateScope, { parent: labels }));
|
|
3297
3302
|
}
|
|
3298
3303
|
consume(parser, context | 32, 1074790415);
|
|
3299
3304
|
return parser.finishNode({
|
|
@@ -3446,7 +3451,7 @@
|
|
|
3446
3451
|
return context & 1 ||
|
|
3447
3452
|
!parser.options.webcompat ||
|
|
3448
3453
|
parser.getToken() !== 86104
|
|
3449
|
-
? parseStatement(parser, context, scope, privateScope, {
|
|
3454
|
+
? parseStatement(parser, context, scope, privateScope, { parent: labels }, 0)
|
|
3450
3455
|
: parseFunctionDeclaration(parser, context, scope?.createChildScope(), privateScope, 0, 0, 0, tokenStart);
|
|
3451
3456
|
}
|
|
3452
3457
|
function parseSwitchStatement(parser, context, scope, privateScope, labels) {
|
|
@@ -3477,7 +3482,7 @@
|
|
|
3477
3482
|
parser.getToken() !== 1074790415 &&
|
|
3478
3483
|
parser.getToken() !== 20561) {
|
|
3479
3484
|
const statement = parseStatementListItem(parser, context | 4, scope, privateScope, {
|
|
3480
|
-
|
|
3485
|
+
parent: labels,
|
|
3481
3486
|
});
|
|
3482
3487
|
if (statement.type === 'VariableDeclaration' &&
|
|
3483
3488
|
(statement.kind === 'using' || statement.kind === 'await using')) {
|
|
@@ -3512,7 +3517,7 @@
|
|
|
3512
3517
|
}, start);
|
|
3513
3518
|
}
|
|
3514
3519
|
function parseIterationStatementBody(parser, context, scope, privateScope, labels) {
|
|
3515
|
-
return parseStatement(parser, ((context | 131072) ^ 131072) | 128, scope, privateScope, { loop: 1,
|
|
3520
|
+
return parseStatement(parser, ((context | 131072) ^ 131072) | 128, scope, privateScope, { loop: 1, parent: labels }, 0);
|
|
3516
3521
|
}
|
|
3517
3522
|
function parseContinueStatement(parser, context, labels) {
|
|
3518
3523
|
if ((context & 128) === 0)
|
|
@@ -3522,9 +3527,9 @@
|
|
|
3522
3527
|
let label = null;
|
|
3523
3528
|
if ((parser.flags & 1) === 0 && parser.getToken() & 143360) {
|
|
3524
3529
|
const { tokenValue } = parser;
|
|
3525
|
-
label = parseIdentifier(parser, context | 32);
|
|
3526
3530
|
if (!isValidLabel(parser, labels, tokenValue, 1))
|
|
3527
3531
|
parser.report(140, tokenValue);
|
|
3532
|
+
label = parseIdentifier(parser, context | 32);
|
|
3528
3533
|
}
|
|
3529
3534
|
matchOrInsertSemicolon(parser, context | 32);
|
|
3530
3535
|
return parser.finishNode({
|
|
@@ -3538,9 +3543,9 @@
|
|
|
3538
3543
|
let label = null;
|
|
3539
3544
|
if ((parser.flags & 1) === 0 && parser.getToken() & 143360) {
|
|
3540
3545
|
const { tokenValue } = parser;
|
|
3541
|
-
label = parseIdentifier(parser, context | 32);
|
|
3542
3546
|
if (!isValidLabel(parser, labels, tokenValue, 0))
|
|
3543
3547
|
parser.report(140, tokenValue);
|
|
3548
|
+
label = parseIdentifier(parser, context | 32);
|
|
3544
3549
|
}
|
|
3545
3550
|
else if ((context & (4 | 128)) === 0) {
|
|
3546
3551
|
parser.report(69);
|
|
@@ -3578,7 +3583,7 @@
|
|
|
3578
3583
|
const start = parser.tokenStart;
|
|
3579
3584
|
nextToken(parser, context | 32);
|
|
3580
3585
|
const firstScope = scope?.createChildScope(16);
|
|
3581
|
-
const block = parseBlock(parser, context, firstScope, privateScope, {
|
|
3586
|
+
const block = parseBlock(parser, context, firstScope, privateScope, { parent: labels });
|
|
3582
3587
|
const { tokenStart } = parser;
|
|
3583
3588
|
const handler = consumeOpt(parser, context | 32, 20557)
|
|
3584
3589
|
? parseCatchBlock(parser, context, scope, privateScope, labels, tokenStart)
|
|
@@ -3587,7 +3592,7 @@
|
|
|
3587
3592
|
if (parser.getToken() === 20566) {
|
|
3588
3593
|
nextToken(parser, context | 32);
|
|
3589
3594
|
const finalizerScope = scope?.createChildScope(4);
|
|
3590
|
-
const block = parseBlock(parser, context, finalizerScope, privateScope, {
|
|
3595
|
+
const block = parseBlock(parser, context, finalizerScope, privateScope, { parent: labels });
|
|
3591
3596
|
finalizer = block;
|
|
3592
3597
|
}
|
|
3593
3598
|
if (!handler && !finalizer) {
|
|
@@ -3616,7 +3621,7 @@
|
|
|
3616
3621
|
consume(parser, context | 32, 16);
|
|
3617
3622
|
}
|
|
3618
3623
|
const additionalScope = scope?.createChildScope(32);
|
|
3619
|
-
const body = parseBlock(parser, context, additionalScope, privateScope, {
|
|
3624
|
+
const body = parseBlock(parser, context, additionalScope, privateScope, { parent: labels });
|
|
3620
3625
|
return parser.finishNode({
|
|
3621
3626
|
type: 'CatchClause',
|
|
3622
3627
|
param,
|
|
@@ -4363,24 +4368,29 @@
|
|
|
4363
4368
|
const { tokenStart } = parser;
|
|
4364
4369
|
declaration = parseIdentifier(parser, context);
|
|
4365
4370
|
const { flags } = parser;
|
|
4366
|
-
if ((flags & 1) === 0) {
|
|
4367
|
-
|
|
4368
|
-
|
|
4369
|
-
|
|
4370
|
-
|
|
4371
|
-
|
|
4372
|
-
|
|
4373
|
-
|
|
4374
|
-
|
|
4375
|
-
|
|
4376
|
-
|
|
4377
|
-
if (scope)
|
|
4378
|
-
scope = createArrowHeadParsingScope(parser, context, parser.tokenValue, parser.tokenStart, parser.currentLocation);
|
|
4379
|
-
declaration = parseIdentifier(parser, context);
|
|
4380
|
-
declaration = parseArrowFunctionExpression(parser, context, scope, undefined, [declaration], 1, tokenStart);
|
|
4381
|
-
}
|
|
4382
|
-
}
|
|
4371
|
+
if ((flags & 1) === 0 && parser.getToken() === 86104) {
|
|
4372
|
+
declaration = parseFunctionDeclaration(parser, context, scope, undefined, 1, 1, 1, tokenStart, 4);
|
|
4373
|
+
break;
|
|
4374
|
+
}
|
|
4375
|
+
if (parser.getToken() === 10) {
|
|
4376
|
+
declaration = parseArrowFromIdentifier(parser, context & -9, undefined, 'async', declaration, 0, 1, 0, tokenStart);
|
|
4377
|
+
}
|
|
4378
|
+
else if ((flags & 1) === 0 && parser.getToken() === 67174411) {
|
|
4379
|
+
declaration = parseAsyncArrowOrCallExpression(parser, context, undefined, declaration, 1, 1, flags, tokenStart);
|
|
4380
|
+
declaration = parseMemberOrUpdateExpression(parser, context, undefined, declaration, 0, 0, tokenStart);
|
|
4381
|
+
declaration = parseAssignmentExpression(parser, context, undefined, 0, 0, tokenStart, declaration);
|
|
4383
4382
|
}
|
|
4383
|
+
else if ((flags & 1) === 0 && parser.getToken() & 143360) {
|
|
4384
|
+
if (scope)
|
|
4385
|
+
scope = createArrowHeadParsingScope(parser, context, parser.tokenValue, parser.tokenStart, parser.currentLocation);
|
|
4386
|
+
declaration = parseIdentifier(parser, context);
|
|
4387
|
+
declaration = parseArrowFunctionExpression(parser, context, scope, undefined, [declaration], 1, tokenStart);
|
|
4388
|
+
}
|
|
4389
|
+
else {
|
|
4390
|
+
declaration = parseMemberOrUpdateExpression(parser, context, undefined, declaration, 0, 0, tokenStart);
|
|
4391
|
+
declaration = parseAssignmentExpression(parser, context, undefined, 0, 0, tokenStart, declaration);
|
|
4392
|
+
}
|
|
4393
|
+
matchOrInsertSemicolon(parser, context | 32);
|
|
4384
4394
|
break;
|
|
4385
4395
|
}
|
|
4386
4396
|
default:
|
|
@@ -4606,6 +4616,10 @@
|
|
|
4606
4616
|
}, start);
|
|
4607
4617
|
}
|
|
4608
4618
|
function parseBinaryExpression(parser, context, privateScope, inGroup, start, minPrecedence, operator, left) {
|
|
4619
|
+
if ((parser.flags & 16384) === 16384) {
|
|
4620
|
+
parser.flags = (parser.flags | 16384) ^ 16384;
|
|
4621
|
+
return left;
|
|
4622
|
+
}
|
|
4609
4623
|
const bit = -((context & 131072) > 0) & 8673330;
|
|
4610
4624
|
let t;
|
|
4611
4625
|
let precedence;
|
|
@@ -4688,12 +4702,16 @@
|
|
|
4688
4702
|
return expr;
|
|
4689
4703
|
}
|
|
4690
4704
|
function parseYieldExpressionOrIdentifier(parser, context, privateScope, inGroup, canAssign, start) {
|
|
4691
|
-
if (inGroup)
|
|
4705
|
+
if (inGroup) {
|
|
4706
|
+
if ((parser.destructible & 256) === 0) {
|
|
4707
|
+
parser.firstYieldLocation ??= { start, end: parser.currentLocation };
|
|
4708
|
+
}
|
|
4692
4709
|
parser.destructible |= 256;
|
|
4710
|
+
}
|
|
4693
4711
|
if (context & 1024) {
|
|
4694
4712
|
nextToken(parser, context | 32);
|
|
4695
4713
|
if (context & 8192)
|
|
4696
|
-
parser.
|
|
4714
|
+
throw new ParseError(start, parser.startPosition, 32);
|
|
4697
4715
|
if (!canAssign)
|
|
4698
4716
|
parser.report(26);
|
|
4699
4717
|
if (parser.getToken() === 22)
|
|
@@ -4709,6 +4727,12 @@
|
|
|
4709
4727
|
else if (parser.getToken() === 8391476) {
|
|
4710
4728
|
parser.report(30, KeywordDescTable[parser.getToken() & 255]);
|
|
4711
4729
|
}
|
|
4730
|
+
if (parser.getToken() & (67108864 | 8388608)) {
|
|
4731
|
+
if (argument === null && (parser.flags & 1) === 0) {
|
|
4732
|
+
parser.report(30, KeywordDescTable[parser.getToken() & 255]);
|
|
4733
|
+
}
|
|
4734
|
+
parser.flags |= 16384;
|
|
4735
|
+
}
|
|
4712
4736
|
parser.assignable = 2;
|
|
4713
4737
|
return parser.finishNode({
|
|
4714
4738
|
type: 'YieldExpression',
|
|
@@ -4729,8 +4753,11 @@
|
|
|
4729
4753
|
}
|
|
4730
4754
|
if (context & 524288)
|
|
4731
4755
|
parser.report(179);
|
|
4732
|
-
const
|
|
4733
|
-
const
|
|
4756
|
+
const isEscaped = (parser.getToken() & -2147483648) !== 0;
|
|
4757
|
+
const allowRegExp = !isEscaped && context & (2048 | 2) ? 1 : 0;
|
|
4758
|
+
const possibleIdentifierOrArrowFunc = parseIdentifierOrArrow(parser, context, privateScope, allowRegExp);
|
|
4759
|
+
const isIdentifier = isEscaped ||
|
|
4760
|
+
possibleIdentifierOrArrowFunc.type === 'ArrowFunctionExpression' ||
|
|
4734
4761
|
(parser.getToken() & 65536) === 0;
|
|
4735
4762
|
if (isIdentifier) {
|
|
4736
4763
|
if (context & 2048)
|
|
@@ -4741,7 +4768,8 @@
|
|
|
4741
4768
|
throw new ParseError(start, parser.startPosition, 112);
|
|
4742
4769
|
return possibleIdentifierOrArrowFunc;
|
|
4743
4770
|
}
|
|
4744
|
-
if (context & 8192
|
|
4771
|
+
if (context & 8192 &&
|
|
4772
|
+
(context & (2048 | 2) || parser.getToken() & 143360)) {
|
|
4745
4773
|
throw new ParseError(start, parser.startPosition, 31);
|
|
4746
4774
|
}
|
|
4747
4775
|
if (context & 2048 || (context & 2 && context & 8)) {
|
|
@@ -4867,6 +4895,10 @@
|
|
|
4867
4895
|
expr = parseUpdateExpression(parser, context, expr, start);
|
|
4868
4896
|
}
|
|
4869
4897
|
else if ((parser.getToken() & 67108864) === 67108864) {
|
|
4898
|
+
if ((parser.flags & 16384) === 16384) {
|
|
4899
|
+
parser.flags = (parser.flags | 16384) ^ 16384;
|
|
4900
|
+
return expr;
|
|
4901
|
+
}
|
|
4870
4902
|
context = (context | 131072) ^ 131072;
|
|
4871
4903
|
switch (parser.getToken()) {
|
|
4872
4904
|
case 67108877: {
|
|
@@ -5062,6 +5094,7 @@
|
|
|
5062
5094
|
if ((parser.getToken() & 143360) === 143360) {
|
|
5063
5095
|
switch (parser.getToken()) {
|
|
5064
5096
|
case 209006:
|
|
5097
|
+
case 209006 | -2147483648:
|
|
5065
5098
|
return parseAwaitExpressionOrIdentifier(parser, context, privateScope, inNew, inGroup, start);
|
|
5066
5099
|
case 241771:
|
|
5067
5100
|
return parseYieldExpressionOrIdentifier(parser, context, privateScope, inGroup, canAssign, start);
|
|
@@ -5408,10 +5441,9 @@
|
|
|
5408
5441
|
consume(parser, context | 64, 16);
|
|
5409
5442
|
return args;
|
|
5410
5443
|
}
|
|
5411
|
-
function parseIdentifier(parser, context) {
|
|
5444
|
+
function parseIdentifier(parser, context, allowRegExp = 0) {
|
|
5412
5445
|
const { tokenValue, tokenStart } = parser;
|
|
5413
|
-
|
|
5414
|
-
nextToken(parser, context | (allowRegex ? 32 : 0));
|
|
5446
|
+
nextToken(parser, context | (allowRegExp ? 32 : 0));
|
|
5415
5447
|
return parser.finishNode({
|
|
5416
5448
|
type: 'Identifier',
|
|
5417
5449
|
name: tokenValue,
|
|
@@ -5771,10 +5803,9 @@
|
|
|
5771
5803
|
parser.report(41);
|
|
5772
5804
|
}
|
|
5773
5805
|
else if (token & 2097152) {
|
|
5774
|
-
argument =
|
|
5775
|
-
parser
|
|
5776
|
-
|
|
5777
|
-
: parseArrayExpressionOrPattern(parser, context, scope, privateScope, 1, inGroup, isPattern, kind, origin);
|
|
5806
|
+
argument = (parser.getToken() === 2162700
|
|
5807
|
+
? parseObjectLiteralOrPattern(parser, context, scope, privateScope, 1, inGroup, isPattern, kind, origin)
|
|
5808
|
+
: parseArrayExpressionOrPattern(parser, context, scope, privateScope, 1, inGroup, isPattern, kind, origin));
|
|
5778
5809
|
token = parser.getToken();
|
|
5779
5810
|
if (token !== 1077936155 && token !== closingToken && token !== 18) {
|
|
5780
5811
|
if (parser.destructible & 8)
|
|
@@ -5809,7 +5840,6 @@
|
|
|
5809
5840
|
else {
|
|
5810
5841
|
destructible |= 32;
|
|
5811
5842
|
argument = parseLeftHandSideExpression(parser, context, privateScope, 1, inGroup, 1);
|
|
5812
|
-
const { tokenStart } = parser;
|
|
5813
5843
|
const token = parser.getToken();
|
|
5814
5844
|
if (token === 1077936155) {
|
|
5815
5845
|
if (parser.assignable & 2)
|
|
@@ -5955,7 +5985,7 @@
|
|
|
5955
5985
|
}
|
|
5956
5986
|
else {
|
|
5957
5987
|
destructible |=
|
|
5958
|
-
(token === 209006 ? 128 : 0) |
|
|
5988
|
+
((token & 255) === (209006 & 255) ? 128 : 0) |
|
|
5959
5989
|
(token === -2147483527 ? 16 : 0);
|
|
5960
5990
|
value = parser.cloneIdentifier(key);
|
|
5961
5991
|
}
|
|
@@ -6444,6 +6474,7 @@
|
|
|
6444
6474
|
parser.flags = (parser.flags | 128) ^ 128;
|
|
6445
6475
|
parser.strictReservedRange = null;
|
|
6446
6476
|
parser.firstAwaitLocation = null;
|
|
6477
|
+
parser.firstYieldLocation = null;
|
|
6447
6478
|
if (parser.getToken() === 16) {
|
|
6448
6479
|
if (kind & 512) {
|
|
6449
6480
|
parser.report(37, 'Setter', 'one', '');
|
|
@@ -6536,6 +6567,8 @@
|
|
|
6536
6567
|
parser.destructible &= -385;
|
|
6537
6568
|
const previousFirstAwaitLocation = parser.firstAwaitLocation;
|
|
6538
6569
|
parser.firstAwaitLocation = null;
|
|
6570
|
+
const previousFirstYieldLocation = parser.firstYieldLocation;
|
|
6571
|
+
parser.firstYieldLocation = null;
|
|
6539
6572
|
let expr;
|
|
6540
6573
|
let expressions = [];
|
|
6541
6574
|
let isSequence = 0;
|
|
@@ -6622,7 +6655,7 @@
|
|
|
6622
6655
|
parser.assignable = 2;
|
|
6623
6656
|
expr = parser.finishNode({
|
|
6624
6657
|
type: 'SequenceExpression',
|
|
6625
|
-
expressions,
|
|
6658
|
+
expressions: expressions,
|
|
6626
6659
|
}, tokenAfterParenthesesStart);
|
|
6627
6660
|
}
|
|
6628
6661
|
consume(parser, context, 16);
|
|
@@ -6630,6 +6663,9 @@
|
|
|
6630
6663
|
if (previousFirstAwaitLocation) {
|
|
6631
6664
|
parser.firstAwaitLocation = previousFirstAwaitLocation;
|
|
6632
6665
|
}
|
|
6666
|
+
if (previousFirstYieldLocation) {
|
|
6667
|
+
parser.firstYieldLocation = previousFirstYieldLocation;
|
|
6668
|
+
}
|
|
6633
6669
|
return parser.options.preserveParens
|
|
6634
6670
|
? parser.finishNode({
|
|
6635
6671
|
type: 'ParenthesizedExpression',
|
|
@@ -6655,7 +6691,7 @@
|
|
|
6655
6691
|
parser.assignable = 2;
|
|
6656
6692
|
expr = parser.finishNode({
|
|
6657
6693
|
type: 'SequenceExpression',
|
|
6658
|
-
expressions,
|
|
6694
|
+
expressions: expressions,
|
|
6659
6695
|
}, tokenAfterParenthesesStart);
|
|
6660
6696
|
}
|
|
6661
6697
|
consume(parser, context, 16);
|
|
@@ -6674,6 +6710,9 @@
|
|
|
6674
6710
|
parser.report(31);
|
|
6675
6711
|
}
|
|
6676
6712
|
if (context & (1 | 1024) && destructible & 256) {
|
|
6713
|
+
const loc = parser.firstYieldLocation;
|
|
6714
|
+
if (loc)
|
|
6715
|
+
throw new ParseError(loc.start, loc.end, 32);
|
|
6677
6716
|
parser.report(32);
|
|
6678
6717
|
}
|
|
6679
6718
|
if (isNonSimpleParameterList)
|
|
@@ -6684,6 +6723,9 @@
|
|
|
6684
6723
|
if (previousFirstAwaitLocation) {
|
|
6685
6724
|
parser.firstAwaitLocation = previousFirstAwaitLocation;
|
|
6686
6725
|
}
|
|
6726
|
+
if (previousFirstYieldLocation) {
|
|
6727
|
+
parser.firstYieldLocation = previousFirstYieldLocation;
|
|
6728
|
+
}
|
|
6687
6729
|
return parseParenthesizedArrow(parser, context, scope, privateScope, isSequence ? expressions : [expr], canAssign, 0, start, origin);
|
|
6688
6730
|
}
|
|
6689
6731
|
if (destructible & 64) {
|
|
@@ -6697,6 +6739,9 @@
|
|
|
6697
6739
|
if (previousFirstAwaitLocation) {
|
|
6698
6740
|
parser.firstAwaitLocation = previousFirstAwaitLocation;
|
|
6699
6741
|
}
|
|
6742
|
+
if (previousFirstYieldLocation) {
|
|
6743
|
+
parser.firstYieldLocation = previousFirstYieldLocation;
|
|
6744
|
+
}
|
|
6700
6745
|
return parser.options.preserveParens
|
|
6701
6746
|
? parser.finishNode({
|
|
6702
6747
|
type: 'ParenthesizedExpression',
|
|
@@ -6704,7 +6749,7 @@
|
|
|
6704
6749
|
}, parenthesesStart)
|
|
6705
6750
|
: expr;
|
|
6706
6751
|
}
|
|
6707
|
-
function parseIdentifierOrArrow(parser, context, privateScope) {
|
|
6752
|
+
function parseIdentifierOrArrow(parser, context, privateScope, allowRegExp = 0) {
|
|
6708
6753
|
const { tokenValue, tokenStart, currentLocation } = parser;
|
|
6709
6754
|
let isNonSimpleParameterList = 0;
|
|
6710
6755
|
let hasStrictReserved = 0;
|
|
@@ -6714,7 +6759,7 @@
|
|
|
6714
6759
|
else if ((parser.getToken() & 36864) === 36864) {
|
|
6715
6760
|
hasStrictReserved = 1;
|
|
6716
6761
|
}
|
|
6717
|
-
const expr = parseIdentifier(parser, context);
|
|
6762
|
+
const expr = parseIdentifier(parser, context, allowRegExp);
|
|
6718
6763
|
parser.assignable = 1;
|
|
6719
6764
|
if (parser.getToken() === 10) {
|
|
6720
6765
|
const scope = parser.options.lexical
|
|
@@ -6806,6 +6851,7 @@
|
|
|
6806
6851
|
parser.flags = (parser.flags | 128) ^ 128;
|
|
6807
6852
|
parser.strictReservedRange = null;
|
|
6808
6853
|
parser.firstAwaitLocation = null;
|
|
6854
|
+
parser.firstYieldLocation = null;
|
|
6809
6855
|
const params = [];
|
|
6810
6856
|
if (consumeOpt(parser, context, 16))
|
|
6811
6857
|
return params;
|
|
@@ -6948,7 +6994,7 @@
|
|
|
6948
6994
|
}, start);
|
|
6949
6995
|
}
|
|
6950
6996
|
function parseAsyncArrowAfterIdent(parser, context, privateScope, canAssign, start) {
|
|
6951
|
-
if (parser.getToken() === 209006)
|
|
6997
|
+
if ((parser.getToken() & 255) === (209006 & 255))
|
|
6952
6998
|
parser.report(31);
|
|
6953
6999
|
if (context & (1 | 1024) && parser.getToken() === 241771) {
|
|
6954
7000
|
parser.report(32);
|
|
@@ -6964,6 +7010,8 @@
|
|
|
6964
7010
|
const scope = parser.createScopeIfLexical()?.createChildScope(512);
|
|
6965
7011
|
const previousFirstAwaitLocation = parser.firstAwaitLocation;
|
|
6966
7012
|
parser.firstAwaitLocation = null;
|
|
7013
|
+
const previousFirstYieldLocation = parser.firstYieldLocation;
|
|
7014
|
+
parser.firstYieldLocation = null;
|
|
6967
7015
|
context = (context | 131072) ^ 131072;
|
|
6968
7016
|
if (consumeOpt(parser, context, 16)) {
|
|
6969
7017
|
if (parser.getToken() === 10) {
|
|
@@ -6979,6 +7027,8 @@
|
|
|
6979
7027
|
}
|
|
6980
7028
|
if (previousFirstAwaitLocation)
|
|
6981
7029
|
parser.firstAwaitLocation = previousFirstAwaitLocation;
|
|
7030
|
+
if (previousFirstYieldLocation)
|
|
7031
|
+
parser.firstYieldLocation = previousFirstYieldLocation;
|
|
6982
7032
|
return parser.finishNode({
|
|
6983
7033
|
type: 'CallExpression',
|
|
6984
7034
|
callee,
|
|
@@ -7025,10 +7075,9 @@
|
|
|
7025
7075
|
}
|
|
7026
7076
|
}
|
|
7027
7077
|
else if (token & 2097152) {
|
|
7028
|
-
expr =
|
|
7029
|
-
|
|
7030
|
-
|
|
7031
|
-
: parseArrayExpressionOrPattern(parser, context, scope, privateScope, 0, 1, 0, kind);
|
|
7078
|
+
expr = (token === 2162700
|
|
7079
|
+
? parseObjectLiteralOrPattern(parser, context, scope, privateScope, 0, 1, 0, kind)
|
|
7080
|
+
: parseArrayExpressionOrPattern(parser, context, scope, privateScope, 0, 1, 0, kind));
|
|
7032
7081
|
destructible |= parser.destructible;
|
|
7033
7082
|
isNonSimpleParameterList = 1;
|
|
7034
7083
|
if (parser.getToken() !== 16 && parser.getToken() !== 18) {
|
|
@@ -7068,6 +7117,8 @@
|
|
|
7068
7117
|
}
|
|
7069
7118
|
if (previousFirstAwaitLocation)
|
|
7070
7119
|
parser.firstAwaitLocation = previousFirstAwaitLocation;
|
|
7120
|
+
if (previousFirstYieldLocation)
|
|
7121
|
+
parser.firstYieldLocation = previousFirstYieldLocation;
|
|
7071
7122
|
return parser.finishNode({
|
|
7072
7123
|
type: 'CallExpression',
|
|
7073
7124
|
callee,
|
|
@@ -7094,8 +7145,12 @@
|
|
|
7094
7145
|
throw new ParseError(loc.start, loc.end, 31);
|
|
7095
7146
|
parser.report(31);
|
|
7096
7147
|
}
|
|
7097
|
-
if (context & (1 | 1024) && destructible & 256)
|
|
7148
|
+
if (context & (1 | 1024) && destructible & 256) {
|
|
7149
|
+
const loc = parser.firstYieldLocation;
|
|
7150
|
+
if (loc)
|
|
7151
|
+
throw new ParseError(loc.start, loc.end, 32);
|
|
7098
7152
|
parser.report(32);
|
|
7153
|
+
}
|
|
7099
7154
|
if (isNonSimpleParameterList)
|
|
7100
7155
|
parser.flags |= 128;
|
|
7101
7156
|
return parseParenthesizedArrow(parser, context | 2048, scope, privateScope, params, canAssign, 1, start);
|
|
@@ -7114,6 +7169,8 @@
|
|
|
7114
7169
|
}
|
|
7115
7170
|
if (previousFirstAwaitLocation)
|
|
7116
7171
|
parser.firstAwaitLocation = previousFirstAwaitLocation;
|
|
7172
|
+
if (previousFirstYieldLocation)
|
|
7173
|
+
parser.firstYieldLocation = previousFirstYieldLocation;
|
|
7117
7174
|
return parser.finishNode({
|
|
7118
7175
|
type: 'CallExpression',
|
|
7119
7176
|
callee,
|
|
@@ -7493,6 +7550,7 @@
|
|
|
7493
7550
|
parser.report(121);
|
|
7494
7551
|
const modifierFlags = 1024 |
|
|
7495
7552
|
2048 |
|
|
7553
|
+
8 |
|
|
7496
7554
|
8192 |
|
|
7497
7555
|
((state & 64) === 0 ? 512 | 16384 : 0);
|
|
7498
7556
|
context =
|