meriyah 6.0.6 → 6.1.0
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 +32 -11
- package/README.md +7 -10
- package/dist/meriyah.cjs +236 -259
- package/dist/meriyah.min.mjs +1 -1
- package/dist/meriyah.mjs +237 -259
- package/dist/meriyah.umd.js +236 -259
- package/dist/meriyah.umd.min.js +1 -1
- package/dist/{src → types}/chars.d.ts +0 -1
- package/dist/{src → types}/common.d.ts +2 -3
- package/dist/{src → types}/errors.d.ts +4 -5
- package/dist/{src → types}/estree.d.ts +16 -18
- package/dist/{src → types}/lexer/charClassifier.d.ts +0 -1
- package/dist/{src → types}/lexer/comments.d.ts +1 -2
- package/dist/{src → types}/lexer/common.d.ts +1 -2
- package/dist/{src → types}/lexer/decodeHTML.d.ts +0 -1
- package/dist/{src → types}/lexer/identifier.d.ts +1 -2
- package/dist/{src → types}/lexer/index.d.ts +3 -4
- package/dist/{src → types}/lexer/jsx.d.ts +1 -2
- package/dist/{src → types}/lexer/numeric.d.ts +1 -2
- package/dist/{src → types}/lexer/regexp.d.ts +1 -2
- package/dist/{src → types}/lexer/scan.d.ts +1 -2
- package/dist/{src → types}/lexer/string.d.ts +1 -2
- package/dist/{src → types}/lexer/template.d.ts +1 -2
- package/dist/{src → types}/meriyah.d.ts +6 -6
- package/dist/{src → types}/parser.d.ts +6 -7
- package/dist/{src → types}/token.d.ts +4 -5
- package/dist/types/unicode.d.ts +3 -0
- package/package.json +31 -30
- package/dist/src/chars.d.ts.map +0 -1
- package/dist/src/common.d.ts.map +0 -1
- package/dist/src/errors.d.ts.map +0 -1
- package/dist/src/estree.d.ts.map +0 -1
- package/dist/src/lexer/charClassifier.d.ts.map +0 -1
- package/dist/src/lexer/comments.d.ts.map +0 -1
- package/dist/src/lexer/common.d.ts.map +0 -1
- package/dist/src/lexer/decodeHTML.d.ts.map +0 -1
- package/dist/src/lexer/identifier.d.ts.map +0 -1
- package/dist/src/lexer/index.d.ts.map +0 -1
- package/dist/src/lexer/jsx.d.ts.map +0 -1
- package/dist/src/lexer/numeric.d.ts.map +0 -1
- package/dist/src/lexer/regexp.d.ts.map +0 -1
- package/dist/src/lexer/scan.d.ts.map +0 -1
- package/dist/src/lexer/string.d.ts.map +0 -1
- package/dist/src/lexer/template.d.ts.map +0 -1
- package/dist/src/meriyah.d.ts.map +0 -1
- package/dist/src/parser.d.ts.map +0 -1
- package/dist/src/token.d.ts.map +0 -1
- package/dist/src/unicode.d.ts +0 -6
- package/dist/src/unicode.d.ts.map +0 -1
package/dist/meriyah.umd.js
CHANGED
|
@@ -181,29 +181,21 @@
|
|
|
181
181
|
[174]: "The only valid meta property for import is 'import.meta'",
|
|
182
182
|
[175]: "'import.meta' must not contain escaped characters",
|
|
183
183
|
[176]: 'cannot use "await" as identifier inside an async function',
|
|
184
|
-
[177]: 'cannot use "await" in static blocks'
|
|
184
|
+
[177]: 'cannot use "await" in static blocks',
|
|
185
185
|
};
|
|
186
186
|
class ParseError extends SyntaxError {
|
|
187
187
|
constructor(start, startLine, startColumn, end, endLine, endColumn, type, ...params) {
|
|
188
|
-
const
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
startColumn +
|
|
192
|
-
'-' +
|
|
193
|
-
endLine +
|
|
194
|
-
':' +
|
|
195
|
-
endColumn +
|
|
196
|
-
']: ' +
|
|
197
|
-
errorMessages[type].replace(/%(\d+)/g, (_, i) => params[i]);
|
|
198
|
-
super(`${message}`);
|
|
188
|
+
const description = errorMessages[type].replace(/%(\d+)/g, (_, i) => params[i]);
|
|
189
|
+
const message = '[' + startLine + ':' + startColumn + '-' + endLine + ':' + endColumn + ']: ' + description;
|
|
190
|
+
super(message);
|
|
199
191
|
this.start = start;
|
|
200
192
|
this.end = end;
|
|
201
193
|
this.range = [start, end];
|
|
202
194
|
this.loc = {
|
|
203
195
|
start: { line: startLine, column: startColumn },
|
|
204
|
-
end: { line: endLine, column: endColumn }
|
|
196
|
+
end: { line: endLine, column: endColumn },
|
|
205
197
|
};
|
|
206
|
-
this.description =
|
|
198
|
+
this.description = description;
|
|
207
199
|
}
|
|
208
200
|
}
|
|
209
201
|
function report(parser, type, ...params) {
|
|
@@ -219,12 +211,6 @@
|
|
|
219
211
|
throw new ParseError(tokenIndex, tokenLine, tokenColumn, index, line, column, type);
|
|
220
212
|
}
|
|
221
213
|
|
|
222
|
-
function isIDContinue(code) {
|
|
223
|
-
return (unicodeLookup[(code >>> 5) + 0] >>> code & 31 & 1) !== 0;
|
|
224
|
-
}
|
|
225
|
-
function isIDStart(code) {
|
|
226
|
-
return (unicodeLookup[(code >>> 5) + 34816] >>> code & 31 & 1) !== 0;
|
|
227
|
-
}
|
|
228
214
|
const unicodeLookup = ((compressed, lookup) => {
|
|
229
215
|
const result = new Uint32Array(104448);
|
|
230
216
|
let index = 0;
|
|
@@ -248,6 +234,8 @@
|
|
|
248
234
|
}
|
|
249
235
|
return result;
|
|
250
236
|
})([-1, 2, 26, 2, 27, 2, 5, -1, 0, 77595648, 3, 44, 2, 3, 0, 14, 2, 63, 2, 64, 3, 0, 3, 0, 3168796671, 0, 4294956992, 2, 1, 2, 0, 2, 41, 3, 0, 4, 0, 4294966523, 3, 0, 4, 2, 16, 2, 65, 2, 0, 0, 4294836735, 0, 3221225471, 0, 4294901942, 2, 66, 0, 134152192, 3, 0, 2, 0, 4294951935, 3, 0, 2, 0, 2683305983, 0, 2684354047, 2, 18, 2, 0, 0, 4294961151, 3, 0, 2, 2, 19, 2, 0, 0, 608174079, 2, 0, 2, 60, 2, 7, 2, 6, 0, 4286611199, 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, 2, 203, 2, 3, 0, 4093640191, 0, 660618719, 0, 65487, 0, 4294828015, 0, 4092591615, 0, 1616920031, 0, 982991, 2, 3, 2, 0, 0, 2163244511, 0, 4227923919, 0, 4236247022, 2, 71, 0, 4284449919, 0, 851904, 2, 4, 2, 12, 0, 67076095, -1, 2, 72, 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, 10, 2, 0, 2, 15, 2, 22, 3, 0, 10, 2, 74, 2, 0, 2, 75, 2, 76, 2, 77, 2, 0, 2, 78, 2, 0, 2, 11, 0, 261632, 2, 25, 3, 0, 2, 2, 13, 2, 4, 3, 0, 18, 2, 79, 2, 5, 3, 0, 2, 2, 80, 0, 2151677951, 2, 29, 2, 9, 0, 909311, 3, 0, 2, 0, 814743551, 2, 49, 0, 67090432, 3, 0, 2, 2, 42, 2, 0, 2, 6, 2, 0, 2, 30, 2, 8, 0, 268374015, 2, 110, 2, 51, 2, 0, 2, 81, 0, 134153215, -1, 2, 7, 2, 0, 2, 8, 0, 2684354559, 0, 67044351, 0, 3221160064, 2, 17, -1, 3, 0, 2, 2, 53, 0, 1046528, 3, 0, 3, 2, 9, 2, 0, 2, 54, 0, 4294960127, 2, 10, 2, 6, 2, 11, 0, 4294377472, 2, 12, 3, 0, 16, 2, 13, 2, 0, 2, 82, 2, 10, 2, 0, 2, 83, 2, 84, 2, 85, 2, 210, 2, 55, 0, 1048577, 2, 86, 2, 14, -1, 2, 14, 0, 131042, 2, 87, 2, 88, 2, 89, 2, 0, 2, 34, -83, 3, 0, 7, 0, 1046559, 2, 0, 2, 15, 2, 0, 0, 2147516671, 2, 21, 3, 90, 2, 2, 0, -16, 2, 91, 0, 524222462, 2, 4, 2, 0, 0, 4269801471, 2, 4, 3, 0, 2, 2, 28, 2, 16, 3, 0, 2, 2, 17, 2, 0, -1, 2, 18, -16, 3, 0, 206, -2, 3, 0, 692, 2, 73, -1, 2, 18, 2, 10, 3, 0, 8, 2, 93, 2, 133, 2, 0, 0, 3220242431, 3, 0, 3, 2, 19, 2, 94, 2, 95, 3, 0, 2, 2, 96, 2, 0, 2, 97, 2, 46, 2, 0, 0, 4351, 2, 0, 2, 9, 3, 0, 2, 0, 67043391, 0, 3909091327, 2, 0, 2, 24, 2, 9, 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, 101, 2, 102, 2, 22, 2, 23, 3, 0, 3, 0, 67057663, 3, 0, 349, 2, 103, 2, 104, 2, 7, -264, 3, 0, 11, 2, 24, 3, 0, 2, 2, 32, -1, 0, 3774349439, 2, 105, 2, 106, 3, 0, 2, 2, 19, 2, 107, 3, 0, 10, 2, 10, 2, 18, 2, 0, 2, 47, 2, 0, 2, 31, 2, 108, 2, 25, 0, 1638399, 2, 183, 2, 109, 3, 0, 3, 2, 20, 2, 26, 2, 27, 2, 5, 2, 28, 2, 0, 2, 8, 2, 111, -1, 2, 112, 2, 113, 2, 114, -1, 3, 0, 3, 2, 12, -2, 2, 0, 2, 29, -3, 2, 163, -4, 2, 20, 2, 0, 2, 36, 0, 1, 2, 0, 2, 67, 2, 6, 2, 12, 2, 10, 2, 0, 2, 115, -1, 3, 0, 4, 2, 10, 2, 23, 2, 116, 2, 7, 2, 0, 2, 117, 2, 0, 2, 118, 2, 119, 2, 120, 2, 0, 2, 9, 3, 0, 9, 2, 21, 2, 30, 2, 31, 2, 121, 2, 122, -2, 2, 123, 2, 124, 2, 30, 2, 21, 2, 8, -2, 2, 125, 2, 30, 2, 32, -2, 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, 48, 2, 0, 0, 4294950463, 2, 37, -7, 2, 0, 0, 203775, 2, 57, 2, 167, 2, 20, 2, 43, 2, 36, 2, 18, 2, 37, 2, 18, 2, 126, 2, 21, 3, 0, 2, 2, 38, 0, 2151677888, 2, 0, 2, 12, 0, 4294901764, 2, 144, 2, 0, 2, 58, 2, 56, 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, 61, 2, 38, -5, 2, 0, 2, 12, -3, 3, 0, 2, 0, 2147484671, 2, 134, 0, 4190109695, 2, 52, -2, 2, 135, 0, 4244635647, 0, 27, 2, 0, 2, 8, 2, 43, 2, 0, 2, 68, 2, 18, 2, 0, 2, 42, -6, 2, 0, 2, 45, 2, 59, 2, 44, 2, 45, 2, 46, 2, 47, 0, 8388351, -2, 2, 136, 0, 3028287487, 2, 48, 2, 138, 0, 33259519, 2, 49, -9, 2, 21, 0, 4294836223, 0, 3355443199, 0, 134152199, -2, 2, 69, -2, 3, 0, 28, 2, 32, -3, 3, 0, 3, 2, 17, 3, 0, 6, 2, 50, -81, 2, 18, 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, -4, 3, 0, 2, 0, 4294936575, 2, 0, 0, 4294934783, -2, 0, 196635, 3, 0, 191, 2, 54, 3, 0, 38, 2, 30, 2, 55, 2, 34, -278, 2, 140, 3, 0, 9, 2, 141, 2, 142, 2, 56, 3, 0, 11, 2, 7, -72, 3, 0, 3, 2, 143, 0, 1677656575, -130, 2, 26, -16, 2, 0, 2, 24, 2, 38, -16, 0, 4161266656, 0, 4071, 2, 205, -4, 2, 57, -13, 3, 0, 2, 2, 58, 2, 0, 2, 145, 2, 146, 2, 62, 2, 0, 2, 147, 2, 148, 2, 149, 3, 0, 10, 2, 150, 2, 151, 2, 22, 3, 58, 2, 3, 152, 2, 3, 59, 2, 0, 4294954999, 2, 0, -16, 2, 0, 2, 92, 2, 0, 0, 2105343, 0, 4160749584, 2, 177, -34, 2, 8, 2, 154, -6, 0, 4194303871, 0, 4294903771, 2, 0, 2, 60, 2, 100, -3, 2, 0, 0, 1073684479, 0, 17407, -9, 2, 18, 2, 17, 2, 0, 2, 32, -14, 2, 18, 2, 32, -6, 2, 18, 2, 12, -15, 2, 155, 3, 0, 6, 0, 8323103, -1, 3, 0, 2, 2, 61, -37, 2, 62, 2, 156, 2, 157, 2, 158, 2, 159, 2, 160, -105, 2, 26, -32, 3, 0, 1335, -1, 3, 0, 129, 2, 32, 3, 0, 6, 2, 10, 3, 0, 180, 2, 161, 3, 0, 233, 2, 162, 3, 0, 18, 2, 10, -77, 3, 0, 16, 2, 10, -47, 3, 0, 154, 2, 6, 3, 0, 130, 2, 25, -22250, 3, 0, 7, 2, 25, -6130, 3, 5, 2, -1, 0, 69207040, 3, 44, 2, 3, 0, 14, 2, 63, 2, 64, -3, 0, 3168731136, 0, 4294956864, 2, 1, 2, 0, 2, 41, 3, 0, 4, 0, 4294966275, 3, 0, 4, 2, 16, 2, 65, 2, 0, 2, 34, -1, 2, 18, 2, 66, -1, 2, 0, 0, 2047, 0, 4294885376, 3, 0, 2, 0, 3145727, 0, 2617294944, 0, 4294770688, 2, 25, 2, 67, 3, 0, 2, 0, 131135, 2, 98, 0, 70256639, 0, 71303167, 0, 272, 2, 42, 2, 6, 0, 32511, 2, 0, 2, 49, -1, 2, 99, 2, 68, 0, 4278255616, 0, 4294836227, 0, 4294549473, 0, 600178175, 0, 2952806400, 0, 268632067, 0, 4294543328, 0, 57540095, 0, 1577058304, 0, 1835008, 0, 4294688736, 2, 70, 2, 69, 0, 33554435, 2, 131, 2, 70, 2, 164, 0, 131075, 0, 3594373096, 0, 67094296, 2, 69, -1, 0, 4294828000, 0, 603979263, 0, 654311424, 0, 3, 0, 4294828001, 0, 602930687, 2, 171, 0, 393219, 0, 4294828016, 0, 671088639, 0, 2154840064, 0, 4227858435, 0, 4236247008, 2, 71, 2, 38, -1, 2, 4, 0, 917503, 2, 38, -1, 2, 72, 0, 537788335, 0, 4026531935, -1, 0, 1, -1, 2, 33, 2, 73, 0, 7936, -3, 2, 0, 0, 2147485695, 0, 1010761728, 0, 4292984930, 0, 16387, 2, 0, 2, 15, 2, 22, 3, 0, 10, 2, 74, 2, 0, 2, 75, 2, 76, 2, 77, 2, 0, 2, 78, 2, 0, 2, 12, -1, 2, 25, 3, 0, 2, 2, 13, 2, 4, 3, 0, 18, 2, 79, 2, 5, 3, 0, 2, 2, 80, 0, 2147745791, 3, 19, 2, 0, 122879, 2, 0, 2, 9, 0, 276824064, -2, 3, 0, 2, 2, 42, 2, 0, 0, 4294903295, 2, 0, 2, 30, 2, 8, -1, 2, 18, 2, 51, 2, 0, 2, 81, 2, 49, -1, 2, 21, 2, 0, 2, 29, -2, 0, 128, -2, 2, 28, 2, 9, 0, 8160, -1, 2, 127, 0, 4227907585, 2, 0, 2, 37, 2, 0, 2, 50, 2, 184, 2, 10, 2, 6, 2, 11, -1, 0, 74440192, 3, 0, 6, -2, 3, 0, 8, 2, 13, 2, 0, 2, 82, 2, 10, 2, 0, 2, 83, 2, 84, 2, 85, -3, 2, 86, 2, 14, -3, 2, 87, 2, 88, 2, 89, 2, 0, 2, 34, -83, 3, 0, 7, 0, 817183, 2, 0, 2, 15, 2, 0, 0, 33023, 2, 21, 3, 90, 2, -17, 2, 91, 0, 524157950, 2, 4, 2, 0, 2, 92, 2, 4, 2, 0, 2, 22, 2, 28, 2, 16, 3, 0, 2, 2, 17, 2, 0, -1, 2, 18, -16, 3, 0, 206, -2, 3, 0, 692, 2, 73, -1, 2, 18, 2, 10, 3, 0, 8, 2, 93, 0, 3072, 2, 0, 0, 2147516415, 2, 10, 3, 0, 2, 2, 25, 2, 94, 2, 95, 3, 0, 2, 2, 96, 2, 0, 2, 97, 2, 46, 0, 4294965179, 0, 7, 2, 0, 2, 9, 2, 95, 2, 9, -1, 0, 1761345536, 2, 98, 0, 4294901823, 2, 38, 2, 20, 2, 99, 2, 35, 2, 100, 0, 2080440287, 2, 0, 2, 34, 2, 153, 0, 3296722943, 2, 0, 0, 1046675455, 0, 939524101, 0, 1837055, 2, 101, 2, 102, 2, 22, 2, 23, 3, 0, 3, 0, 7, 3, 0, 349, 2, 103, 2, 104, 2, 7, -264, 3, 0, 11, 2, 24, 3, 0, 2, 2, 32, -1, 0, 2700607615, 2, 105, 2, 106, 3, 0, 2, 2, 19, 2, 107, 3, 0, 10, 2, 10, 2, 18, 2, 0, 2, 47, 2, 0, 2, 31, 2, 108, -3, 2, 109, 3, 0, 3, 2, 20, -1, 3, 5, 2, 2, 110, 2, 0, 2, 8, 2, 111, -1, 2, 112, 2, 113, 2, 114, -1, 3, 0, 3, 2, 12, -2, 2, 0, 2, 29, -8, 2, 20, 2, 0, 2, 36, -1, 2, 0, 2, 67, 2, 6, 2, 30, 2, 10, 2, 0, 2, 115, -1, 3, 0, 4, 2, 10, 2, 18, 2, 116, 2, 7, 2, 0, 2, 117, 2, 0, 2, 118, 2, 119, 2, 120, 2, 0, 2, 9, 3, 0, 9, 2, 21, 2, 30, 2, 31, 2, 121, 2, 122, -2, 2, 123, 2, 124, 2, 30, 2, 21, 2, 8, -2, 2, 125, 2, 30, 2, 32, -2, 2, 0, 2, 39, -2, 0, 4277075969, 2, 30, -1, 3, 20, 2, -1, 2, 33, 2, 126, 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, 98, 0, 4294934591, 2, 37, -7, 2, 0, 0, 197631, 2, 57, -1, 2, 20, 2, 43, 2, 37, 2, 18, 0, 3, 2, 18, 2, 126, 2, 21, 2, 127, 2, 54, -1, 0, 2490368, 2, 127, 2, 25, 2, 18, 2, 34, 2, 127, 2, 38, 0, 4294901904, 0, 4718591, 2, 127, 2, 35, 0, 335544350, -1, 2, 128, 0, 2147487743, 0, 1, -1, 2, 129, 2, 130, 2, 8, -1, 2, 131, 2, 70, 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, 17, 2, 192, -1, 2, 0, 2, 25, 2, 209, -1, 2, 0, 0, 16779263, -2, 2, 12, -1, 2, 38, -5, 2, 0, 2, 133, -3, 3, 0, 2, 2, 55, 2, 134, 0, 2147549183, 0, 2, -2, 2, 135, 2, 36, 0, 10, 0, 4294965249, 0, 67633151, 0, 4026597376, 2, 0, 0, 536871935, 2, 18, 2, 0, 2, 42, -6, 2, 0, 0, 1, 2, 59, 2, 17, 0, 1, 2, 46, 2, 25, -3, 2, 136, 2, 36, 2, 137, 2, 138, 0, 16778239, -10, 2, 35, 0, 4294836212, 2, 9, -3, 2, 69, -2, 3, 0, 28, 2, 32, -3, 3, 0, 3, 2, 17, 3, 0, 6, 2, 50, -81, 2, 18, 3, 0, 2, 2, 36, 3, 0, 33, 2, 25, 0, 126, 3, 0, 124, 2, 12, 3, 0, 18, 2, 38, -213, 2, 10, -55, 3, 0, 17, 2, 42, 2, 8, 2, 18, 2, 0, 2, 8, 2, 18, 2, 60, 2, 0, 2, 25, 2, 50, 2, 139, 2, 25, -13, 2, 0, 2, 73, -6, 3, 0, 2, -4, 3, 0, 2, 0, 67583, -1, 2, 107, -2, 0, 11, 3, 0, 191, 2, 54, 3, 0, 38, 2, 30, 2, 55, 2, 34, -278, 2, 140, 3, 0, 9, 2, 141, 2, 142, 2, 56, 3, 0, 11, 2, 7, -72, 3, 0, 3, 2, 143, 2, 144, -187, 3, 0, 2, 2, 58, 2, 0, 2, 145, 2, 146, 2, 62, 2, 0, 2, 147, 2, 148, 2, 149, 3, 0, 10, 2, 150, 2, 151, 2, 22, 3, 58, 2, 3, 152, 2, 3, 59, 2, 2, 153, -57, 2, 8, 2, 154, -7, 2, 18, 2, 0, 2, 60, -4, 2, 0, 0, 1065361407, 0, 16384, -9, 2, 18, 2, 60, 2, 0, 2, 133, -14, 2, 18, 2, 133, -6, 2, 18, 0, 81919, -15, 2, 155, 3, 0, 6, 2, 126, -1, 3, 0, 2, 0, 2063, -37, 2, 62, 2, 156, 2, 157, 2, 158, 2, 159, 2, 160, -138, 3, 0, 1335, -1, 3, 0, 129, 2, 32, 3, 0, 6, 2, 10, 3, 0, 180, 2, 161, 3, 0, 233, 2, 162, 3, 0, 18, 2, 10, -77, 3, 0, 16, 2, 10, -47, 3, 0, 154, 2, 6, 3, 0, 130, 2, 25, -28386, 2, 0, 0, 1, -1, 2, 55, 2, 0, 0, 8193, -21, 2, 201, 0, 10255, 0, 4, -11, 2, 69, 2, 182, -1, 0, 71680, -1, 2, 174, 0, 4292900864, 0, 268435519, -5, 2, 163, -1, 2, 173, -1, 0, 6144, -2, 2, 46, -1, 2, 168, -1, 0, 2147532800, 2, 164, 2, 170, 0, 8355840, -2, 0, 4, -4, 2, 198, 0, 205128192, 0, 1333757536, 0, 2147483696, 0, 423953, 0, 747766272, 0, 2717763192, 0, 4286578751, 0, 278545, 2, 165, 0, 4294886464, 0, 33292336, 0, 417809, 2, 165, 0, 1327482464, 0, 4278190128, 0, 700594195, 0, 1006647527, 0, 4286497336, 0, 4160749631, 2, 166, 0, 201327104, 0, 3634348576, 0, 8323120, 2, 166, 0, 202375680, 0, 2678047264, 0, 4293984304, 2, 166, -1, 0, 983584, 0, 48, 0, 58720273, 0, 3489923072, 0, 10517376, 0, 4293066815, 0, 1, 2, 213, 2, 167, 2, 0, 0, 2089, 0, 3221225552, 0, 201359520, 2, 0, -2, 0, 256, 0, 122880, 0, 16777216, 2, 163, 0, 4160757760, 2, 0, -6, 2, 179, -11, 0, 3263218176, -1, 0, 49664, 0, 2160197632, 0, 8388802, -1, 0, 12713984, -1, 2, 168, 2, 186, 2, 187, -2, 2, 175, -20, 0, 3758096385, -2, 2, 169, 2, 195, 2, 94, 2, 180, 0, 4294057984, -2, 2, 176, 2, 172, 0, 4227874816, -2, 2, 169, -1, 2, 170, -1, 2, 181, 2, 55, 0, 4026593280, 0, 14, 0, 4292919296, -1, 2, 178, 0, 939588608, -1, 0, 805306368, -1, 2, 55, 2, 171, 2, 172, 2, 173, 2, 211, 2, 0, -2, 0, 8192, -4, 0, 267386880, -1, 0, 117440512, 0, 7168, -1, 2, 170, 2, 168, 2, 174, 2, 188, -16, 2, 175, -1, 0, 1426112704, 2, 176, -1, 2, 196, 0, 271581216, 0, 2149777408, 2, 25, 2, 174, 2, 55, 0, 851967, 2, 189, -1, 2, 177, 2, 190, -4, 2, 178, -20, 2, 98, 2, 208, -56, 0, 3145728, 2, 191, -10, 0, 32505856, -1, 2, 179, -1, 0, 2147385088, 2, 94, 1, 2155905152, 2, -3, 2, 176, 2, 0, 0, 67108864, -2, 2, 180, -6, 2, 181, 2, 25, 0, 1, -1, 0, 1, -1, 2, 182, -3, 2, 126, 2, 69, -2, 2, 100, -2, 0, 32704, 2, 55, -915, 2, 183, -1, 2, 207, -10, 2, 194, -5, 2, 185, -6, 0, 3759456256, 2, 19, -1, 2, 184, -1, 2, 185, -2, 0, 4227874752, -3, 0, 2146435072, 2, 186, -2, 0, 1006649344, 2, 55, -1, 2, 94, 0, 201375744, -3, 0, 134217720, 2, 94, 0, 4286677377, 0, 32896, -1, 2, 178, -3, 0, 4227907584, -349, 0, 65520, 0, 1920, 2, 167, 3, 0, 264, -11, 2, 173, -2, 2, 187, 2, 0, 0, 520617856, 0, 2692743168, 0, 36, -3, 0, 524280, -13, 2, 193, -1, 0, 4294934272, 2, 25, 2, 187, -1, 2, 215, 0, 2158720, -3, 2, 186, 0, 1, -4, 2, 55, 0, 3808625411, 0, 3489628288, 0, 4096, 0, 1207959680, 0, 3221274624, 2, 0, -3, 2, 188, 0, 120, 0, 7340032, -2, 2, 189, 2, 4, 2, 25, 2, 176, 3, 0, 4, 2, 186, -1, 2, 190, 2, 167, -1, 0, 8176, 2, 170, 2, 188, 0, 1073741824, -1, 0, 4290773232, 2, 0, -4, 2, 176, 2, 197, 0, 15728640, 2, 167, -1, 2, 174, -1, 0, 134250480, 0, 4720640, 0, 3825467396, -1, 2, 180, -9, 2, 94, 2, 181, 0, 4294967040, 2, 137, 0, 4160880640, 3, 0, 2, 0, 704, 0, 1849688064, 2, 191, -1, 2, 55, 0, 4294901887, 2, 0, 0, 130547712, 0, 1879048192, 2, 212, 3, 0, 2, -1, 2, 192, 2, 193, -1, 0, 17829776, 0, 2025848832, 0, 4261477888, -2, 2, 0, -1, 0, 4286580608, -1, 0, 29360128, 2, 200, 0, 16252928, 0, 3791388672, 2, 130, 3, 0, 2, -2, 2, 206, 2, 0, -1, 2, 107, -1, 0, 66584576, -1, 2, 199, -1, 0, 448, 0, 4294918080, 3, 0, 6, 2, 55, -1, 0, 4294755328, 0, 4294967267, 2, 7, -1, 2, 174, 2, 187, 2, 25, 2, 98, 2, 25, 2, 194, 2, 94, -2, 0, 245760, 2, 195, -1, 2, 163, 2, 202, 0, 4227923456, -1, 2, 196, 2, 174, 2, 94, -3, 0, 4292870145, 0, 262144, -1, 2, 95, 2, 0, 0, 1073758848, 2, 197, -1, 0, 4227921920, 2, 198, 0, 68289024, 0, 528402016, 0, 4292927536, 0, 46080, 2, 191, 0, 4265609306, 0, 4294967289, -2, 0, 268435456, 2, 95, -2, 2, 199, 3, 0, 5, -1, 2, 200, 2, 176, 2, 0, -2, 0, 4227923936, 2, 67, -1, 2, 187, 2, 197, 2, 99, 2, 168, 2, 178, 2, 204, 3, 0, 5, -1, 2, 167, 3, 0, 3, -2, 0, 2146959360, 0, 9440640, 0, 104857600, 0, 4227923840, 3, 0, 2, 0, 768, 2, 201, 2, 28, -2, 2, 174, -2, 2, 202, -1, 2, 169, 2, 98, 3, 0, 5, -1, 0, 4227923964, 0, 512, 0, 8388608, 2, 203, 2, 183, 2, 193, 0, 4286578944, 3, 0, 2, 0, 1152, 0, 1266679808, 2, 199, 0, 576, 0, 4261707776, 2, 98, 3, 0, 9, 2, 169, 0, 131072, 0, 939524096, 2, 188, 3, 0, 2, 2, 16, -1, 0, 2147221504, -28, 2, 187, 3, 0, 3, -3, 0, 4292902912, -6, 2, 99, 3, 0, 81, 2, 25, -2, 2, 107, -33, 2, 18, 2, 181, -124, 2, 188, -18, 2, 204, 3, 0, 213, -1, 2, 187, 3, 0, 54, -17, 2, 169, 2, 55, 2, 205, -1, 2, 55, 2, 197, 0, 4290822144, -2, 0, 67174336, 0, 520093700, 2, 18, 3, 0, 13, -1, 2, 187, 3, 0, 6, -2, 2, 188, 3, 0, 3, -2, 0, 30720, -1, 0, 32512, 3, 0, 2, 0, 4294770656, -191, 2, 185, -38, 2, 181, 2, 8, 2, 206, 3, 0, 278, 0, 2417033215, -9, 0, 4294705144, 0, 4292411391, 0, 65295, -11, 2, 167, 3, 0, 72, -3, 0, 3758159872, 0, 201391616, 3, 0, 123, -7, 2, 187, -13, 2, 180, 3, 0, 2, -1, 2, 173, 2, 207, -3, 2, 99, 2, 0, -7, 2, 181, -1, 0, 384, -1, 0, 133693440, -3, 2, 208, -2, 2, 110, 3, 0, 3, 3, 180, 2, -2, 2, 94, 2, 169, 3, 0, 4, -2, 2, 196, -1, 2, 163, 0, 335552923, 2, 209, -1, 0, 538974272, 0, 2214592512, 0, 132000, -10, 0, 192, -8, 2, 210, -21, 0, 134213632, 2, 162, 3, 0, 34, 2, 55, 0, 4294965279, 3, 0, 6, 0, 100663424, 0, 63524, -1, 2, 214, 2, 152, 3, 0, 3, -1, 0, 3221282816, 0, 4294917120, 3, 0, 9, 2, 25, 2, 211, -1, 2, 212, 3, 0, 14, 2, 25, 2, 187, 3, 0, 6, 2, 25, 2, 213, 3, 0, 15, 0, 2147520640, -6, 0, 4286578784, 2, 0, -2, 0, 1006694400, 3, 0, 24, 2, 36, -1, 0, 4292870144, 3, 0, 2, 0, 1, 2, 176, 3, 0, 6, 2, 209, 0, 4110942569, 0, 1432950139, 0, 2701658217, 0, 4026532864, 0, 4026532881, 2, 0, 2, 47, 3, 0, 8, -1, 2, 178, -2, 2, 180, 0, 98304, 0, 65537, 2, 181, -5, 2, 214, 2, 0, 2, 37, 2, 202, 2, 167, 0, 4294770176, 2, 110, 3, 0, 4, -30, 2, 192, 0, 3758153728, -3, 0, 125829120, -2, 2, 187, 0, 4294897664, 2, 178, -1, 2, 199, -1, 2, 174, 0, 4026580992, 2, 95, 2, 0, -10, 2, 180, 0, 3758145536, 0, 31744, -1, 0, 1610628992, 0, 4261477376, -4, 2, 215, -2, 2, 187, 3, 0, 32, -1335, 2, 0, -129, 2, 187, -6, 2, 176, -180, 0, 65532, -233, 2, 177, -18, 2, 176, 3, 0, 77, -16, 2, 176, 3, 0, 47, -154, 2, 170, -130, 2, 18, 3, 0, 22250, -7, 2, 18, 3, 0, 6128], [4294967295, 4294967291, 4092460543, 4294828031, 4294967294, 134217726, 4294903807, 268435455, 2147483647, 1048575, 1073741823, 3892314111, 134217727, 1061158911, 536805376, 4294910143, 4294901759, 32767, 4294901760, 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, 4294705152, 4294770687, 67043583, 1023, 15, 2047999, 67043343, 67051519, 16777215, 2147483648, 4294902000, 28, 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, 535511039, 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, 4294967288, 4294705151, 3221208447, 4294902271, 4294549472, 4294921215, 4095, 4285526655, 4294966527, 4294966143, 64, 4294966719, 3774873592, 1877934080, 262151, 2555904, 536807423, 67043839, 3758096383, 3959414372, 3755993023, 2080374783, 4294835295, 4294967103, 4160749565, 4294934527, 4087, 2016, 2147446655, 184024726, 2862017156, 1593309078, 268434431, 268434414, 4294901763, 4294901761, 536870912, 2952790016, 202506752, 139264, 4026531840, 402653184, 4261412864, 63488, 1610612736, 4227922944, 49152, 65280, 3233808384, 3221225472, 65534, 61440, 57152, 4293918720, 4290772992, 25165824, 57344, 4227915776, 4278190080, 3758096384, 4227858432, 4160749568, 3758129152, 4294836224, 4194304, 251658240, 196608, 4294963200, 2143289344, 2097152, 64512, 417808, 4227923712, 12582912, 50331648, 65528, 65472, 4294967168, 15360, 4294966784, 65408, 4294965248, 16, 12288, 4294934528, 2080374784, 2013265920, 4294950912, 524288]);
|
|
237
|
+
const isIDContinue = (code) => (unicodeLookup[(code >>> 5) + 0] >>> code & 31 & 1) !== 0;
|
|
238
|
+
const isIDStart = (code) => (unicodeLookup[(code >>> 5) + 34816] >>> code & 31 & 1) !== 0;
|
|
251
239
|
|
|
252
240
|
function advanceChar(parser) {
|
|
253
241
|
parser.column++;
|
|
@@ -758,12 +746,12 @@
|
|
|
758
746
|
const loc = {
|
|
759
747
|
start: {
|
|
760
748
|
line,
|
|
761
|
-
column
|
|
749
|
+
column,
|
|
762
750
|
},
|
|
763
751
|
end: {
|
|
764
752
|
line: parser.tokenLine,
|
|
765
|
-
column: parser.tokenColumn
|
|
766
|
-
}
|
|
753
|
+
column: parser.tokenColumn,
|
|
754
|
+
},
|
|
767
755
|
};
|
|
768
756
|
parser.onComment(CommentTypes[type & 0xff], source.slice(index, parser.tokenIndex), start, parser.tokenIndex, loc);
|
|
769
757
|
}
|
|
@@ -785,12 +773,12 @@
|
|
|
785
773
|
const loc = {
|
|
786
774
|
start: {
|
|
787
775
|
line: parser.tokenLine,
|
|
788
|
-
column: parser.tokenColumn
|
|
776
|
+
column: parser.tokenColumn,
|
|
789
777
|
},
|
|
790
778
|
end: {
|
|
791
779
|
line: parser.line,
|
|
792
|
-
column: parser.column
|
|
793
|
-
}
|
|
780
|
+
column: parser.column,
|
|
781
|
+
},
|
|
794
782
|
};
|
|
795
783
|
parser.onComment(CommentTypes[1 & 0xff], source.slice(index, parser.index - 2), index - 2, parser.index, loc);
|
|
796
784
|
}
|
|
@@ -1802,7 +1790,7 @@
|
|
|
1802
1790
|
8389702,
|
|
1803
1791
|
1074790415,
|
|
1804
1792
|
16842799,
|
|
1805
|
-
128
|
|
1793
|
+
128,
|
|
1806
1794
|
];
|
|
1807
1795
|
function nextToken(parser, context) {
|
|
1808
1796
|
parser.flags = (parser.flags | 1) ^ 1;
|
|
@@ -4259,7 +4247,7 @@
|
|
|
4259
4247
|
zopf: '\uD835\uDD6B',
|
|
4260
4248
|
zscr: '\uD835\uDCCF',
|
|
4261
4249
|
zwj: '\u200D',
|
|
4262
|
-
zwnj: '\u200C'
|
|
4250
|
+
zwnj: '\u200C',
|
|
4263
4251
|
};
|
|
4264
4252
|
const decodeMap = {
|
|
4265
4253
|
'0': 65533,
|
|
@@ -4289,7 +4277,7 @@
|
|
|
4289
4277
|
'155': 8250,
|
|
4290
4278
|
'156': 339,
|
|
4291
4279
|
'158': 382,
|
|
4292
|
-
'159': 376
|
|
4280
|
+
'159': 376,
|
|
4293
4281
|
};
|
|
4294
4282
|
function decodeHTMLStrict(text) {
|
|
4295
4283
|
return text.replace(/&(?:[a-zA-Z]+|#[xX][\da-fA-F]+|#\d+);/g, (key) => {
|
|
@@ -4555,12 +4543,12 @@
|
|
|
4555
4543
|
node.loc = {
|
|
4556
4544
|
start: {
|
|
4557
4545
|
line,
|
|
4558
|
-
column
|
|
4546
|
+
column,
|
|
4559
4547
|
},
|
|
4560
4548
|
end: {
|
|
4561
4549
|
line: parser.startLine,
|
|
4562
|
-
column: parser.startColumn
|
|
4563
|
-
}
|
|
4550
|
+
column: parser.startColumn,
|
|
4551
|
+
},
|
|
4564
4552
|
};
|
|
4565
4553
|
if (parser.sourceFile) {
|
|
4566
4554
|
node.loc.source = parser.sourceFile;
|
|
@@ -4593,26 +4581,26 @@
|
|
|
4593
4581
|
column,
|
|
4594
4582
|
tokenIndex,
|
|
4595
4583
|
tokenLine,
|
|
4596
|
-
tokenColumn
|
|
4584
|
+
tokenColumn,
|
|
4597
4585
|
};
|
|
4598
4586
|
}
|
|
4599
4587
|
function createScope() {
|
|
4600
4588
|
return {
|
|
4601
4589
|
parent: void 0,
|
|
4602
|
-
type: 2
|
|
4590
|
+
type: 2,
|
|
4603
4591
|
};
|
|
4604
4592
|
}
|
|
4605
4593
|
function addChildScope(parent, type) {
|
|
4606
4594
|
return {
|
|
4607
4595
|
parent,
|
|
4608
4596
|
type,
|
|
4609
|
-
scopeError: void 0
|
|
4597
|
+
scopeError: void 0,
|
|
4610
4598
|
};
|
|
4611
4599
|
}
|
|
4612
4600
|
function addChildPrivateScope(parent) {
|
|
4613
4601
|
return {
|
|
4614
4602
|
parent,
|
|
4615
|
-
refs: Object.create(null)
|
|
4603
|
+
refs: Object.create(null),
|
|
4616
4604
|
};
|
|
4617
4605
|
}
|
|
4618
4606
|
function addVarOrBlock(parser, context, scope, name, kind, origin) {
|
|
@@ -4699,7 +4687,7 @@
|
|
|
4699
4687
|
scope.refs[name].push({
|
|
4700
4688
|
index: parser.tokenIndex,
|
|
4701
4689
|
line: parser.tokenLine,
|
|
4702
|
-
column: parser.tokenColumn
|
|
4690
|
+
column: parser.tokenColumn,
|
|
4703
4691
|
});
|
|
4704
4692
|
}
|
|
4705
4693
|
function isPrivateIdentifierDefined(name, scope) {
|
|
@@ -4734,7 +4722,7 @@
|
|
|
4734
4722
|
return function (type, value, start, end, loc) {
|
|
4735
4723
|
const comment = {
|
|
4736
4724
|
type,
|
|
4737
|
-
value
|
|
4725
|
+
value,
|
|
4738
4726
|
};
|
|
4739
4727
|
if (context & 2) {
|
|
4740
4728
|
comment.start = start;
|
|
@@ -4750,7 +4738,7 @@
|
|
|
4750
4738
|
function pushToken(context, array) {
|
|
4751
4739
|
return function (token, start, end, loc) {
|
|
4752
4740
|
const tokens = {
|
|
4753
|
-
token
|
|
4741
|
+
token,
|
|
4754
4742
|
};
|
|
4755
4743
|
if (context & 2) {
|
|
4756
4744
|
tokens.start = start;
|
|
@@ -4810,12 +4798,12 @@
|
|
|
4810
4798
|
const loc = {
|
|
4811
4799
|
start: {
|
|
4812
4800
|
line: this.tokenLine,
|
|
4813
|
-
column: this.tokenColumn
|
|
4801
|
+
column: this.tokenColumn,
|
|
4814
4802
|
},
|
|
4815
4803
|
end: {
|
|
4816
4804
|
line: this.line,
|
|
4817
|
-
column: this.column
|
|
4818
|
-
}
|
|
4805
|
+
column: this.column,
|
|
4806
|
+
},
|
|
4819
4807
|
};
|
|
4820
4808
|
if (!replaceLast && lastOnToken) {
|
|
4821
4809
|
onToken(...lastOnToken);
|
|
@@ -4841,7 +4829,7 @@
|
|
|
4841
4829
|
onComment,
|
|
4842
4830
|
onToken,
|
|
4843
4831
|
onInsertedSemicolon,
|
|
4844
|
-
leadingDecorators: []
|
|
4832
|
+
leadingDecorators: [],
|
|
4845
4833
|
};
|
|
4846
4834
|
}
|
|
4847
4835
|
function parseSource(source, options, context) {
|
|
@@ -4906,7 +4894,7 @@
|
|
|
4906
4894
|
const node = {
|
|
4907
4895
|
type: 'Program',
|
|
4908
4896
|
sourceType,
|
|
4909
|
-
body
|
|
4897
|
+
body,
|
|
4910
4898
|
};
|
|
4911
4899
|
if (context & 2) {
|
|
4912
4900
|
node.start = 0;
|
|
@@ -4916,7 +4904,7 @@
|
|
|
4916
4904
|
if (context & 4) {
|
|
4917
4905
|
node.loc = {
|
|
4918
4906
|
start: { line: 1, column: 0 },
|
|
4919
|
-
end: { line: parser.line, column: parser.column }
|
|
4907
|
+
end: { line: parser.line, column: parser.column },
|
|
4920
4908
|
};
|
|
4921
4909
|
if (parser.sourceFile)
|
|
4922
4910
|
node.loc.source = sourceFile;
|
|
@@ -5084,7 +5072,7 @@
|
|
|
5084
5072
|
}
|
|
5085
5073
|
return parseExpressionStatement(parser, context, expr, start, line, column);
|
|
5086
5074
|
}
|
|
5087
|
-
function parseBlock(parser, context, scope, privateScope, labels, start, line, column) {
|
|
5075
|
+
function parseBlock(parser, context, scope, privateScope, labels, start, line, column, type = 'BlockStatement') {
|
|
5088
5076
|
const body = [];
|
|
5089
5077
|
consume(parser, context | 8192, 2162700);
|
|
5090
5078
|
while (parser.getToken() !== 1074790415) {
|
|
@@ -5092,8 +5080,8 @@
|
|
|
5092
5080
|
}
|
|
5093
5081
|
consume(parser, context | 8192, 1074790415);
|
|
5094
5082
|
return finishNode(parser, context, start, line, column, {
|
|
5095
|
-
type
|
|
5096
|
-
body
|
|
5083
|
+
type,
|
|
5084
|
+
body,
|
|
5097
5085
|
});
|
|
5098
5086
|
}
|
|
5099
5087
|
function parseReturnStatement(parser, context, privateScope, start, line, column) {
|
|
@@ -5106,14 +5094,14 @@
|
|
|
5106
5094
|
matchOrInsertSemicolon(parser, context | 8192);
|
|
5107
5095
|
return finishNode(parser, context, start, line, column, {
|
|
5108
5096
|
type: 'ReturnStatement',
|
|
5109
|
-
argument
|
|
5097
|
+
argument,
|
|
5110
5098
|
});
|
|
5111
5099
|
}
|
|
5112
5100
|
function parseExpressionStatement(parser, context, expression, start, line, column) {
|
|
5113
5101
|
matchOrInsertSemicolon(parser, context | 8192);
|
|
5114
5102
|
return finishNode(parser, context, start, line, column, {
|
|
5115
5103
|
type: 'ExpressionStatement',
|
|
5116
|
-
expression
|
|
5104
|
+
expression,
|
|
5117
5105
|
});
|
|
5118
5106
|
}
|
|
5119
5107
|
function parseLabelledStatement(parser, context, scope, privateScope, origin, labels, value, expr, token, allowFuncDecl, start, line, column) {
|
|
@@ -5129,7 +5117,7 @@
|
|
|
5129
5117
|
return finishNode(parser, context, start, line, column, {
|
|
5130
5118
|
type: 'LabeledStatement',
|
|
5131
5119
|
label: expr,
|
|
5132
|
-
body
|
|
5120
|
+
body,
|
|
5133
5121
|
});
|
|
5134
5122
|
}
|
|
5135
5123
|
function parseAsyncArrowOrAsyncFunctionDeclaration(parser, context, scope, privateScope, origin, labels, allowFuncDecl, start, line, column) {
|
|
@@ -5191,17 +5179,17 @@
|
|
|
5191
5179
|
? finishNode(parser, context, start, line, column, {
|
|
5192
5180
|
type: 'ExpressionStatement',
|
|
5193
5181
|
expression,
|
|
5194
|
-
directive: parser.source.slice(start + 1, endIndex - 1)
|
|
5182
|
+
directive: parser.source.slice(start + 1, endIndex - 1),
|
|
5195
5183
|
})
|
|
5196
5184
|
: finishNode(parser, context, start, line, column, {
|
|
5197
5185
|
type: 'ExpressionStatement',
|
|
5198
|
-
expression
|
|
5186
|
+
expression,
|
|
5199
5187
|
});
|
|
5200
5188
|
}
|
|
5201
5189
|
function parseEmptyStatement(parser, context, start, line, column) {
|
|
5202
5190
|
nextToken(parser, context | 8192);
|
|
5203
5191
|
return finishNode(parser, context, start, line, column, {
|
|
5204
|
-
type: 'EmptyStatement'
|
|
5192
|
+
type: 'EmptyStatement',
|
|
5205
5193
|
});
|
|
5206
5194
|
}
|
|
5207
5195
|
function parseThrowStatement(parser, context, privateScope, start, line, column) {
|
|
@@ -5212,7 +5200,7 @@
|
|
|
5212
5200
|
matchOrInsertSemicolon(parser, context | 8192);
|
|
5213
5201
|
return finishNode(parser, context, start, line, column, {
|
|
5214
5202
|
type: 'ThrowStatement',
|
|
5215
|
-
argument
|
|
5203
|
+
argument,
|
|
5216
5204
|
});
|
|
5217
5205
|
}
|
|
5218
5206
|
function parseIfStatement(parser, context, scope, privateScope, labels, start, line, column) {
|
|
@@ -5231,7 +5219,7 @@
|
|
|
5231
5219
|
type: 'IfStatement',
|
|
5232
5220
|
test,
|
|
5233
5221
|
consequent,
|
|
5234
|
-
alternate
|
|
5222
|
+
alternate,
|
|
5235
5223
|
});
|
|
5236
5224
|
}
|
|
5237
5225
|
function parseConsequentOrAlternative(parser, context, scope, privateScope, labels, start, line, column) {
|
|
@@ -5269,20 +5257,20 @@
|
|
|
5269
5257
|
parser.getToken() !== 1074790415 &&
|
|
5270
5258
|
parser.getToken() !== 20561) {
|
|
5271
5259
|
consequent.push(parseStatementListItem(parser, context | 1024, scope, privateScope, 2, {
|
|
5272
|
-
$: labels
|
|
5260
|
+
$: labels,
|
|
5273
5261
|
}));
|
|
5274
5262
|
}
|
|
5275
5263
|
cases.push(finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
5276
5264
|
type: 'SwitchCase',
|
|
5277
5265
|
test,
|
|
5278
|
-
consequent
|
|
5266
|
+
consequent,
|
|
5279
5267
|
}));
|
|
5280
5268
|
}
|
|
5281
5269
|
consume(parser, context | 8192, 1074790415);
|
|
5282
5270
|
return finishNode(parser, context, start, line, column, {
|
|
5283
5271
|
type: 'SwitchStatement',
|
|
5284
5272
|
discriminant,
|
|
5285
|
-
cases
|
|
5273
|
+
cases,
|
|
5286
5274
|
});
|
|
5287
5275
|
}
|
|
5288
5276
|
function parseWhileStatement(parser, context, scope, privateScope, labels, start, line, column) {
|
|
@@ -5294,7 +5282,7 @@
|
|
|
5294
5282
|
return finishNode(parser, context, start, line, column, {
|
|
5295
5283
|
type: 'WhileStatement',
|
|
5296
5284
|
test,
|
|
5297
|
-
body
|
|
5285
|
+
body,
|
|
5298
5286
|
});
|
|
5299
5287
|
}
|
|
5300
5288
|
function parseIterationStatementBody(parser, context, scope, privateScope, labels) {
|
|
@@ -5314,7 +5302,7 @@
|
|
|
5314
5302
|
matchOrInsertSemicolon(parser, context | 8192);
|
|
5315
5303
|
return finishNode(parser, context, start, line, column, {
|
|
5316
5304
|
type: 'ContinueStatement',
|
|
5317
|
-
label
|
|
5305
|
+
label,
|
|
5318
5306
|
});
|
|
5319
5307
|
}
|
|
5320
5308
|
function parseBreakStatement(parser, context, labels, start, line, column) {
|
|
@@ -5332,7 +5320,7 @@
|
|
|
5332
5320
|
matchOrInsertSemicolon(parser, context | 8192);
|
|
5333
5321
|
return finishNode(parser, context, start, line, column, {
|
|
5334
5322
|
type: 'BreakStatement',
|
|
5335
|
-
label
|
|
5323
|
+
label,
|
|
5336
5324
|
});
|
|
5337
5325
|
}
|
|
5338
5326
|
function parseWithStatement(parser, context, scope, privateScope, labels, start, line, column) {
|
|
@@ -5346,14 +5334,14 @@
|
|
|
5346
5334
|
return finishNode(parser, context, start, line, column, {
|
|
5347
5335
|
type: 'WithStatement',
|
|
5348
5336
|
object,
|
|
5349
|
-
body
|
|
5337
|
+
body,
|
|
5350
5338
|
});
|
|
5351
5339
|
}
|
|
5352
5340
|
function parseDebuggerStatement(parser, context, start, line, column) {
|
|
5353
5341
|
nextToken(parser, context | 8192);
|
|
5354
5342
|
matchOrInsertSemicolon(parser, context | 8192);
|
|
5355
5343
|
return finishNode(parser, context, start, line, column, {
|
|
5356
|
-
type: 'DebuggerStatement'
|
|
5344
|
+
type: 'DebuggerStatement',
|
|
5357
5345
|
});
|
|
5358
5346
|
}
|
|
5359
5347
|
function parseTryStatement(parser, context, scope, privateScope, labels, start, line, column) {
|
|
@@ -5368,7 +5356,8 @@
|
|
|
5368
5356
|
if (parser.getToken() === 20566) {
|
|
5369
5357
|
nextToken(parser, context | 8192);
|
|
5370
5358
|
const finalizerScope = firstScope ? addChildScope(scope, 4) : void 0;
|
|
5371
|
-
|
|
5359
|
+
const block = parseBlock(parser, context, finalizerScope, privateScope, { $: labels }, parser.tokenIndex, parser.tokenLine, parser.tokenColumn);
|
|
5360
|
+
finalizer = block;
|
|
5372
5361
|
}
|
|
5373
5362
|
if (!handler && !finalizer) {
|
|
5374
5363
|
report(parser, 88);
|
|
@@ -5377,7 +5366,7 @@
|
|
|
5377
5366
|
type: 'TryStatement',
|
|
5378
5367
|
block,
|
|
5379
5368
|
handler,
|
|
5380
|
-
finalizer
|
|
5369
|
+
finalizer,
|
|
5381
5370
|
});
|
|
5382
5371
|
}
|
|
5383
5372
|
function parseCatchBlock(parser, context, scope, privateScope, labels, start, line, column) {
|
|
@@ -5403,7 +5392,7 @@
|
|
|
5403
5392
|
return finishNode(parser, context, start, line, column, {
|
|
5404
5393
|
type: 'CatchClause',
|
|
5405
5394
|
param,
|
|
5406
|
-
body
|
|
5395
|
+
body,
|
|
5407
5396
|
});
|
|
5408
5397
|
}
|
|
5409
5398
|
function parseStaticBlock(parser, context, scope, privateScope, start, line, column) {
|
|
@@ -5416,11 +5405,7 @@
|
|
|
5416
5405
|
524288 |
|
|
5417
5406
|
268435456 |
|
|
5418
5407
|
16777216;
|
|
5419
|
-
|
|
5420
|
-
return finishNode(parser, context, start, line, column, {
|
|
5421
|
-
type: 'StaticBlock',
|
|
5422
|
-
body
|
|
5423
|
-
});
|
|
5408
|
+
return parseBlock(parser, context, scope, privateScope, {}, start, line, column, 'StaticBlock');
|
|
5424
5409
|
}
|
|
5425
5410
|
function parseDoWhileStatement(parser, context, scope, privateScope, labels, start, line, column) {
|
|
5426
5411
|
nextToken(parser, context | 8192);
|
|
@@ -5433,7 +5418,7 @@
|
|
|
5433
5418
|
return finishNode(parser, context, start, line, column, {
|
|
5434
5419
|
type: 'DoWhileStatement',
|
|
5435
5420
|
body,
|
|
5436
|
-
test
|
|
5421
|
+
test,
|
|
5437
5422
|
});
|
|
5438
5423
|
}
|
|
5439
5424
|
function parseLetIdentOrVarDeclarationStatement(parser, context, scope, privateScope, origin, start, line, column) {
|
|
@@ -5446,7 +5431,7 @@
|
|
|
5446
5431
|
return finishNode(parser, context, start, line, column, {
|
|
5447
5432
|
type: 'VariableDeclaration',
|
|
5448
5433
|
kind: 'let',
|
|
5449
|
-
declarations
|
|
5434
|
+
declarations,
|
|
5450
5435
|
});
|
|
5451
5436
|
}
|
|
5452
5437
|
parser.assignable = 1;
|
|
@@ -5478,7 +5463,7 @@
|
|
|
5478
5463
|
return finishNode(parser, context, start, line, column, {
|
|
5479
5464
|
type: 'VariableDeclaration',
|
|
5480
5465
|
kind: kind & 8 ? 'let' : 'const',
|
|
5481
|
-
declarations
|
|
5466
|
+
declarations,
|
|
5482
5467
|
});
|
|
5483
5468
|
}
|
|
5484
5469
|
function parseVariableStatement(parser, context, scope, privateScope, origin, start, line, column) {
|
|
@@ -5488,13 +5473,13 @@
|
|
|
5488
5473
|
return finishNode(parser, context, start, line, column, {
|
|
5489
5474
|
type: 'VariableDeclaration',
|
|
5490
5475
|
kind: 'var',
|
|
5491
|
-
declarations
|
|
5476
|
+
declarations,
|
|
5492
5477
|
});
|
|
5493
5478
|
}
|
|
5494
5479
|
function parseVariableDeclarationList(parser, context, scope, privateScope, kind, origin) {
|
|
5495
5480
|
let bindingCount = 1;
|
|
5496
5481
|
const list = [
|
|
5497
|
-
parseVariableDeclaration(parser, context, scope, privateScope, kind, origin)
|
|
5482
|
+
parseVariableDeclaration(parser, context, scope, privateScope, kind, origin),
|
|
5498
5483
|
];
|
|
5499
5484
|
while (consumeOpt(parser, context, 18)) {
|
|
5500
5485
|
bindingCount++;
|
|
@@ -5528,7 +5513,7 @@
|
|
|
5528
5513
|
return finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
5529
5514
|
type: 'VariableDeclarator',
|
|
5530
5515
|
id,
|
|
5531
|
-
init
|
|
5516
|
+
init,
|
|
5532
5517
|
});
|
|
5533
5518
|
}
|
|
5534
5519
|
function parseForStatement(parser, context, scope, privateScope, labels, start, line, column) {
|
|
@@ -5560,7 +5545,7 @@
|
|
|
5560
5545
|
init = finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
5561
5546
|
type: 'VariableDeclaration',
|
|
5562
5547
|
kind: 'let',
|
|
5563
|
-
declarations: parseVariableDeclarationList(parser, context | 33554432, scope, privateScope, 8, 32)
|
|
5548
|
+
declarations: parseVariableDeclarationList(parser, context | 33554432, scope, privateScope, 8, 32),
|
|
5564
5549
|
});
|
|
5565
5550
|
}
|
|
5566
5551
|
parser.assignable = 1;
|
|
@@ -5582,12 +5567,12 @@
|
|
|
5582
5567
|
? {
|
|
5583
5568
|
type: 'VariableDeclaration',
|
|
5584
5569
|
kind: 'var',
|
|
5585
|
-
declarations: parseVariableDeclarationList(parser, context | 33554432, scope, privateScope, 4, 32)
|
|
5570
|
+
declarations: parseVariableDeclarationList(parser, context | 33554432, scope, privateScope, 4, 32),
|
|
5586
5571
|
}
|
|
5587
5572
|
: {
|
|
5588
5573
|
type: 'VariableDeclaration',
|
|
5589
5574
|
kind: 'const',
|
|
5590
|
-
declarations: parseVariableDeclarationList(parser, context | 33554432, scope, privateScope, 16, 32)
|
|
5575
|
+
declarations: parseVariableDeclarationList(parser, context | 33554432, scope, privateScope, 16, 32),
|
|
5591
5576
|
});
|
|
5592
5577
|
parser.assignable = 1;
|
|
5593
5578
|
}
|
|
@@ -5626,7 +5611,7 @@
|
|
|
5626
5611
|
left: init,
|
|
5627
5612
|
right,
|
|
5628
5613
|
body,
|
|
5629
|
-
await: forAwait
|
|
5614
|
+
await: forAwait,
|
|
5630
5615
|
});
|
|
5631
5616
|
}
|
|
5632
5617
|
if (parser.assignable & 2)
|
|
@@ -5642,7 +5627,7 @@
|
|
|
5642
5627
|
type: 'ForInStatement',
|
|
5643
5628
|
body,
|
|
5644
5629
|
left: init,
|
|
5645
|
-
right
|
|
5630
|
+
right,
|
|
5646
5631
|
});
|
|
5647
5632
|
}
|
|
5648
5633
|
if (forAwait)
|
|
@@ -5668,7 +5653,7 @@
|
|
|
5668
5653
|
init,
|
|
5669
5654
|
test,
|
|
5670
5655
|
update,
|
|
5671
|
-
body
|
|
5656
|
+
body,
|
|
5672
5657
|
});
|
|
5673
5658
|
}
|
|
5674
5659
|
function parseRestrictedIdentifier(parser, context, scope) {
|
|
@@ -5697,8 +5682,8 @@
|
|
|
5697
5682
|
specifiers = [
|
|
5698
5683
|
finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
5699
5684
|
type: 'ImportDefaultSpecifier',
|
|
5700
|
-
local
|
|
5701
|
-
})
|
|
5685
|
+
local,
|
|
5686
|
+
}),
|
|
5702
5687
|
];
|
|
5703
5688
|
if (consumeOpt(parser, context, 18)) {
|
|
5704
5689
|
switch (parser.getToken()) {
|
|
@@ -5731,14 +5716,13 @@
|
|
|
5731
5716
|
}
|
|
5732
5717
|
source = parseModuleSpecifier(parser, context);
|
|
5733
5718
|
}
|
|
5719
|
+
const attributes = parseImportAttributes(parser, context, specifiers);
|
|
5734
5720
|
const node = {
|
|
5735
5721
|
type: 'ImportDeclaration',
|
|
5736
5722
|
specifiers,
|
|
5737
|
-
source
|
|
5723
|
+
source,
|
|
5724
|
+
attributes,
|
|
5738
5725
|
};
|
|
5739
|
-
if (context & 1) {
|
|
5740
|
-
node.attributes = parseImportAttributes(parser, context, specifiers);
|
|
5741
|
-
}
|
|
5742
5726
|
matchOrInsertSemicolon(parser, context | 8192);
|
|
5743
5727
|
return finishNode(parser, context, start, line, column, node);
|
|
5744
5728
|
}
|
|
@@ -5751,7 +5735,7 @@
|
|
|
5751
5735
|
}
|
|
5752
5736
|
return finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
5753
5737
|
type: 'ImportNamespaceSpecifier',
|
|
5754
|
-
local: parseRestrictedIdentifier(parser, context, scope)
|
|
5738
|
+
local: parseRestrictedIdentifier(parser, context, scope),
|
|
5755
5739
|
});
|
|
5756
5740
|
}
|
|
5757
5741
|
function parseModuleSpecifier(parser, context) {
|
|
@@ -5790,7 +5774,7 @@
|
|
|
5790
5774
|
specifiers.push(finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
5791
5775
|
type: 'ImportSpecifier',
|
|
5792
5776
|
local,
|
|
5793
|
-
imported
|
|
5777
|
+
imported,
|
|
5794
5778
|
}));
|
|
5795
5779
|
if (parser.getToken() !== 1074790415)
|
|
5796
5780
|
consume(parser, context, 18);
|
|
@@ -5801,7 +5785,7 @@
|
|
|
5801
5785
|
function parseImportMetaDeclaration(parser, context, start, line, column) {
|
|
5802
5786
|
let expr = parseImportMetaExpression(parser, context, finishNode(parser, context, start, line, column, {
|
|
5803
5787
|
type: 'Identifier',
|
|
5804
|
-
name: 'import'
|
|
5788
|
+
name: 'import',
|
|
5805
5789
|
}), start, line, column);
|
|
5806
5790
|
expr = parseMemberOrUpdateExpression(parser, context, undefined, expr, 0, 0, start, line, column);
|
|
5807
5791
|
expr = parseAssignmentExpression(parser, context, undefined, 0, 0, start, line, column, expr);
|
|
@@ -5826,7 +5810,7 @@
|
|
|
5826
5810
|
const specifiers = [];
|
|
5827
5811
|
let declaration = null;
|
|
5828
5812
|
let source = null;
|
|
5829
|
-
let attributes =
|
|
5813
|
+
let attributes = [];
|
|
5830
5814
|
if (consumeOpt(parser, context | 8192, 20561)) {
|
|
5831
5815
|
switch (parser.getToken()) {
|
|
5832
5816
|
case 86104: {
|
|
@@ -5869,7 +5853,7 @@
|
|
|
5869
5853
|
declareUnboundVariable(parser, 'default');
|
|
5870
5854
|
return finishNode(parser, context, start, line, column, {
|
|
5871
5855
|
type: 'ExportDefaultDeclaration',
|
|
5872
|
-
declaration
|
|
5856
|
+
declaration,
|
|
5873
5857
|
});
|
|
5874
5858
|
}
|
|
5875
5859
|
switch (parser.getToken()) {
|
|
@@ -5886,14 +5870,13 @@
|
|
|
5886
5870
|
if (parser.getToken() !== 134283267)
|
|
5887
5871
|
report(parser, 105, 'Export');
|
|
5888
5872
|
source = parseLiteral(parser, context);
|
|
5873
|
+
const attributes = parseImportAttributes(parser, context);
|
|
5889
5874
|
const node = {
|
|
5890
5875
|
type: 'ExportAllDeclaration',
|
|
5891
5876
|
source,
|
|
5892
|
-
exported
|
|
5877
|
+
exported,
|
|
5878
|
+
attributes,
|
|
5893
5879
|
};
|
|
5894
|
-
if (context & 1) {
|
|
5895
|
-
node.attributes = parseImportAttributes(parser, context);
|
|
5896
|
-
}
|
|
5897
5880
|
matchOrInsertSemicolon(parser, context | 8192);
|
|
5898
5881
|
return finishNode(parser, context, start, line, column, node);
|
|
5899
5882
|
}
|
|
@@ -5930,7 +5913,7 @@
|
|
|
5930
5913
|
specifiers.push(finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
5931
5914
|
type: 'ExportSpecifier',
|
|
5932
5915
|
local,
|
|
5933
|
-
exported
|
|
5916
|
+
exported,
|
|
5934
5917
|
}));
|
|
5935
5918
|
if (parser.getToken() !== 1074790415)
|
|
5936
5919
|
consume(parser, context, 18);
|
|
@@ -5940,9 +5923,7 @@
|
|
|
5940
5923
|
if (parser.getToken() !== 134283267)
|
|
5941
5924
|
report(parser, 105, 'Export');
|
|
5942
5925
|
source = parseLiteral(parser, context);
|
|
5943
|
-
|
|
5944
|
-
attributes = parseImportAttributes(parser, context, specifiers);
|
|
5945
|
-
}
|
|
5926
|
+
attributes = parseImportAttributes(parser, context, specifiers);
|
|
5946
5927
|
if (scope) {
|
|
5947
5928
|
tmpExportedNames.forEach((n) => declareUnboundVariable(parser, n));
|
|
5948
5929
|
}
|
|
@@ -5989,11 +5970,9 @@
|
|
|
5989
5970
|
type: 'ExportNamedDeclaration',
|
|
5990
5971
|
declaration,
|
|
5991
5972
|
specifiers,
|
|
5992
|
-
source
|
|
5973
|
+
source,
|
|
5974
|
+
attributes: attributes,
|
|
5993
5975
|
};
|
|
5994
|
-
if (attributes) {
|
|
5995
|
-
node.attributes = attributes;
|
|
5996
|
-
}
|
|
5997
5976
|
return finishNode(parser, context, start, line, column, node);
|
|
5998
5977
|
}
|
|
5999
5978
|
function parseExpression(parser, context, privateScope, canAssign, inGroup, start, line, column) {
|
|
@@ -6008,7 +5987,7 @@
|
|
|
6008
5987
|
}
|
|
6009
5988
|
return finishNode(parser, context, start, line, column, {
|
|
6010
5989
|
type: 'SequenceExpression',
|
|
6011
|
-
expressions
|
|
5990
|
+
expressions,
|
|
6012
5991
|
});
|
|
6013
5992
|
}
|
|
6014
5993
|
function parseExpressions(parser, context, privateScope, inGroup, canAssign, start, line, column) {
|
|
@@ -6033,13 +6012,13 @@
|
|
|
6033
6012
|
? {
|
|
6034
6013
|
type: 'AssignmentPattern',
|
|
6035
6014
|
left,
|
|
6036
|
-
right
|
|
6015
|
+
right,
|
|
6037
6016
|
}
|
|
6038
6017
|
: {
|
|
6039
6018
|
type: 'AssignmentExpression',
|
|
6040
6019
|
left,
|
|
6041
6020
|
operator: KeywordDescTable[token & 255],
|
|
6042
|
-
right
|
|
6021
|
+
right,
|
|
6043
6022
|
});
|
|
6044
6023
|
}
|
|
6045
6024
|
if ((token & 8388608) === 8388608) {
|
|
@@ -6058,13 +6037,13 @@
|
|
|
6058
6037
|
? {
|
|
6059
6038
|
type: 'AssignmentPattern',
|
|
6060
6039
|
left,
|
|
6061
|
-
right
|
|
6040
|
+
right,
|
|
6062
6041
|
}
|
|
6063
6042
|
: {
|
|
6064
6043
|
type: 'AssignmentExpression',
|
|
6065
6044
|
left,
|
|
6066
6045
|
operator: KeywordDescTable[token & 255],
|
|
6067
|
-
right
|
|
6046
|
+
right,
|
|
6068
6047
|
});
|
|
6069
6048
|
parser.assignable = 2;
|
|
6070
6049
|
return left;
|
|
@@ -6079,28 +6058,28 @@
|
|
|
6079
6058
|
type: 'ConditionalExpression',
|
|
6080
6059
|
test,
|
|
6081
6060
|
consequent,
|
|
6082
|
-
alternate
|
|
6061
|
+
alternate,
|
|
6083
6062
|
});
|
|
6084
6063
|
}
|
|
6085
|
-
function parseBinaryExpression(parser, context, privateScope, inGroup, start, line, column,
|
|
6064
|
+
function parseBinaryExpression(parser, context, privateScope, inGroup, start, line, column, minPrecedence, operator, left) {
|
|
6086
6065
|
const bit = -((context & 33554432) > 0) & 8673330;
|
|
6087
6066
|
let t;
|
|
6088
|
-
let
|
|
6067
|
+
let precedence;
|
|
6089
6068
|
parser.assignable = 2;
|
|
6090
6069
|
while (parser.getToken() & 8388608) {
|
|
6091
6070
|
t = parser.getToken();
|
|
6092
|
-
|
|
6071
|
+
precedence = t & 3840;
|
|
6093
6072
|
if ((t & 524288 && operator & 268435456) || (operator & 524288 && t & 268435456)) {
|
|
6094
6073
|
report(parser, 165);
|
|
6095
6074
|
}
|
|
6096
|
-
if (
|
|
6075
|
+
if (precedence + ((t === 8391735) << 8) - ((bit === t) << 12) <= minPrecedence)
|
|
6097
6076
|
break;
|
|
6098
6077
|
nextToken(parser, context | 8192);
|
|
6099
6078
|
left = finishNode(parser, context, start, line, column, {
|
|
6100
6079
|
type: t & 524288 || t & 268435456 ? 'LogicalExpression' : 'BinaryExpression',
|
|
6101
6080
|
left,
|
|
6102
|
-
right: parseBinaryExpression(parser, context, privateScope, inGroup, parser.tokenIndex, parser.tokenLine, parser.tokenColumn,
|
|
6103
|
-
operator: KeywordDescTable[t & 255]
|
|
6081
|
+
right: parseBinaryExpression(parser, context, privateScope, inGroup, parser.tokenIndex, parser.tokenLine, parser.tokenColumn, precedence, t, parseLeftHandSideExpression(parser, context, privateScope, 0, inGroup, 1, parser.tokenIndex, parser.tokenLine, parser.tokenColumn)),
|
|
6082
|
+
operator: KeywordDescTable[t & 255],
|
|
6104
6083
|
});
|
|
6105
6084
|
}
|
|
6106
6085
|
if (parser.getToken() === 1077936155)
|
|
@@ -6128,7 +6107,7 @@
|
|
|
6128
6107
|
type: 'UnaryExpression',
|
|
6129
6108
|
operator: KeywordDescTable[unaryOperator & 255],
|
|
6130
6109
|
argument: arg,
|
|
6131
|
-
prefix: true
|
|
6110
|
+
prefix: true,
|
|
6132
6111
|
});
|
|
6133
6112
|
}
|
|
6134
6113
|
function parseAsyncExpression(parser, context, privateScope, inGroup, isLHS, canAssign, inNew, start, line, column) {
|
|
@@ -6189,7 +6168,7 @@
|
|
|
6189
6168
|
return finishNode(parser, context, start, line, column, {
|
|
6190
6169
|
type: 'YieldExpression',
|
|
6191
6170
|
argument,
|
|
6192
|
-
delegate
|
|
6171
|
+
delegate,
|
|
6193
6172
|
});
|
|
6194
6173
|
}
|
|
6195
6174
|
if (context & 256)
|
|
@@ -6201,8 +6180,8 @@
|
|
|
6201
6180
|
parser.destructible |= 128;
|
|
6202
6181
|
if (context & 268435456)
|
|
6203
6182
|
report(parser, 177);
|
|
6204
|
-
const
|
|
6205
|
-
const isIdentifier =
|
|
6183
|
+
const possibleIdentifierOrArrowFunc = parseIdentifierOrArrow(parser, context, privateScope, start, line, column);
|
|
6184
|
+
const isIdentifier = possibleIdentifierOrArrowFunc.type === 'ArrowFunctionExpression' ||
|
|
6206
6185
|
(parser.getToken() & 65536) === 0;
|
|
6207
6186
|
if (isIdentifier) {
|
|
6208
6187
|
if (context & 524288)
|
|
@@ -6211,7 +6190,7 @@
|
|
|
6211
6190
|
reportMessageAt(start, line, column, parser.startIndex, parser.startLine, parser.startColumn, 110);
|
|
6212
6191
|
if (context & 2097152 && context & 524288)
|
|
6213
6192
|
reportMessageAt(start, line, column, parser.startIndex, parser.startLine, parser.startColumn, 110);
|
|
6214
|
-
return
|
|
6193
|
+
return possibleIdentifierOrArrowFunc;
|
|
6215
6194
|
}
|
|
6216
6195
|
if (context & 2097152) {
|
|
6217
6196
|
reportMessageAt(start, line, column, parser.startIndex, parser.startLine, parser.startColumn, 31);
|
|
@@ -6225,12 +6204,12 @@
|
|
|
6225
6204
|
parser.assignable = 2;
|
|
6226
6205
|
return finishNode(parser, context, start, line, column, {
|
|
6227
6206
|
type: 'AwaitExpression',
|
|
6228
|
-
argument
|
|
6207
|
+
argument,
|
|
6229
6208
|
});
|
|
6230
6209
|
}
|
|
6231
6210
|
if (context & 512)
|
|
6232
6211
|
reportMessageAt(start, line, column, parser.startIndex, parser.startLine, parser.startColumn, 98);
|
|
6233
|
-
return
|
|
6212
|
+
return possibleIdentifierOrArrowFunc;
|
|
6234
6213
|
}
|
|
6235
6214
|
function parseFunctionBody(parser, context, scope, privateScope, origin, funcNameToken, scopeError) {
|
|
6236
6215
|
const { tokenIndex, tokenLine, tokenColumn } = parser;
|
|
@@ -6285,7 +6264,7 @@
|
|
|
6285
6264
|
report(parser, 26);
|
|
6286
6265
|
return finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
6287
6266
|
type: 'BlockStatement',
|
|
6288
|
-
body
|
|
6267
|
+
body,
|
|
6289
6268
|
});
|
|
6290
6269
|
}
|
|
6291
6270
|
function parseSuperExpression(parser, context, start, line, column) {
|
|
@@ -6325,7 +6304,7 @@
|
|
|
6325
6304
|
type: 'UpdateExpression',
|
|
6326
6305
|
argument: expr,
|
|
6327
6306
|
operator: KeywordDescTable[token & 255],
|
|
6328
|
-
prefix: false
|
|
6307
|
+
prefix: false,
|
|
6329
6308
|
});
|
|
6330
6309
|
}
|
|
6331
6310
|
function parseMemberOrUpdateExpression(parser, context, privateScope, expr, inGroup, inChain, start, line, column) {
|
|
@@ -6346,7 +6325,7 @@
|
|
|
6346
6325
|
type: 'MemberExpression',
|
|
6347
6326
|
object: expr,
|
|
6348
6327
|
computed: false,
|
|
6349
|
-
property
|
|
6328
|
+
property,
|
|
6350
6329
|
});
|
|
6351
6330
|
break;
|
|
6352
6331
|
}
|
|
@@ -6365,7 +6344,7 @@
|
|
|
6365
6344
|
type: 'MemberExpression',
|
|
6366
6345
|
object: expr,
|
|
6367
6346
|
computed: true,
|
|
6368
|
-
property
|
|
6347
|
+
property,
|
|
6369
6348
|
});
|
|
6370
6349
|
if (restoreHasOptionalChaining) {
|
|
6371
6350
|
parser.flags |= 2048;
|
|
@@ -6387,7 +6366,7 @@
|
|
|
6387
6366
|
expr = finishNode(parser, context, start, line, column, {
|
|
6388
6367
|
type: 'CallExpression',
|
|
6389
6368
|
callee: expr,
|
|
6390
|
-
arguments: args
|
|
6369
|
+
arguments: args,
|
|
6391
6370
|
});
|
|
6392
6371
|
if (restoreHasOptionalChaining) {
|
|
6393
6372
|
parser.flags |= 2048;
|
|
@@ -6411,7 +6390,7 @@
|
|
|
6411
6390
|
tag: expr,
|
|
6412
6391
|
quasi: parser.getToken() === 67174408
|
|
6413
6392
|
? parseTemplate(parser, context | 16384, privateScope)
|
|
6414
|
-
: parseTemplateLiteral(parser, context, parser.tokenIndex, parser.tokenLine, parser.tokenColumn)
|
|
6393
|
+
: parseTemplateLiteral(parser, context, parser.tokenIndex, parser.tokenLine, parser.tokenColumn),
|
|
6415
6394
|
});
|
|
6416
6395
|
}
|
|
6417
6396
|
expr = parseMemberOrUpdateExpression(parser, context, privateScope, expr, 0, 1, start, line, column);
|
|
@@ -6420,7 +6399,7 @@
|
|
|
6420
6399
|
parser.flags = (parser.flags | 2048) ^ 2048;
|
|
6421
6400
|
expr = finishNode(parser, context, start, line, column, {
|
|
6422
6401
|
type: 'ChainExpression',
|
|
6423
|
-
expression: expr
|
|
6402
|
+
expression: expr,
|
|
6424
6403
|
});
|
|
6425
6404
|
}
|
|
6426
6405
|
return expr;
|
|
@@ -6445,7 +6424,7 @@
|
|
|
6445
6424
|
object: expr,
|
|
6446
6425
|
computed: true,
|
|
6447
6426
|
optional: true,
|
|
6448
|
-
property
|
|
6427
|
+
property,
|
|
6449
6428
|
});
|
|
6450
6429
|
}
|
|
6451
6430
|
else if (parser.getToken() === 67174411) {
|
|
@@ -6455,7 +6434,7 @@
|
|
|
6455
6434
|
type: 'CallExpression',
|
|
6456
6435
|
callee: expr,
|
|
6457
6436
|
arguments: args,
|
|
6458
|
-
optional: true
|
|
6437
|
+
optional: true,
|
|
6459
6438
|
});
|
|
6460
6439
|
}
|
|
6461
6440
|
else {
|
|
@@ -6466,7 +6445,7 @@
|
|
|
6466
6445
|
object: expr,
|
|
6467
6446
|
computed: false,
|
|
6468
6447
|
optional: true,
|
|
6469
|
-
property
|
|
6448
|
+
property,
|
|
6470
6449
|
});
|
|
6471
6450
|
}
|
|
6472
6451
|
if (restoreHasOptionalChaining) {
|
|
@@ -6501,7 +6480,7 @@
|
|
|
6501
6480
|
type: 'UpdateExpression',
|
|
6502
6481
|
argument: arg,
|
|
6503
6482
|
operator: KeywordDescTable[token & 255],
|
|
6504
|
-
prefix: true
|
|
6483
|
+
prefix: true,
|
|
6505
6484
|
});
|
|
6506
6485
|
}
|
|
6507
6486
|
function parsePrimaryExpression(parser, context, privateScope, kind, inNew, canAssign, inGroup, isLHS, start, line, column) {
|
|
@@ -6626,7 +6605,7 @@
|
|
|
6626
6605
|
return finishNode(parser, context, start, line, column, {
|
|
6627
6606
|
type: 'MetaProperty',
|
|
6628
6607
|
meta,
|
|
6629
|
-
property: parseIdentifier(parser, context)
|
|
6608
|
+
property: parseIdentifier(parser, context),
|
|
6630
6609
|
});
|
|
6631
6610
|
}
|
|
6632
6611
|
function parseImportExpression(parser, context, privateScope, inGroup, start, line, column) {
|
|
@@ -6634,22 +6613,20 @@
|
|
|
6634
6613
|
if (parser.getToken() === 14)
|
|
6635
6614
|
report(parser, 143);
|
|
6636
6615
|
const source = parseExpression(parser, context, privateScope, 1, inGroup, parser.tokenIndex, parser.tokenLine, parser.tokenColumn);
|
|
6637
|
-
|
|
6638
|
-
|
|
6639
|
-
|
|
6640
|
-
|
|
6641
|
-
|
|
6642
|
-
|
|
6643
|
-
if (parser.getToken() === 18) {
|
|
6644
|
-
consume(parser, context, 18);
|
|
6645
|
-
if (parser.getToken() !== 16) {
|
|
6646
|
-
const expContext = (context | 33554432) ^ 33554432;
|
|
6647
|
-
options = parseExpression(parser, expContext, privateScope, 1, inGroup, parser.tokenIndex, parser.tokenLine, parser.tokenColumn);
|
|
6648
|
-
}
|
|
6616
|
+
let options = null;
|
|
6617
|
+
if (parser.getToken() === 18) {
|
|
6618
|
+
consume(parser, context, 18);
|
|
6619
|
+
if (parser.getToken() !== 16) {
|
|
6620
|
+
const expContext = (context | 33554432) ^ 33554432;
|
|
6621
|
+
options = parseExpression(parser, expContext, privateScope, 1, inGroup, parser.tokenIndex, parser.tokenLine, parser.tokenColumn);
|
|
6649
6622
|
}
|
|
6650
|
-
node.options = options;
|
|
6651
6623
|
consumeOpt(parser, context, 18);
|
|
6652
6624
|
}
|
|
6625
|
+
const node = {
|
|
6626
|
+
type: 'ImportExpression',
|
|
6627
|
+
source,
|
|
6628
|
+
options,
|
|
6629
|
+
};
|
|
6653
6630
|
consume(parser, context, 16);
|
|
6654
6631
|
return finishNode(parser, context, start, line, column, node);
|
|
6655
6632
|
}
|
|
@@ -6689,7 +6666,7 @@
|
|
|
6689
6666
|
attributes.push(finishNode(parser, context, start, line, column, {
|
|
6690
6667
|
type: 'ImportAttribute',
|
|
6691
6668
|
key,
|
|
6692
|
-
value
|
|
6669
|
+
value,
|
|
6693
6670
|
}));
|
|
6694
6671
|
if (parser.getToken() !== 1074790415) {
|
|
6695
6672
|
consume(parser, context, 18);
|
|
@@ -6744,30 +6721,27 @@
|
|
|
6744
6721
|
const { tokenRaw, tokenValue } = parser;
|
|
6745
6722
|
nextToken(parser, context);
|
|
6746
6723
|
parser.assignable = 2;
|
|
6747
|
-
|
|
6748
|
-
|
|
6749
|
-
|
|
6750
|
-
|
|
6751
|
-
|
|
6752
|
-
|
|
6753
|
-
|
|
6754
|
-
|
|
6755
|
-
|
|
6756
|
-
value: tokenValue,
|
|
6757
|
-
bigint: tokenRaw.slice(0, -1)
|
|
6758
|
-
});
|
|
6724
|
+
const node = {
|
|
6725
|
+
type: 'Literal',
|
|
6726
|
+
value: tokenValue,
|
|
6727
|
+
bigint: String(tokenValue),
|
|
6728
|
+
};
|
|
6729
|
+
if (context & 128) {
|
|
6730
|
+
node.raw = tokenRaw;
|
|
6731
|
+
}
|
|
6732
|
+
return finishNode(parser, context, start, line, column, node);
|
|
6759
6733
|
}
|
|
6760
6734
|
function parseTemplateLiteral(parser, context, start, line, column) {
|
|
6761
6735
|
parser.assignable = 2;
|
|
6762
6736
|
const { tokenValue, tokenRaw, tokenIndex, tokenLine, tokenColumn } = parser;
|
|
6763
6737
|
consume(parser, context, 67174409);
|
|
6764
6738
|
const quasis = [
|
|
6765
|
-
parseTemplateElement(parser, context, tokenValue, tokenRaw, tokenIndex, tokenLine, tokenColumn, true)
|
|
6739
|
+
parseTemplateElement(parser, context, tokenValue, tokenRaw, tokenIndex, tokenLine, tokenColumn, true),
|
|
6766
6740
|
];
|
|
6767
6741
|
return finishNode(parser, context, start, line, column, {
|
|
6768
6742
|
type: 'TemplateLiteral',
|
|
6769
6743
|
expressions: [],
|
|
6770
|
-
quasis
|
|
6744
|
+
quasis,
|
|
6771
6745
|
});
|
|
6772
6746
|
}
|
|
6773
6747
|
function parseTemplate(parser, context, privateScope) {
|
|
@@ -6775,10 +6749,10 @@
|
|
|
6775
6749
|
const { tokenValue, tokenRaw, tokenIndex, tokenLine, tokenColumn } = parser;
|
|
6776
6750
|
consume(parser, (context & -16385) | 8192, 67174408);
|
|
6777
6751
|
const quasis = [
|
|
6778
|
-
parseTemplateElement(parser, context, tokenValue, tokenRaw, tokenIndex, tokenLine, tokenColumn, false)
|
|
6752
|
+
parseTemplateElement(parser, context, tokenValue, tokenRaw, tokenIndex, tokenLine, tokenColumn, false),
|
|
6779
6753
|
];
|
|
6780
6754
|
const expressions = [
|
|
6781
|
-
parseExpressions(parser, context & -16385, privateScope, 0, 1, parser.tokenIndex, parser.tokenLine, parser.tokenColumn)
|
|
6755
|
+
parseExpressions(parser, context & -16385, privateScope, 0, 1, parser.tokenIndex, parser.tokenLine, parser.tokenColumn),
|
|
6782
6756
|
];
|
|
6783
6757
|
if (parser.getToken() !== 1074790415)
|
|
6784
6758
|
report(parser, 83);
|
|
@@ -6798,7 +6772,7 @@
|
|
|
6798
6772
|
return finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
6799
6773
|
type: 'TemplateLiteral',
|
|
6800
6774
|
expressions,
|
|
6801
|
-
quasis
|
|
6775
|
+
quasis,
|
|
6802
6776
|
});
|
|
6803
6777
|
}
|
|
6804
6778
|
function parseTemplateElement(parser, context, cooked, raw, start, line, col, tail) {
|
|
@@ -6806,9 +6780,9 @@
|
|
|
6806
6780
|
type: 'TemplateElement',
|
|
6807
6781
|
value: {
|
|
6808
6782
|
cooked,
|
|
6809
|
-
raw
|
|
6783
|
+
raw,
|
|
6810
6784
|
},
|
|
6811
|
-
tail
|
|
6785
|
+
tail,
|
|
6812
6786
|
});
|
|
6813
6787
|
const tailSize = tail ? 1 : 2;
|
|
6814
6788
|
if (context & 2) {
|
|
@@ -6830,7 +6804,7 @@
|
|
|
6830
6804
|
parser.assignable = 1;
|
|
6831
6805
|
return finishNode(parser, context, start, line, column, {
|
|
6832
6806
|
type: 'SpreadElement',
|
|
6833
|
-
argument
|
|
6807
|
+
argument,
|
|
6834
6808
|
});
|
|
6835
6809
|
}
|
|
6836
6810
|
function parseArguments(parser, context, privateScope, inGroup) {
|
|
@@ -6862,7 +6836,7 @@
|
|
|
6862
6836
|
nextToken(parser, context | (allowRegex ? 8192 : 0));
|
|
6863
6837
|
return finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
6864
6838
|
type: 'Identifier',
|
|
6865
|
-
name: tokenValue
|
|
6839
|
+
name: tokenValue,
|
|
6866
6840
|
});
|
|
6867
6841
|
}
|
|
6868
6842
|
function parseLiteral(parser, context) {
|
|
@@ -6876,11 +6850,11 @@
|
|
|
6876
6850
|
? {
|
|
6877
6851
|
type: 'Literal',
|
|
6878
6852
|
value: tokenValue,
|
|
6879
|
-
raw: tokenRaw
|
|
6853
|
+
raw: tokenRaw,
|
|
6880
6854
|
}
|
|
6881
6855
|
: {
|
|
6882
6856
|
type: 'Literal',
|
|
6883
|
-
value: tokenValue
|
|
6857
|
+
value: tokenValue,
|
|
6884
6858
|
});
|
|
6885
6859
|
}
|
|
6886
6860
|
function parseNullOrTrueOrFalseLiteral(parser, context, start, line, column) {
|
|
@@ -6892,11 +6866,11 @@
|
|
|
6892
6866
|
? {
|
|
6893
6867
|
type: 'Literal',
|
|
6894
6868
|
value,
|
|
6895
|
-
raw
|
|
6869
|
+
raw,
|
|
6896
6870
|
}
|
|
6897
6871
|
: {
|
|
6898
6872
|
type: 'Literal',
|
|
6899
|
-
value
|
|
6873
|
+
value,
|
|
6900
6874
|
});
|
|
6901
6875
|
}
|
|
6902
6876
|
function parseThisExpression(parser, context) {
|
|
@@ -6904,7 +6878,7 @@
|
|
|
6904
6878
|
nextToken(parser, context);
|
|
6905
6879
|
parser.assignable = 2;
|
|
6906
6880
|
return finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
6907
|
-
type: 'ThisExpression'
|
|
6881
|
+
type: 'ThisExpression',
|
|
6908
6882
|
});
|
|
6909
6883
|
}
|
|
6910
6884
|
function parseFunctionDeclaration(parser, context, scope, privateScope, origin, allowGen, flags, isAsync, start, line, column) {
|
|
@@ -6944,30 +6918,32 @@
|
|
|
6944
6918
|
report(parser, 30, KeywordDescTable[parser.getToken() & 255]);
|
|
6945
6919
|
}
|
|
6946
6920
|
}
|
|
6947
|
-
|
|
6948
|
-
|
|
6949
|
-
|
|
6950
|
-
|
|
6951
|
-
|
|
6952
|
-
|
|
6953
|
-
|
|
6954
|
-
|
|
6955
|
-
|
|
6956
|
-
|
|
6957
|
-
|
|
6958
|
-
|
|
6921
|
+
{
|
|
6922
|
+
const modifierFlags = 65536 |
|
|
6923
|
+
131072 |
|
|
6924
|
+
262144 |
|
|
6925
|
+
524288 |
|
|
6926
|
+
2097152 |
|
|
6927
|
+
4194304;
|
|
6928
|
+
context =
|
|
6929
|
+
((context | modifierFlags) ^ modifierFlags) |
|
|
6930
|
+
16777216 |
|
|
6931
|
+
(isAsync ? 524288 : 0) |
|
|
6932
|
+
(isGenerator ? 262144 : 0) |
|
|
6933
|
+
(isGenerator ? 0 : 67108864);
|
|
6934
|
+
}
|
|
6959
6935
|
if (scope)
|
|
6960
6936
|
functionScope = addChildScope(functionScope, 512);
|
|
6961
6937
|
const params = parseFormalParametersOrFormalList(parser, (context | 2097152) & -268435457, functionScope, privateScope, 0, 1);
|
|
6962
|
-
const
|
|
6963
|
-
const body = parseFunctionBody(parser, ((context |
|
|
6938
|
+
const modifierFlags = 2048 | 1024 | 32768 | 268435456;
|
|
6939
|
+
const body = parseFunctionBody(parser, ((context | modifierFlags) ^ modifierFlags) | 8388608 | 1048576, scope ? addChildScope(functionScope, 128) : functionScope, privateScope, 8, funcNameToken, functionScope?.scopeError);
|
|
6964
6940
|
return finishNode(parser, context, start, line, column, {
|
|
6965
6941
|
type: 'FunctionDeclaration',
|
|
6966
6942
|
id,
|
|
6967
6943
|
params,
|
|
6968
6944
|
body,
|
|
6969
6945
|
async: isAsync === 1,
|
|
6970
|
-
generator: isGenerator === 1
|
|
6946
|
+
generator: isGenerator === 1,
|
|
6971
6947
|
});
|
|
6972
6948
|
}
|
|
6973
6949
|
function parseFunctionExpression(parser, context, privateScope, isAsync, inGroup, start, line, column) {
|
|
@@ -7009,7 +6985,7 @@
|
|
|
7009
6985
|
params,
|
|
7010
6986
|
body,
|
|
7011
6987
|
async: isAsync === 1,
|
|
7012
|
-
generator: isGenerator === 1
|
|
6988
|
+
generator: isGenerator === 1,
|
|
7013
6989
|
});
|
|
7014
6990
|
}
|
|
7015
6991
|
function parseArrayLiteral(parser, context, privateScope, skipInitializer, inGroup, start, line, column) {
|
|
@@ -7048,13 +7024,13 @@
|
|
|
7048
7024
|
? {
|
|
7049
7025
|
type: 'AssignmentPattern',
|
|
7050
7026
|
left,
|
|
7051
|
-
right
|
|
7027
|
+
right,
|
|
7052
7028
|
}
|
|
7053
7029
|
: {
|
|
7054
7030
|
type: 'AssignmentExpression',
|
|
7055
7031
|
operator: '=',
|
|
7056
7032
|
left,
|
|
7057
|
-
right
|
|
7033
|
+
right,
|
|
7058
7034
|
});
|
|
7059
7035
|
destructible |=
|
|
7060
7036
|
parser.destructible & 256
|
|
@@ -7165,7 +7141,7 @@
|
|
|
7165
7141
|
consume(parser, context, 20);
|
|
7166
7142
|
const node = finishNode(parser, context, start, line, column, {
|
|
7167
7143
|
type: isPattern ? 'ArrayPattern' : 'ArrayExpression',
|
|
7168
|
-
elements
|
|
7144
|
+
elements,
|
|
7169
7145
|
});
|
|
7170
7146
|
if (!skipInitializer && parser.getToken() & 4194304) {
|
|
7171
7147
|
return parseArrayOrObjectAssignmentPattern(parser, context, privateScope, destructible, inGroup, isPattern, start, line, column, node);
|
|
@@ -7192,13 +7168,13 @@
|
|
|
7192
7168
|
? {
|
|
7193
7169
|
type: 'AssignmentPattern',
|
|
7194
7170
|
left: node,
|
|
7195
|
-
right
|
|
7171
|
+
right,
|
|
7196
7172
|
}
|
|
7197
7173
|
: {
|
|
7198
7174
|
type: 'AssignmentExpression',
|
|
7199
7175
|
left: node,
|
|
7200
7176
|
operator: '=',
|
|
7201
|
-
right
|
|
7177
|
+
right,
|
|
7202
7178
|
});
|
|
7203
7179
|
}
|
|
7204
7180
|
function parseSpreadOrRestElement(parser, context, scope, privateScope, closingToken, kind, origin, isAsync, inGroup, isPattern, start, line, column) {
|
|
@@ -7295,7 +7271,7 @@
|
|
|
7295
7271
|
report(parser, 161);
|
|
7296
7272
|
return finishNode(parser, context, start, line, column, {
|
|
7297
7273
|
type: isPattern ? 'RestElement' : 'SpreadElement',
|
|
7298
|
-
argument: argument
|
|
7274
|
+
argument: argument,
|
|
7299
7275
|
});
|
|
7300
7276
|
}
|
|
7301
7277
|
if (parser.getToken() !== closingToken) {
|
|
@@ -7310,13 +7286,13 @@
|
|
|
7310
7286
|
? {
|
|
7311
7287
|
type: 'AssignmentPattern',
|
|
7312
7288
|
left: argument,
|
|
7313
|
-
right
|
|
7289
|
+
right,
|
|
7314
7290
|
}
|
|
7315
7291
|
: {
|
|
7316
7292
|
type: 'AssignmentExpression',
|
|
7317
7293
|
left: argument,
|
|
7318
7294
|
operator: '=',
|
|
7319
|
-
right
|
|
7295
|
+
right,
|
|
7320
7296
|
});
|
|
7321
7297
|
destructible = 16;
|
|
7322
7298
|
}
|
|
@@ -7327,7 +7303,7 @@
|
|
|
7327
7303
|
parser.destructible = destructible;
|
|
7328
7304
|
return finishNode(parser, context, start, line, column, {
|
|
7329
7305
|
type: isPattern ? 'RestElement' : 'SpreadElement',
|
|
7330
|
-
argument: argument
|
|
7306
|
+
argument: argument,
|
|
7331
7307
|
});
|
|
7332
7308
|
}
|
|
7333
7309
|
function parseMethodDefinition(parser, context, privateScope, kind, inGroup, start, line, column) {
|
|
@@ -7356,7 +7332,7 @@
|
|
|
7356
7332
|
body,
|
|
7357
7333
|
async: (kind & 16) > 0,
|
|
7358
7334
|
generator: (kind & 8) > 0,
|
|
7359
|
-
id: null
|
|
7335
|
+
id: null,
|
|
7360
7336
|
});
|
|
7361
7337
|
}
|
|
7362
7338
|
function parseObjectLiteral(parser, context, privateScope, skipInitializer, inGroup, start, line, column) {
|
|
@@ -7415,7 +7391,7 @@
|
|
|
7415
7391
|
value = finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
7416
7392
|
type: 'AssignmentPattern',
|
|
7417
7393
|
left: context & 134217728 ? Object.assign({}, key) : key,
|
|
7418
|
-
right
|
|
7394
|
+
right,
|
|
7419
7395
|
});
|
|
7420
7396
|
}
|
|
7421
7397
|
else {
|
|
@@ -7876,7 +7852,7 @@
|
|
|
7876
7852
|
kind: !(state & 768) ? 'init' : state & 512 ? 'set' : 'get',
|
|
7877
7853
|
computed: (state & 2) > 0,
|
|
7878
7854
|
method: (state & 1) > 0,
|
|
7879
|
-
shorthand: (state & 4) > 0
|
|
7855
|
+
shorthand: (state & 4) > 0,
|
|
7880
7856
|
}));
|
|
7881
7857
|
}
|
|
7882
7858
|
destructible |= parser.destructible;
|
|
@@ -7889,7 +7865,7 @@
|
|
|
7889
7865
|
destructible |= 64;
|
|
7890
7866
|
const node = finishNode(parser, context, start, line, column, {
|
|
7891
7867
|
type: isPattern ? 'ObjectPattern' : 'ObjectExpression',
|
|
7892
|
-
properties
|
|
7868
|
+
properties,
|
|
7893
7869
|
});
|
|
7894
7870
|
if (!skipInitializer && parser.getToken() & 4194304) {
|
|
7895
7871
|
return parseArrayOrObjectAssignmentPattern(parser, context, privateScope, destructible, inGroup, isPattern, start, line, column, node);
|
|
@@ -7952,7 +7928,7 @@
|
|
|
7952
7928
|
left = finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
7953
7929
|
type: 'AssignmentPattern',
|
|
7954
7930
|
left: left,
|
|
7955
|
-
right
|
|
7931
|
+
right,
|
|
7956
7932
|
});
|
|
7957
7933
|
}
|
|
7958
7934
|
setterArgs++;
|
|
@@ -8077,12 +8053,17 @@
|
|
|
8077
8053
|
parser.assignable = 2;
|
|
8078
8054
|
expr = finishNode(parser, context, iStart, lStart, cStart, {
|
|
8079
8055
|
type: 'SequenceExpression',
|
|
8080
|
-
expressions
|
|
8056
|
+
expressions,
|
|
8081
8057
|
});
|
|
8082
8058
|
}
|
|
8083
8059
|
consume(parser, context, 16);
|
|
8084
8060
|
parser.destructible = destructible;
|
|
8085
|
-
return
|
|
8061
|
+
return context & 32
|
|
8062
|
+
? finishNode(parser, context, piStart, plStart, pcStart, {
|
|
8063
|
+
type: 'ParenthesizedExpression',
|
|
8064
|
+
expression: expr,
|
|
8065
|
+
})
|
|
8066
|
+
: expr;
|
|
8086
8067
|
}
|
|
8087
8068
|
if (isSequence && (parser.getToken() === 16 || parser.getToken() === 18)) {
|
|
8088
8069
|
expressions.push(expr);
|
|
@@ -8102,7 +8083,7 @@
|
|
|
8102
8083
|
parser.assignable = 2;
|
|
8103
8084
|
expr = finishNode(parser, context, iStart, lStart, cStart, {
|
|
8104
8085
|
type: 'SequenceExpression',
|
|
8105
|
-
expressions
|
|
8086
|
+
expressions,
|
|
8106
8087
|
});
|
|
8107
8088
|
}
|
|
8108
8089
|
consume(parser, context, 16);
|
|
@@ -8138,7 +8119,7 @@
|
|
|
8138
8119
|
return context & 32
|
|
8139
8120
|
? finishNode(parser, context, piStart, plStart, pcStart, {
|
|
8140
8121
|
type: 'ParenthesizedExpression',
|
|
8141
|
-
expression: expr
|
|
8122
|
+
expression: expr,
|
|
8142
8123
|
})
|
|
8143
8124
|
: expr;
|
|
8144
8125
|
}
|
|
@@ -8231,7 +8212,8 @@
|
|
|
8231
8212
|
params,
|
|
8232
8213
|
body,
|
|
8233
8214
|
async: isAsync === 1,
|
|
8234
|
-
expression
|
|
8215
|
+
expression,
|
|
8216
|
+
generator: false,
|
|
8235
8217
|
});
|
|
8236
8218
|
}
|
|
8237
8219
|
function parseFormalParametersOrFormalList(parser, context, scope, privateScope, inGroup, kind) {
|
|
@@ -8282,7 +8264,7 @@
|
|
|
8282
8264
|
left = finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
8283
8265
|
type: 'AssignmentPattern',
|
|
8284
8266
|
left,
|
|
8285
|
-
right
|
|
8267
|
+
right,
|
|
8286
8268
|
});
|
|
8287
8269
|
}
|
|
8288
8270
|
params.push(left);
|
|
@@ -8300,18 +8282,18 @@
|
|
|
8300
8282
|
consume(parser, context, 16);
|
|
8301
8283
|
return params;
|
|
8302
8284
|
}
|
|
8303
|
-
function
|
|
8285
|
+
function parseMemberExpressionNoCall(parser, context, privateScope, expr, inGroup, start, line, column) {
|
|
8304
8286
|
const token = parser.getToken();
|
|
8305
8287
|
if (token & 67108864) {
|
|
8306
8288
|
if (token === 67108877) {
|
|
8307
8289
|
nextToken(parser, context | 67108864);
|
|
8308
8290
|
parser.assignable = 1;
|
|
8309
8291
|
const property = parsePropertyOrPrivatePropertyName(parser, context, privateScope);
|
|
8310
|
-
return
|
|
8292
|
+
return parseMemberExpressionNoCall(parser, context, privateScope, finishNode(parser, context, start, line, column, {
|
|
8311
8293
|
type: 'MemberExpression',
|
|
8312
8294
|
object: expr,
|
|
8313
8295
|
computed: false,
|
|
8314
|
-
property
|
|
8296
|
+
property,
|
|
8315
8297
|
}), 0, start, line, column);
|
|
8316
8298
|
}
|
|
8317
8299
|
else if (token === 69271571) {
|
|
@@ -8320,21 +8302,21 @@
|
|
|
8320
8302
|
const property = parseExpressions(parser, context, privateScope, inGroup, 1, tokenIndex, tokenLine, tokenColumn);
|
|
8321
8303
|
consume(parser, context, 20);
|
|
8322
8304
|
parser.assignable = 1;
|
|
8323
|
-
return
|
|
8305
|
+
return parseMemberExpressionNoCall(parser, context, privateScope, finishNode(parser, context, start, line, column, {
|
|
8324
8306
|
type: 'MemberExpression',
|
|
8325
8307
|
object: expr,
|
|
8326
8308
|
computed: true,
|
|
8327
|
-
property
|
|
8309
|
+
property,
|
|
8328
8310
|
}), 0, start, line, column);
|
|
8329
8311
|
}
|
|
8330
8312
|
else if (token === 67174408 || token === 67174409) {
|
|
8331
8313
|
parser.assignable = 2;
|
|
8332
|
-
return
|
|
8314
|
+
return parseMemberExpressionNoCall(parser, context, privateScope, finishNode(parser, context, start, line, column, {
|
|
8333
8315
|
type: 'TaggedTemplateExpression',
|
|
8334
8316
|
tag: expr,
|
|
8335
8317
|
quasi: parser.getToken() === 67174408
|
|
8336
8318
|
? parseTemplate(parser, context | 16384, privateScope)
|
|
8337
|
-
: parseTemplateLiteral(parser, context | 16384, parser.tokenIndex, parser.tokenLine, parser.tokenColumn)
|
|
8319
|
+
: parseTemplateLiteral(parser, context | 16384, parser.tokenIndex, parser.tokenLine, parser.tokenColumn),
|
|
8338
8320
|
}), 0, start, line, column);
|
|
8339
8321
|
}
|
|
8340
8322
|
}
|
|
@@ -8358,12 +8340,12 @@
|
|
|
8358
8340
|
context = (context | 33554432) ^ 33554432;
|
|
8359
8341
|
if (parser.getToken() === 67108990)
|
|
8360
8342
|
report(parser, 168);
|
|
8361
|
-
const callee =
|
|
8343
|
+
const callee = parseMemberExpressionNoCall(parser, context, privateScope, expr, inGroup, tokenIndex, tokenLine, tokenColumn);
|
|
8362
8344
|
parser.assignable = 2;
|
|
8363
8345
|
return finishNode(parser, context, start, line, column, {
|
|
8364
8346
|
type: 'NewExpression',
|
|
8365
8347
|
callee,
|
|
8366
|
-
arguments: parser.getToken() === 67174411 ? parseArguments(parser, context, privateScope, inGroup) : []
|
|
8348
|
+
arguments: parser.getToken() === 67174411 ? parseArguments(parser, context, privateScope, inGroup) : [],
|
|
8367
8349
|
});
|
|
8368
8350
|
}
|
|
8369
8351
|
function parseMetaProperty(parser, context, meta, start, line, column) {
|
|
@@ -8371,7 +8353,7 @@
|
|
|
8371
8353
|
return finishNode(parser, context, start, line, column, {
|
|
8372
8354
|
type: 'MetaProperty',
|
|
8373
8355
|
meta,
|
|
8374
|
-
property
|
|
8356
|
+
property,
|
|
8375
8357
|
});
|
|
8376
8358
|
}
|
|
8377
8359
|
function parseAsyncArrowAfterIdent(parser, context, privateScope, canAssign, start, line, column) {
|
|
@@ -8399,7 +8381,7 @@
|
|
|
8399
8381
|
return finishNode(parser, context, start, line, column, {
|
|
8400
8382
|
type: 'CallExpression',
|
|
8401
8383
|
callee,
|
|
8402
|
-
arguments: []
|
|
8384
|
+
arguments: [],
|
|
8403
8385
|
});
|
|
8404
8386
|
}
|
|
8405
8387
|
let destructible = 0;
|
|
@@ -8481,7 +8463,7 @@
|
|
|
8481
8463
|
return finishNode(parser, context, start, line, column, {
|
|
8482
8464
|
type: 'CallExpression',
|
|
8483
8465
|
callee,
|
|
8484
|
-
arguments: params
|
|
8466
|
+
arguments: params,
|
|
8485
8467
|
});
|
|
8486
8468
|
}
|
|
8487
8469
|
params.push(expr);
|
|
@@ -8518,7 +8500,7 @@
|
|
|
8518
8500
|
return finishNode(parser, context, start, line, column, {
|
|
8519
8501
|
type: 'CallExpression',
|
|
8520
8502
|
callee,
|
|
8521
|
-
arguments: params
|
|
8503
|
+
arguments: params,
|
|
8522
8504
|
});
|
|
8523
8505
|
}
|
|
8524
8506
|
function parseRegExpLiteral(parser, context, start, line, column) {
|
|
@@ -8530,12 +8512,12 @@
|
|
|
8530
8512
|
type: 'Literal',
|
|
8531
8513
|
value: tokenValue,
|
|
8532
8514
|
regex: tokenRegExp,
|
|
8533
|
-
raw: tokenRaw
|
|
8515
|
+
raw: tokenRaw,
|
|
8534
8516
|
})
|
|
8535
8517
|
: finishNode(parser, context, start, line, column, {
|
|
8536
8518
|
type: 'Literal',
|
|
8537
8519
|
value: tokenValue,
|
|
8538
|
-
regex: tokenRegExp
|
|
8520
|
+
regex: tokenRegExp,
|
|
8539
8521
|
});
|
|
8540
8522
|
}
|
|
8541
8523
|
function parseClassDeclaration(parser, context, scope, privateScope, flags, start, line, column) {
|
|
@@ -8590,7 +8572,7 @@
|
|
|
8590
8572
|
id,
|
|
8591
8573
|
superClass,
|
|
8592
8574
|
body,
|
|
8593
|
-
...(context & 1 ? { decorators } : null)
|
|
8575
|
+
...(context & 1 ? { decorators } : null),
|
|
8594
8576
|
});
|
|
8595
8577
|
}
|
|
8596
8578
|
function parseClassExpression(parser, context, privateScope, inGroup, start, line, column) {
|
|
@@ -8627,7 +8609,7 @@
|
|
|
8627
8609
|
id,
|
|
8628
8610
|
superClass,
|
|
8629
8611
|
body,
|
|
8630
|
-
...(context & 1 ? { decorators } : null)
|
|
8612
|
+
...(context & 1 ? { decorators } : null),
|
|
8631
8613
|
});
|
|
8632
8614
|
}
|
|
8633
8615
|
function parseDecorators(parser, context, privateScope) {
|
|
@@ -8645,7 +8627,7 @@
|
|
|
8645
8627
|
expression = parseMemberOrUpdateExpression(parser, context, privateScope, expression, 0, 0, start, line, column);
|
|
8646
8628
|
return finishNode(parser, context, start, line, column, {
|
|
8647
8629
|
type: 'Decorator',
|
|
8648
|
-
expression
|
|
8630
|
+
expression,
|
|
8649
8631
|
});
|
|
8650
8632
|
}
|
|
8651
8633
|
function parseClassBody(parser, context, inheritedContext, scope, parentScope, kind, origin, inGroup) {
|
|
@@ -8680,7 +8662,7 @@
|
|
|
8680
8662
|
parser.flags = (parser.flags & -33) | hasConstr;
|
|
8681
8663
|
return finishNode(parser, context, tokenIndex, tokenLine, tokenColumn, {
|
|
8682
8664
|
type: 'ClassBody',
|
|
8683
|
-
body
|
|
8665
|
+
body,
|
|
8684
8666
|
});
|
|
8685
8667
|
}
|
|
8686
8668
|
function parseClassElementList(parser, context, scope, privateScope, inheritedContext, type, decorators, isStatic, inGroup, start, line, column) {
|
|
@@ -8753,7 +8735,7 @@
|
|
|
8753
8735
|
kind |= 128;
|
|
8754
8736
|
}
|
|
8755
8737
|
else if (isStatic && token === 2162700) {
|
|
8756
|
-
return parseStaticBlock(parser, context | 4096, scope, privateScope,
|
|
8738
|
+
return parseStaticBlock(parser, context | 4096, scope, privateScope, start, line, column);
|
|
8757
8739
|
}
|
|
8758
8740
|
else if (token === -2147483527) {
|
|
8759
8741
|
key = parseIdentifier(parser, context);
|
|
@@ -8824,7 +8806,7 @@
|
|
|
8824
8806
|
computed: (kind & 2) > 0,
|
|
8825
8807
|
key,
|
|
8826
8808
|
value,
|
|
8827
|
-
...(context & 1 ? { decorators } : null)
|
|
8809
|
+
...(context & 1 ? { decorators } : null),
|
|
8828
8810
|
});
|
|
8829
8811
|
}
|
|
8830
8812
|
function parsePrivateIdentifier(parser, context, privateScope, kind, start, line, column) {
|
|
@@ -8845,7 +8827,7 @@
|
|
|
8845
8827
|
nextToken(parser, context);
|
|
8846
8828
|
return finishNode(parser, context, start, line, column, {
|
|
8847
8829
|
type: 'PrivateIdentifier',
|
|
8848
|
-
name: tokenValue
|
|
8830
|
+
name: tokenValue,
|
|
8849
8831
|
});
|
|
8850
8832
|
}
|
|
8851
8833
|
function parsePropertyDefinition(parser, context, privateScope, key, state, decorators, start, line, column) {
|
|
@@ -8882,7 +8864,7 @@
|
|
|
8882
8864
|
value,
|
|
8883
8865
|
static: (state & 32) > 0,
|
|
8884
8866
|
computed: (state & 2) > 0,
|
|
8885
|
-
...(context & 1 ? { decorators } : null)
|
|
8867
|
+
...(context & 1 ? { decorators } : null),
|
|
8886
8868
|
});
|
|
8887
8869
|
}
|
|
8888
8870
|
function parseBindingPattern(parser, context, scope, privateScope, type, origin, start, line, column) {
|
|
@@ -8935,7 +8917,7 @@
|
|
|
8935
8917
|
addVarOrBlock(parser, context, scope, tokenValue, kind, origin);
|
|
8936
8918
|
return finishNode(parser, context, start, line, column, {
|
|
8937
8919
|
type: 'Identifier',
|
|
8938
|
-
name: tokenValue
|
|
8920
|
+
name: tokenValue,
|
|
8939
8921
|
});
|
|
8940
8922
|
}
|
|
8941
8923
|
function parseJSXRootElementOrFragment(parser, context, privateScope, inJSXChild, start, line, column) {
|
|
@@ -8948,7 +8930,7 @@
|
|
|
8948
8930
|
type: 'JSXFragment',
|
|
8949
8931
|
openingFragment,
|
|
8950
8932
|
children,
|
|
8951
|
-
closingFragment
|
|
8933
|
+
closingFragment,
|
|
8952
8934
|
});
|
|
8953
8935
|
}
|
|
8954
8936
|
if (parser.getToken() === 8457014)
|
|
@@ -8966,13 +8948,13 @@
|
|
|
8966
8948
|
type: 'JSXElement',
|
|
8967
8949
|
children,
|
|
8968
8950
|
openingElement,
|
|
8969
|
-
closingElement
|
|
8951
|
+
closingElement,
|
|
8970
8952
|
});
|
|
8971
8953
|
}
|
|
8972
8954
|
function parseOpeningFragment(parser, context, start, line, column) {
|
|
8973
8955
|
nextJSXToken(parser, context);
|
|
8974
8956
|
return finishNode(parser, context, start, line, column, {
|
|
8975
|
-
type: 'JSXOpeningFragment'
|
|
8957
|
+
type: 'JSXOpeningFragment',
|
|
8976
8958
|
});
|
|
8977
8959
|
}
|
|
8978
8960
|
function parseJSXClosingElement(parser, context, inJSXChild, start, line, column) {
|
|
@@ -8989,7 +8971,7 @@
|
|
|
8989
8971
|
}
|
|
8990
8972
|
return finishNode(parser, context, start, line, column, {
|
|
8991
8973
|
type: 'JSXClosingElement',
|
|
8992
|
-
name
|
|
8974
|
+
name,
|
|
8993
8975
|
});
|
|
8994
8976
|
}
|
|
8995
8977
|
function parseJSXClosingFragment(parser, context, inJSXChild, start, line, column) {
|
|
@@ -9004,7 +8986,7 @@
|
|
|
9004
8986
|
nextToken(parser, context);
|
|
9005
8987
|
}
|
|
9006
8988
|
return finishNode(parser, context, start, line, column, {
|
|
9007
|
-
type: 'JSXClosingFragment'
|
|
8989
|
+
type: 'JSXClosingFragment',
|
|
9008
8990
|
});
|
|
9009
8991
|
}
|
|
9010
8992
|
function parseJSXChildrenAndClosingElement(parser, context, privateScope, inJSXChild) {
|
|
@@ -9057,7 +9039,7 @@
|
|
|
9057
9039
|
nextToken(parser, context);
|
|
9058
9040
|
const node = {
|
|
9059
9041
|
type: 'JSXText',
|
|
9060
|
-
value: parser.tokenValue
|
|
9042
|
+
value: parser.tokenValue,
|
|
9061
9043
|
};
|
|
9062
9044
|
if (context & 128) {
|
|
9063
9045
|
node.raw = parser.tokenRaw;
|
|
@@ -9086,7 +9068,7 @@
|
|
|
9086
9068
|
type: 'JSXOpeningElement',
|
|
9087
9069
|
name: tagName,
|
|
9088
9070
|
attributes,
|
|
9089
|
-
selfClosing
|
|
9071
|
+
selfClosing,
|
|
9090
9072
|
});
|
|
9091
9073
|
}
|
|
9092
9074
|
function parseJSXElementName(parser, context, start, line, column) {
|
|
@@ -9105,7 +9087,7 @@
|
|
|
9105
9087
|
return finishNode(parser, context, start, line, column, {
|
|
9106
9088
|
type: 'JSXMemberExpression',
|
|
9107
9089
|
object,
|
|
9108
|
-
property
|
|
9090
|
+
property,
|
|
9109
9091
|
});
|
|
9110
9092
|
}
|
|
9111
9093
|
function parseJSXAttributes(parser, context, privateScope) {
|
|
@@ -9124,7 +9106,7 @@
|
|
|
9124
9106
|
consume(parser, context, 1074790415);
|
|
9125
9107
|
return finishNode(parser, context, start, line, column, {
|
|
9126
9108
|
type: 'JSXSpreadAttribute',
|
|
9127
|
-
argument: expression
|
|
9109
|
+
argument: expression,
|
|
9128
9110
|
});
|
|
9129
9111
|
}
|
|
9130
9112
|
function parseJsxAttribute(parser, context, privateScope, start, line, column) {
|
|
@@ -9156,7 +9138,7 @@
|
|
|
9156
9138
|
return finishNode(parser, context, start, line, column, {
|
|
9157
9139
|
type: 'JSXAttribute',
|
|
9158
9140
|
value,
|
|
9159
|
-
name
|
|
9141
|
+
name,
|
|
9160
9142
|
});
|
|
9161
9143
|
}
|
|
9162
9144
|
function parseJSXNamespacedName(parser, context, namespace, start, line, column) {
|
|
@@ -9165,7 +9147,7 @@
|
|
|
9165
9147
|
return finishNode(parser, context, start, line, column, {
|
|
9166
9148
|
type: 'JSXNamespacedName',
|
|
9167
9149
|
namespace,
|
|
9168
|
-
name
|
|
9150
|
+
name,
|
|
9169
9151
|
});
|
|
9170
9152
|
}
|
|
9171
9153
|
function parseJSXExpressionContainer(parser, context, privateScope, inJSXChild, isAttr, start, line, column) {
|
|
@@ -9193,7 +9175,7 @@
|
|
|
9193
9175
|
}
|
|
9194
9176
|
return finishNode(parser, context, start, line, column, {
|
|
9195
9177
|
type: 'JSXExpressionContainer',
|
|
9196
|
-
expression
|
|
9178
|
+
expression,
|
|
9197
9179
|
});
|
|
9198
9180
|
}
|
|
9199
9181
|
function parseJSXSpreadChild(parser, context, privateScope, start, line, column) {
|
|
@@ -9202,7 +9184,7 @@
|
|
|
9202
9184
|
consume(parser, context, 1074790415);
|
|
9203
9185
|
return finishNode(parser, context, start, line, column, {
|
|
9204
9186
|
type: 'JSXSpreadChild',
|
|
9205
|
-
expression
|
|
9187
|
+
expression,
|
|
9206
9188
|
});
|
|
9207
9189
|
}
|
|
9208
9190
|
function parseJSXEmptyExpression(parser, context, start, line, column) {
|
|
@@ -9210,7 +9192,7 @@
|
|
|
9210
9192
|
parser.startLine = parser.tokenLine;
|
|
9211
9193
|
parser.startColumn = parser.tokenColumn;
|
|
9212
9194
|
return finishNode(parser, context, start, line, column, {
|
|
9213
|
-
type: 'JSXEmptyExpression'
|
|
9195
|
+
type: 'JSXEmptyExpression',
|
|
9214
9196
|
});
|
|
9215
9197
|
}
|
|
9216
9198
|
function parseJSXIdentifier(parser, context, start, line, column) {
|
|
@@ -9221,15 +9203,11 @@
|
|
|
9221
9203
|
nextToken(parser, context);
|
|
9222
9204
|
return finishNode(parser, context, start, line, column, {
|
|
9223
9205
|
type: 'JSXIdentifier',
|
|
9224
|
-
name: tokenValue
|
|
9206
|
+
name: tokenValue,
|
|
9225
9207
|
});
|
|
9226
9208
|
}
|
|
9227
9209
|
|
|
9228
|
-
var
|
|
9229
|
-
__proto__: null
|
|
9230
|
-
});
|
|
9231
|
-
|
|
9232
|
-
var version$1 = "6.0.6";
|
|
9210
|
+
var version$1 = "6.1.0";
|
|
9233
9211
|
|
|
9234
9212
|
const version = version$1;
|
|
9235
9213
|
function parseScript(source, options) {
|
|
@@ -9242,7 +9220,6 @@
|
|
|
9242
9220
|
return parseSource(source, options, 0);
|
|
9243
9221
|
}
|
|
9244
9222
|
|
|
9245
|
-
exports.ESTree = estree;
|
|
9246
9223
|
exports.parse = parse;
|
|
9247
9224
|
exports.parseModule = parseModule;
|
|
9248
9225
|
exports.parseScript = parseScript;
|