@putout/bundle 2.0.0 → 2.0.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/bundle/putout-iife.js +1 -1
- package/bundle/putout.js +856 -836
- package/bundle/putout.min.js +1 -0
- package/package.json +10 -9
package/bundle/putout.js
CHANGED
|
@@ -71014,485 +71014,495 @@ function isValidIdentifier$8(name, reserved = true) {
|
|
|
71014
71014
|
|
|
71015
71015
|
var lib$m = {};
|
|
71016
71016
|
|
|
71017
|
-
|
|
71018
|
-
value: true
|
|
71019
|
-
});
|
|
71020
|
-
lib$m.readCodePoint = readCodePoint$3;
|
|
71021
|
-
lib$m.readInt = readInt$3;
|
|
71022
|
-
lib$m.readStringContents = readStringContents$3;
|
|
71023
|
-
var _isDigit$3 = function isDigit(code) {
|
|
71024
|
-
return code >= 48 && code <= 57;
|
|
71025
|
-
};
|
|
71026
|
-
const forbiddenNumericSeparatorSiblings$3 = {
|
|
71027
|
-
decBinOct: new Set([46, 66, 69, 79, 95, 98, 101, 111]),
|
|
71028
|
-
hex: new Set([46, 88, 95, 120])
|
|
71029
|
-
};
|
|
71030
|
-
const isAllowedNumericSeparatorSibling$3 = {
|
|
71031
|
-
bin: ch => ch === 48 || ch === 49,
|
|
71032
|
-
oct: ch => ch >= 48 && ch <= 55,
|
|
71033
|
-
dec: ch => ch >= 48 && ch <= 57,
|
|
71034
|
-
hex: ch => ch >= 48 && ch <= 57 || ch >= 65 && ch <= 70 || ch >= 97 && ch <= 102
|
|
71035
|
-
};
|
|
71036
|
-
function readStringContents$3(type, input, pos, lineStart, curLine, errors) {
|
|
71037
|
-
const initialPos = pos;
|
|
71038
|
-
const initialLineStart = lineStart;
|
|
71039
|
-
const initialCurLine = curLine;
|
|
71040
|
-
let out = "";
|
|
71041
|
-
let firstInvalidLoc = null;
|
|
71042
|
-
let chunkStart = pos;
|
|
71043
|
-
const {
|
|
71044
|
-
length
|
|
71045
|
-
} = input;
|
|
71046
|
-
for (;;) {
|
|
71047
|
-
if (pos >= length) {
|
|
71048
|
-
errors.unterminated(initialPos, initialLineStart, initialCurLine);
|
|
71049
|
-
out += input.slice(chunkStart, pos);
|
|
71050
|
-
break;
|
|
71051
|
-
}
|
|
71052
|
-
const ch = input.charCodeAt(pos);
|
|
71053
|
-
if (isStringEnd$3(type, ch, input, pos)) {
|
|
71054
|
-
out += input.slice(chunkStart, pos);
|
|
71055
|
-
break;
|
|
71056
|
-
}
|
|
71057
|
-
if (ch === 92) {
|
|
71058
|
-
out += input.slice(chunkStart, pos);
|
|
71059
|
-
const res = readEscapedChar$3(input, pos, lineStart, curLine, type === "template", errors);
|
|
71060
|
-
if (res.ch === null && !firstInvalidLoc) {
|
|
71061
|
-
firstInvalidLoc = {
|
|
71062
|
-
pos,
|
|
71063
|
-
lineStart,
|
|
71064
|
-
curLine
|
|
71065
|
-
};
|
|
71066
|
-
} else {
|
|
71067
|
-
out += res.ch;
|
|
71068
|
-
}
|
|
71069
|
-
({
|
|
71070
|
-
pos,
|
|
71071
|
-
lineStart,
|
|
71072
|
-
curLine
|
|
71073
|
-
} = res);
|
|
71074
|
-
chunkStart = pos;
|
|
71075
|
-
} else if (ch === 8232 || ch === 8233) {
|
|
71076
|
-
++pos;
|
|
71077
|
-
++curLine;
|
|
71078
|
-
lineStart = pos;
|
|
71079
|
-
} else if (ch === 10 || ch === 13) {
|
|
71080
|
-
if (type === "template") {
|
|
71081
|
-
out += input.slice(chunkStart, pos) + "\n";
|
|
71082
|
-
++pos;
|
|
71083
|
-
if (ch === 13 && input.charCodeAt(pos) === 10) {
|
|
71084
|
-
++pos;
|
|
71085
|
-
}
|
|
71086
|
-
++curLine;
|
|
71087
|
-
chunkStart = lineStart = pos;
|
|
71088
|
-
} else {
|
|
71089
|
-
errors.unterminated(initialPos, initialLineStart, initialCurLine);
|
|
71090
|
-
}
|
|
71091
|
-
} else {
|
|
71092
|
-
++pos;
|
|
71093
|
-
}
|
|
71094
|
-
}
|
|
71095
|
-
return {
|
|
71096
|
-
pos,
|
|
71097
|
-
str: out,
|
|
71098
|
-
firstInvalidLoc,
|
|
71099
|
-
lineStart,
|
|
71100
|
-
curLine,
|
|
71101
|
-
containsInvalid: !!firstInvalidLoc
|
|
71102
|
-
};
|
|
71103
|
-
}
|
|
71104
|
-
function isStringEnd$3(type, ch, input, pos) {
|
|
71105
|
-
if (type === "template") {
|
|
71106
|
-
return ch === 96 || ch === 36 && input.charCodeAt(pos + 1) === 123;
|
|
71107
|
-
}
|
|
71108
|
-
return ch === (type === "double" ? 34 : 39);
|
|
71109
|
-
}
|
|
71110
|
-
function readEscapedChar$3(input, pos, lineStart, curLine, inTemplate, errors) {
|
|
71111
|
-
const throwOnInvalid = !inTemplate;
|
|
71112
|
-
pos++;
|
|
71113
|
-
const res = ch => ({
|
|
71114
|
-
pos,
|
|
71115
|
-
ch,
|
|
71116
|
-
lineStart,
|
|
71117
|
-
curLine
|
|
71118
|
-
});
|
|
71119
|
-
const ch = input.charCodeAt(pos++);
|
|
71120
|
-
switch (ch) {
|
|
71121
|
-
case 110:
|
|
71122
|
-
return res("\n");
|
|
71123
|
-
case 114:
|
|
71124
|
-
return res("\r");
|
|
71125
|
-
case 120:
|
|
71126
|
-
{
|
|
71127
|
-
let code;
|
|
71128
|
-
({
|
|
71129
|
-
code,
|
|
71130
|
-
pos
|
|
71131
|
-
} = readHexChar$3(input, pos, lineStart, curLine, 2, false, throwOnInvalid, errors));
|
|
71132
|
-
return res(code === null ? null : String.fromCharCode(code));
|
|
71133
|
-
}
|
|
71134
|
-
case 117:
|
|
71135
|
-
{
|
|
71136
|
-
let code;
|
|
71137
|
-
({
|
|
71138
|
-
code,
|
|
71139
|
-
pos
|
|
71140
|
-
} = readCodePoint$3(input, pos, lineStart, curLine, throwOnInvalid, errors));
|
|
71141
|
-
return res(code === null ? null : String.fromCodePoint(code));
|
|
71142
|
-
}
|
|
71143
|
-
case 116:
|
|
71144
|
-
return res("\t");
|
|
71145
|
-
case 98:
|
|
71146
|
-
return res("\b");
|
|
71147
|
-
case 118:
|
|
71148
|
-
return res("\u000b");
|
|
71149
|
-
case 102:
|
|
71150
|
-
return res("\f");
|
|
71151
|
-
case 13:
|
|
71152
|
-
if (input.charCodeAt(pos) === 10) {
|
|
71153
|
-
++pos;
|
|
71154
|
-
}
|
|
71155
|
-
case 10:
|
|
71156
|
-
lineStart = pos;
|
|
71157
|
-
++curLine;
|
|
71158
|
-
case 8232:
|
|
71159
|
-
case 8233:
|
|
71160
|
-
return res("");
|
|
71161
|
-
case 56:
|
|
71162
|
-
case 57:
|
|
71163
|
-
if (inTemplate) {
|
|
71164
|
-
return res(null);
|
|
71165
|
-
} else {
|
|
71166
|
-
errors.strictNumericEscape(pos - 1, lineStart, curLine);
|
|
71167
|
-
}
|
|
71168
|
-
default:
|
|
71169
|
-
if (ch >= 48 && ch <= 55) {
|
|
71170
|
-
const startPos = pos - 1;
|
|
71171
|
-
const match = input.slice(startPos, pos + 2).match(/^[0-7]+/);
|
|
71172
|
-
let octalStr = match[0];
|
|
71173
|
-
let octal = parseInt(octalStr, 8);
|
|
71174
|
-
if (octal > 255) {
|
|
71175
|
-
octalStr = octalStr.slice(0, -1);
|
|
71176
|
-
octal = parseInt(octalStr, 8);
|
|
71177
|
-
}
|
|
71178
|
-
pos += octalStr.length - 1;
|
|
71179
|
-
const next = input.charCodeAt(pos);
|
|
71180
|
-
if (octalStr !== "0" || next === 56 || next === 57) {
|
|
71181
|
-
if (inTemplate) {
|
|
71182
|
-
return res(null);
|
|
71183
|
-
} else {
|
|
71184
|
-
errors.strictNumericEscape(startPos, lineStart, curLine);
|
|
71185
|
-
}
|
|
71186
|
-
}
|
|
71187
|
-
return res(String.fromCharCode(octal));
|
|
71188
|
-
}
|
|
71189
|
-
return res(String.fromCharCode(ch));
|
|
71190
|
-
}
|
|
71191
|
-
}
|
|
71192
|
-
function readHexChar$3(input, pos, lineStart, curLine, len, forceLen, throwOnInvalid, errors) {
|
|
71193
|
-
const initialPos = pos;
|
|
71194
|
-
let n;
|
|
71195
|
-
({
|
|
71196
|
-
n,
|
|
71197
|
-
pos
|
|
71198
|
-
} = readInt$3(input, pos, lineStart, curLine, 16, len, forceLen, false, errors, !throwOnInvalid));
|
|
71199
|
-
if (n === null) {
|
|
71200
|
-
if (throwOnInvalid) {
|
|
71201
|
-
errors.invalidEscapeSequence(initialPos, lineStart, curLine);
|
|
71202
|
-
} else {
|
|
71203
|
-
pos = initialPos - 1;
|
|
71204
|
-
}
|
|
71205
|
-
}
|
|
71206
|
-
return {
|
|
71207
|
-
code: n,
|
|
71208
|
-
pos
|
|
71209
|
-
};
|
|
71210
|
-
}
|
|
71211
|
-
function readInt$3(input, pos, lineStart, curLine, radix, len, forceLen, allowNumSeparator, errors, bailOnError) {
|
|
71212
|
-
const start = pos;
|
|
71213
|
-
const forbiddenSiblings = radix === 16 ? forbiddenNumericSeparatorSiblings$3.hex : forbiddenNumericSeparatorSiblings$3.decBinOct;
|
|
71214
|
-
const isAllowedSibling = radix === 16 ? isAllowedNumericSeparatorSibling$3.hex : radix === 10 ? isAllowedNumericSeparatorSibling$3.dec : radix === 8 ? isAllowedNumericSeparatorSibling$3.oct : isAllowedNumericSeparatorSibling$3.bin;
|
|
71215
|
-
let invalid = false;
|
|
71216
|
-
let total = 0;
|
|
71217
|
-
for (let i = 0, e = len == null ? Infinity : len; i < e; ++i) {
|
|
71218
|
-
const code = input.charCodeAt(pos);
|
|
71219
|
-
let val;
|
|
71220
|
-
if (code === 95 && allowNumSeparator !== "bail") {
|
|
71221
|
-
const prev = input.charCodeAt(pos - 1);
|
|
71222
|
-
const next = input.charCodeAt(pos + 1);
|
|
71223
|
-
if (!allowNumSeparator) {
|
|
71224
|
-
if (bailOnError) return {
|
|
71225
|
-
n: null,
|
|
71226
|
-
pos
|
|
71227
|
-
};
|
|
71228
|
-
errors.numericSeparatorInEscapeSequence(pos, lineStart, curLine);
|
|
71229
|
-
} else if (Number.isNaN(next) || !isAllowedSibling(next) || forbiddenSiblings.has(prev) || forbiddenSiblings.has(next)) {
|
|
71230
|
-
if (bailOnError) return {
|
|
71231
|
-
n: null,
|
|
71232
|
-
pos
|
|
71233
|
-
};
|
|
71234
|
-
errors.unexpectedNumericSeparator(pos, lineStart, curLine);
|
|
71235
|
-
}
|
|
71236
|
-
++pos;
|
|
71237
|
-
continue;
|
|
71238
|
-
}
|
|
71239
|
-
if (code >= 97) {
|
|
71240
|
-
val = code - 97 + 10;
|
|
71241
|
-
} else if (code >= 65) {
|
|
71242
|
-
val = code - 65 + 10;
|
|
71243
|
-
} else if (_isDigit$3(code)) {
|
|
71244
|
-
val = code - 48;
|
|
71245
|
-
} else {
|
|
71246
|
-
val = Infinity;
|
|
71247
|
-
}
|
|
71248
|
-
if (val >= radix) {
|
|
71249
|
-
if (val <= 9 && bailOnError) {
|
|
71250
|
-
return {
|
|
71251
|
-
n: null,
|
|
71252
|
-
pos
|
|
71253
|
-
};
|
|
71254
|
-
} else if (val <= 9 && errors.invalidDigit(pos, lineStart, curLine, radix)) {
|
|
71255
|
-
val = 0;
|
|
71256
|
-
} else if (forceLen) {
|
|
71257
|
-
val = 0;
|
|
71258
|
-
invalid = true;
|
|
71259
|
-
} else {
|
|
71260
|
-
break;
|
|
71261
|
-
}
|
|
71262
|
-
}
|
|
71263
|
-
++pos;
|
|
71264
|
-
total = total * radix + val;
|
|
71265
|
-
}
|
|
71266
|
-
if (pos === start || len != null && pos - start !== len || invalid) {
|
|
71267
|
-
return {
|
|
71268
|
-
n: null,
|
|
71269
|
-
pos
|
|
71270
|
-
};
|
|
71271
|
-
}
|
|
71272
|
-
return {
|
|
71273
|
-
n: total,
|
|
71274
|
-
pos
|
|
71275
|
-
};
|
|
71276
|
-
}
|
|
71277
|
-
function readCodePoint$3(input, pos, lineStart, curLine, throwOnInvalid, errors) {
|
|
71278
|
-
const ch = input.charCodeAt(pos);
|
|
71279
|
-
let code;
|
|
71280
|
-
if (ch === 123) {
|
|
71281
|
-
++pos;
|
|
71282
|
-
({
|
|
71283
|
-
code,
|
|
71284
|
-
pos
|
|
71285
|
-
} = readHexChar$3(input, pos, lineStart, curLine, input.indexOf("}", pos) - pos, true, throwOnInvalid, errors));
|
|
71286
|
-
++pos;
|
|
71287
|
-
if (code !== null && code > 0x10ffff) {
|
|
71288
|
-
if (throwOnInvalid) {
|
|
71289
|
-
errors.invalidCodePoint(pos, lineStart, curLine);
|
|
71290
|
-
} else {
|
|
71291
|
-
return {
|
|
71292
|
-
code: null,
|
|
71293
|
-
pos
|
|
71294
|
-
};
|
|
71295
|
-
}
|
|
71296
|
-
}
|
|
71297
|
-
} else {
|
|
71298
|
-
({
|
|
71299
|
-
code,
|
|
71300
|
-
pos
|
|
71301
|
-
} = readHexChar$3(input, pos, lineStart, curLine, 4, false, throwOnInvalid, errors));
|
|
71302
|
-
}
|
|
71303
|
-
return {
|
|
71304
|
-
code,
|
|
71305
|
-
pos
|
|
71306
|
-
};
|
|
71307
|
-
}
|
|
71308
|
-
|
|
71309
|
-
var constants$4 = {};
|
|
71310
|
-
|
|
71311
|
-
Object.defineProperty(constants$4, "__esModule", {
|
|
71312
|
-
value: true
|
|
71313
|
-
});
|
|
71314
|
-
constants$4.UPDATE_OPERATORS = constants$4.UNARY_OPERATORS = constants$4.STRING_UNARY_OPERATORS = constants$4.STATEMENT_OR_BLOCK_KEYS = constants$4.NUMBER_UNARY_OPERATORS = constants$4.NUMBER_BINARY_OPERATORS = constants$4.NOT_LOCAL_BINDING = constants$4.LOGICAL_OPERATORS = constants$4.INHERIT_KEYS = constants$4.FOR_INIT_KEYS = constants$4.FLATTENABLE_KEYS = constants$4.EQUALITY_BINARY_OPERATORS = constants$4.COMPARISON_BINARY_OPERATORS = constants$4.COMMENT_KEYS = constants$4.BOOLEAN_UNARY_OPERATORS = constants$4.BOOLEAN_NUMBER_BINARY_OPERATORS = constants$4.BOOLEAN_BINARY_OPERATORS = constants$4.BLOCK_SCOPED_SYMBOL = constants$4.BINARY_OPERATORS = constants$4.ASSIGNMENT_OPERATORS = void 0;
|
|
71315
|
-
const STATEMENT_OR_BLOCK_KEYS$5 = ["consequent", "body", "alternate"];
|
|
71316
|
-
constants$4.STATEMENT_OR_BLOCK_KEYS = STATEMENT_OR_BLOCK_KEYS$5;
|
|
71317
|
-
const FLATTENABLE_KEYS$4 = ["body", "expressions"];
|
|
71318
|
-
constants$4.FLATTENABLE_KEYS = FLATTENABLE_KEYS$4;
|
|
71319
|
-
const FOR_INIT_KEYS$4 = ["left", "init"];
|
|
71320
|
-
constants$4.FOR_INIT_KEYS = FOR_INIT_KEYS$4;
|
|
71321
|
-
const COMMENT_KEYS$4 = ["leadingComments", "trailingComments", "innerComments"];
|
|
71322
|
-
constants$4.COMMENT_KEYS = COMMENT_KEYS$4;
|
|
71323
|
-
const LOGICAL_OPERATORS$5 = ["||", "&&", "??"];
|
|
71324
|
-
constants$4.LOGICAL_OPERATORS = LOGICAL_OPERATORS$5;
|
|
71325
|
-
const UPDATE_OPERATORS$4 = ["++", "--"];
|
|
71326
|
-
constants$4.UPDATE_OPERATORS = UPDATE_OPERATORS$4;
|
|
71327
|
-
const BOOLEAN_NUMBER_BINARY_OPERATORS$5 = [">", "<", ">=", "<="];
|
|
71328
|
-
constants$4.BOOLEAN_NUMBER_BINARY_OPERATORS = BOOLEAN_NUMBER_BINARY_OPERATORS$5;
|
|
71329
|
-
const EQUALITY_BINARY_OPERATORS$4 = ["==", "===", "!=", "!=="];
|
|
71330
|
-
constants$4.EQUALITY_BINARY_OPERATORS = EQUALITY_BINARY_OPERATORS$4;
|
|
71331
|
-
const COMPARISON_BINARY_OPERATORS$4 = [...EQUALITY_BINARY_OPERATORS$4, "in", "instanceof"];
|
|
71332
|
-
constants$4.COMPARISON_BINARY_OPERATORS = COMPARISON_BINARY_OPERATORS$4;
|
|
71333
|
-
const BOOLEAN_BINARY_OPERATORS$4 = [...COMPARISON_BINARY_OPERATORS$4, ...BOOLEAN_NUMBER_BINARY_OPERATORS$5];
|
|
71334
|
-
constants$4.BOOLEAN_BINARY_OPERATORS = BOOLEAN_BINARY_OPERATORS$4;
|
|
71335
|
-
const NUMBER_BINARY_OPERATORS$4 = ["-", "/", "%", "*", "**", "&", "|", ">>", ">>>", "<<", "^"];
|
|
71336
|
-
constants$4.NUMBER_BINARY_OPERATORS = NUMBER_BINARY_OPERATORS$4;
|
|
71337
|
-
const BINARY_OPERATORS$4 = ["+", ...NUMBER_BINARY_OPERATORS$4, ...BOOLEAN_BINARY_OPERATORS$4, "|>"];
|
|
71338
|
-
constants$4.BINARY_OPERATORS = BINARY_OPERATORS$4;
|
|
71339
|
-
const ASSIGNMENT_OPERATORS$4 = ["=", "+=", ...NUMBER_BINARY_OPERATORS$4.map(op => op + "="), ...LOGICAL_OPERATORS$5.map(op => op + "=")];
|
|
71340
|
-
constants$4.ASSIGNMENT_OPERATORS = ASSIGNMENT_OPERATORS$4;
|
|
71341
|
-
const BOOLEAN_UNARY_OPERATORS$4 = ["delete", "!"];
|
|
71342
|
-
constants$4.BOOLEAN_UNARY_OPERATORS = BOOLEAN_UNARY_OPERATORS$4;
|
|
71343
|
-
const NUMBER_UNARY_OPERATORS$4 = ["+", "-", "~"];
|
|
71344
|
-
constants$4.NUMBER_UNARY_OPERATORS = NUMBER_UNARY_OPERATORS$4;
|
|
71345
|
-
const STRING_UNARY_OPERATORS$4 = ["typeof"];
|
|
71346
|
-
constants$4.STRING_UNARY_OPERATORS = STRING_UNARY_OPERATORS$4;
|
|
71347
|
-
const UNARY_OPERATORS$4 = ["void", "throw", ...BOOLEAN_UNARY_OPERATORS$4, ...NUMBER_UNARY_OPERATORS$4, ...STRING_UNARY_OPERATORS$4];
|
|
71348
|
-
constants$4.UNARY_OPERATORS = UNARY_OPERATORS$4;
|
|
71349
|
-
const INHERIT_KEYS$4 = {
|
|
71350
|
-
optional: ["typeAnnotation", "typeParameters", "returnType"],
|
|
71351
|
-
force: ["start", "loc", "end"]
|
|
71352
|
-
};
|
|
71353
|
-
constants$4.INHERIT_KEYS = INHERIT_KEYS$4;
|
|
71354
|
-
const BLOCK_SCOPED_SYMBOL$4 = Symbol.for("var used to be block scoped");
|
|
71355
|
-
constants$4.BLOCK_SCOPED_SYMBOL = BLOCK_SCOPED_SYMBOL$4;
|
|
71356
|
-
const NOT_LOCAL_BINDING$5 = Symbol.for("should not be considered a local binding");
|
|
71357
|
-
constants$4.NOT_LOCAL_BINDING = NOT_LOCAL_BINDING$5;
|
|
71358
|
-
|
|
71359
|
-
var utils$5 = {};
|
|
71017
|
+
var hasRequiredLib$9;
|
|
71360
71018
|
|
|
71361
|
-
|
|
71362
|
-
|
|
71363
|
-
|
|
71364
|
-
if (hasRequiredUtils$4) return utils$5;
|
|
71365
|
-
hasRequiredUtils$4 = 1;
|
|
71019
|
+
function requireLib$9 () {
|
|
71020
|
+
if (hasRequiredLib$9) return lib$m;
|
|
71021
|
+
hasRequiredLib$9 = 1;
|
|
71366
71022
|
|
|
71367
|
-
Object.defineProperty(
|
|
71023
|
+
Object.defineProperty(lib$m, "__esModule", {
|
|
71368
71024
|
value: true
|
|
71369
71025
|
});
|
|
71370
|
-
|
|
71371
|
-
|
|
71372
|
-
|
|
71373
|
-
|
|
71374
|
-
|
|
71375
|
-
|
|
71376
|
-
|
|
71377
|
-
|
|
71378
|
-
|
|
71379
|
-
|
|
71380
|
-
|
|
71381
|
-
|
|
71382
|
-
|
|
71383
|
-
|
|
71384
|
-
|
|
71385
|
-
|
|
71386
|
-
|
|
71387
|
-
|
|
71388
|
-
|
|
71389
|
-
|
|
71390
|
-
|
|
71391
|
-
|
|
71392
|
-
|
|
71393
|
-
|
|
71394
|
-
|
|
71395
|
-
|
|
71396
|
-
|
|
71397
|
-
|
|
71398
|
-
|
|
71399
|
-
|
|
71400
|
-
|
|
71401
|
-
const DEPRECATED_KEYS = {};
|
|
71402
|
-
utils$5.DEPRECATED_KEYS = DEPRECATED_KEYS;
|
|
71403
|
-
const NODE_PARENT_VALIDATIONS = {};
|
|
71404
|
-
utils$5.NODE_PARENT_VALIDATIONS = NODE_PARENT_VALIDATIONS;
|
|
71405
|
-
function getType(val) {
|
|
71406
|
-
if (Array.isArray(val)) {
|
|
71407
|
-
return "array";
|
|
71408
|
-
} else if (val === null) {
|
|
71409
|
-
return "null";
|
|
71410
|
-
} else {
|
|
71411
|
-
return typeof val;
|
|
71412
|
-
}
|
|
71413
|
-
}
|
|
71414
|
-
function validate(validate) {
|
|
71415
|
-
return {
|
|
71416
|
-
validate
|
|
71417
|
-
};
|
|
71418
|
-
}
|
|
71419
|
-
function typeIs(typeName) {
|
|
71420
|
-
return typeof typeName === "string" ? assertNodeType(typeName) : assertNodeType(...typeName);
|
|
71421
|
-
}
|
|
71422
|
-
function validateType(typeName) {
|
|
71423
|
-
return validate(typeIs(typeName));
|
|
71424
|
-
}
|
|
71425
|
-
function validateOptional(validate) {
|
|
71426
|
-
return {
|
|
71427
|
-
validate,
|
|
71428
|
-
optional: true
|
|
71429
|
-
};
|
|
71430
|
-
}
|
|
71431
|
-
function validateOptionalType(typeName) {
|
|
71432
|
-
return {
|
|
71433
|
-
validate: typeIs(typeName),
|
|
71434
|
-
optional: true
|
|
71435
|
-
};
|
|
71436
|
-
}
|
|
71437
|
-
function arrayOf(elementType) {
|
|
71438
|
-
return chain(assertValueType("array"), assertEach(elementType));
|
|
71439
|
-
}
|
|
71440
|
-
function arrayOfType(typeName) {
|
|
71441
|
-
return arrayOf(typeIs(typeName));
|
|
71442
|
-
}
|
|
71443
|
-
function validateArrayOfType(typeName) {
|
|
71444
|
-
return validate(arrayOfType(typeName));
|
|
71445
|
-
}
|
|
71446
|
-
function assertEach(callback) {
|
|
71447
|
-
function validator(node, key, val) {
|
|
71448
|
-
if (!Array.isArray(val)) return;
|
|
71449
|
-
for (let i = 0; i < val.length; i++) {
|
|
71450
|
-
const subkey = `${key}[${i}]`;
|
|
71451
|
-
const v = val[i];
|
|
71452
|
-
callback(node, subkey, v);
|
|
71453
|
-
(0, _validate.validateChild)(node, subkey, v);
|
|
71026
|
+
lib$m.readCodePoint = readCodePoint;
|
|
71027
|
+
lib$m.readInt = readInt;
|
|
71028
|
+
lib$m.readStringContents = readStringContents;
|
|
71029
|
+
var _isDigit = function isDigit(code) {
|
|
71030
|
+
return code >= 48 && code <= 57;
|
|
71031
|
+
};
|
|
71032
|
+
const forbiddenNumericSeparatorSiblings = {
|
|
71033
|
+
decBinOct: new Set([46, 66, 69, 79, 95, 98, 101, 111]),
|
|
71034
|
+
hex: new Set([46, 88, 95, 120])
|
|
71035
|
+
};
|
|
71036
|
+
const isAllowedNumericSeparatorSibling = {
|
|
71037
|
+
bin: ch => ch === 48 || ch === 49,
|
|
71038
|
+
oct: ch => ch >= 48 && ch <= 55,
|
|
71039
|
+
dec: ch => ch >= 48 && ch <= 57,
|
|
71040
|
+
hex: ch => ch >= 48 && ch <= 57 || ch >= 65 && ch <= 70 || ch >= 97 && ch <= 102
|
|
71041
|
+
};
|
|
71042
|
+
function readStringContents(type, input, pos, lineStart, curLine, errors) {
|
|
71043
|
+
const initialPos = pos;
|
|
71044
|
+
const initialLineStart = lineStart;
|
|
71045
|
+
const initialCurLine = curLine;
|
|
71046
|
+
let out = "";
|
|
71047
|
+
let firstInvalidLoc = null;
|
|
71048
|
+
let chunkStart = pos;
|
|
71049
|
+
const {
|
|
71050
|
+
length
|
|
71051
|
+
} = input;
|
|
71052
|
+
for (;;) {
|
|
71053
|
+
if (pos >= length) {
|
|
71054
|
+
errors.unterminated(initialPos, initialLineStart, initialCurLine);
|
|
71055
|
+
out += input.slice(chunkStart, pos);
|
|
71056
|
+
break;
|
|
71454
71057
|
}
|
|
71455
|
-
|
|
71456
|
-
|
|
71457
|
-
|
|
71458
|
-
|
|
71459
|
-
function assertOneOf(...values) {
|
|
71460
|
-
function validate(node, key, val) {
|
|
71461
|
-
if (values.indexOf(val) < 0) {
|
|
71462
|
-
throw new TypeError(`Property ${key} expected value to be one of ${JSON.stringify(values)} but got ${JSON.stringify(val)}`);
|
|
71058
|
+
const ch = input.charCodeAt(pos);
|
|
71059
|
+
if (isStringEnd(type, ch, input, pos)) {
|
|
71060
|
+
out += input.slice(chunkStart, pos);
|
|
71061
|
+
break;
|
|
71463
71062
|
}
|
|
71464
|
-
|
|
71465
|
-
|
|
71466
|
-
|
|
71467
|
-
|
|
71468
|
-
|
|
71469
|
-
|
|
71470
|
-
|
|
71471
|
-
|
|
71472
|
-
|
|
71473
|
-
|
|
71063
|
+
if (ch === 92) {
|
|
71064
|
+
out += input.slice(chunkStart, pos);
|
|
71065
|
+
const res = readEscapedChar(input, pos, lineStart, curLine, type === "template", errors);
|
|
71066
|
+
if (res.ch === null && !firstInvalidLoc) {
|
|
71067
|
+
firstInvalidLoc = {
|
|
71068
|
+
pos,
|
|
71069
|
+
lineStart,
|
|
71070
|
+
curLine
|
|
71071
|
+
};
|
|
71072
|
+
} else {
|
|
71073
|
+
out += res.ch;
|
|
71474
71074
|
}
|
|
71475
|
-
|
|
71476
|
-
|
|
71477
|
-
|
|
71478
|
-
|
|
71479
|
-
|
|
71480
|
-
|
|
71481
|
-
|
|
71482
|
-
|
|
71483
|
-
|
|
71484
|
-
|
|
71485
|
-
|
|
71486
|
-
|
|
71075
|
+
({
|
|
71076
|
+
pos,
|
|
71077
|
+
lineStart,
|
|
71078
|
+
curLine
|
|
71079
|
+
} = res);
|
|
71080
|
+
chunkStart = pos;
|
|
71081
|
+
} else if (ch === 8232 || ch === 8233) {
|
|
71082
|
+
++pos;
|
|
71083
|
+
++curLine;
|
|
71084
|
+
lineStart = pos;
|
|
71085
|
+
} else if (ch === 10 || ch === 13) {
|
|
71086
|
+
if (type === "template") {
|
|
71087
|
+
out += input.slice(chunkStart, pos) + "\n";
|
|
71088
|
+
++pos;
|
|
71089
|
+
if (ch === 13 && input.charCodeAt(pos) === 10) {
|
|
71090
|
+
++pos;
|
|
71091
|
+
}
|
|
71092
|
+
++curLine;
|
|
71093
|
+
chunkStart = lineStart = pos;
|
|
71094
|
+
} else {
|
|
71095
|
+
errors.unterminated(initialPos, initialLineStart, initialCurLine);
|
|
71487
71096
|
}
|
|
71097
|
+
} else {
|
|
71098
|
+
++pos;
|
|
71488
71099
|
}
|
|
71489
|
-
throw new TypeError(`Property ${key} of ${node.type} expected node to be of a type ${JSON.stringify(types)} but instead got ${JSON.stringify(val == null ? void 0 : val.type)}`);
|
|
71490
71100
|
}
|
|
71491
|
-
|
|
71492
|
-
|
|
71493
|
-
|
|
71494
|
-
|
|
71495
|
-
|
|
71101
|
+
return {
|
|
71102
|
+
pos,
|
|
71103
|
+
str: out,
|
|
71104
|
+
firstInvalidLoc,
|
|
71105
|
+
lineStart,
|
|
71106
|
+
curLine,
|
|
71107
|
+
containsInvalid: !!firstInvalidLoc
|
|
71108
|
+
};
|
|
71109
|
+
}
|
|
71110
|
+
function isStringEnd(type, ch, input, pos) {
|
|
71111
|
+
if (type === "template") {
|
|
71112
|
+
return ch === 96 || ch === 36 && input.charCodeAt(pos + 1) === 123;
|
|
71113
|
+
}
|
|
71114
|
+
return ch === (type === "double" ? 34 : 39);
|
|
71115
|
+
}
|
|
71116
|
+
function readEscapedChar(input, pos, lineStart, curLine, inTemplate, errors) {
|
|
71117
|
+
const throwOnInvalid = !inTemplate;
|
|
71118
|
+
pos++;
|
|
71119
|
+
const res = ch => ({
|
|
71120
|
+
pos,
|
|
71121
|
+
ch,
|
|
71122
|
+
lineStart,
|
|
71123
|
+
curLine
|
|
71124
|
+
});
|
|
71125
|
+
const ch = input.charCodeAt(pos++);
|
|
71126
|
+
switch (ch) {
|
|
71127
|
+
case 110:
|
|
71128
|
+
return res("\n");
|
|
71129
|
+
case 114:
|
|
71130
|
+
return res("\r");
|
|
71131
|
+
case 120:
|
|
71132
|
+
{
|
|
71133
|
+
let code;
|
|
71134
|
+
({
|
|
71135
|
+
code,
|
|
71136
|
+
pos
|
|
71137
|
+
} = readHexChar(input, pos, lineStart, curLine, 2, false, throwOnInvalid, errors));
|
|
71138
|
+
return res(code === null ? null : String.fromCharCode(code));
|
|
71139
|
+
}
|
|
71140
|
+
case 117:
|
|
71141
|
+
{
|
|
71142
|
+
let code;
|
|
71143
|
+
({
|
|
71144
|
+
code,
|
|
71145
|
+
pos
|
|
71146
|
+
} = readCodePoint(input, pos, lineStart, curLine, throwOnInvalid, errors));
|
|
71147
|
+
return res(code === null ? null : String.fromCodePoint(code));
|
|
71148
|
+
}
|
|
71149
|
+
case 116:
|
|
71150
|
+
return res("\t");
|
|
71151
|
+
case 98:
|
|
71152
|
+
return res("\b");
|
|
71153
|
+
case 118:
|
|
71154
|
+
return res("\u000b");
|
|
71155
|
+
case 102:
|
|
71156
|
+
return res("\f");
|
|
71157
|
+
case 13:
|
|
71158
|
+
if (input.charCodeAt(pos) === 10) {
|
|
71159
|
+
++pos;
|
|
71160
|
+
}
|
|
71161
|
+
case 10:
|
|
71162
|
+
lineStart = pos;
|
|
71163
|
+
++curLine;
|
|
71164
|
+
case 8232:
|
|
71165
|
+
case 8233:
|
|
71166
|
+
return res("");
|
|
71167
|
+
case 56:
|
|
71168
|
+
case 57:
|
|
71169
|
+
if (inTemplate) {
|
|
71170
|
+
return res(null);
|
|
71171
|
+
} else {
|
|
71172
|
+
errors.strictNumericEscape(pos - 1, lineStart, curLine);
|
|
71173
|
+
}
|
|
71174
|
+
default:
|
|
71175
|
+
if (ch >= 48 && ch <= 55) {
|
|
71176
|
+
const startPos = pos - 1;
|
|
71177
|
+
const match = input.slice(startPos, pos + 2).match(/^[0-7]+/);
|
|
71178
|
+
let octalStr = match[0];
|
|
71179
|
+
let octal = parseInt(octalStr, 8);
|
|
71180
|
+
if (octal > 255) {
|
|
71181
|
+
octalStr = octalStr.slice(0, -1);
|
|
71182
|
+
octal = parseInt(octalStr, 8);
|
|
71183
|
+
}
|
|
71184
|
+
pos += octalStr.length - 1;
|
|
71185
|
+
const next = input.charCodeAt(pos);
|
|
71186
|
+
if (octalStr !== "0" || next === 56 || next === 57) {
|
|
71187
|
+
if (inTemplate) {
|
|
71188
|
+
return res(null);
|
|
71189
|
+
} else {
|
|
71190
|
+
errors.strictNumericEscape(startPos, lineStart, curLine);
|
|
71191
|
+
}
|
|
71192
|
+
}
|
|
71193
|
+
return res(String.fromCharCode(octal));
|
|
71194
|
+
}
|
|
71195
|
+
return res(String.fromCharCode(ch));
|
|
71196
|
+
}
|
|
71197
|
+
}
|
|
71198
|
+
function readHexChar(input, pos, lineStart, curLine, len, forceLen, throwOnInvalid, errors) {
|
|
71199
|
+
const initialPos = pos;
|
|
71200
|
+
let n;
|
|
71201
|
+
({
|
|
71202
|
+
n,
|
|
71203
|
+
pos
|
|
71204
|
+
} = readInt(input, pos, lineStart, curLine, 16, len, forceLen, false, errors, !throwOnInvalid));
|
|
71205
|
+
if (n === null) {
|
|
71206
|
+
if (throwOnInvalid) {
|
|
71207
|
+
errors.invalidEscapeSequence(initialPos, lineStart, curLine);
|
|
71208
|
+
} else {
|
|
71209
|
+
pos = initialPos - 1;
|
|
71210
|
+
}
|
|
71211
|
+
}
|
|
71212
|
+
return {
|
|
71213
|
+
code: n,
|
|
71214
|
+
pos
|
|
71215
|
+
};
|
|
71216
|
+
}
|
|
71217
|
+
function readInt(input, pos, lineStart, curLine, radix, len, forceLen, allowNumSeparator, errors, bailOnError) {
|
|
71218
|
+
const start = pos;
|
|
71219
|
+
const forbiddenSiblings = radix === 16 ? forbiddenNumericSeparatorSiblings.hex : forbiddenNumericSeparatorSiblings.decBinOct;
|
|
71220
|
+
const isAllowedSibling = radix === 16 ? isAllowedNumericSeparatorSibling.hex : radix === 10 ? isAllowedNumericSeparatorSibling.dec : radix === 8 ? isAllowedNumericSeparatorSibling.oct : isAllowedNumericSeparatorSibling.bin;
|
|
71221
|
+
let invalid = false;
|
|
71222
|
+
let total = 0;
|
|
71223
|
+
for (let i = 0, e = len == null ? Infinity : len; i < e; ++i) {
|
|
71224
|
+
const code = input.charCodeAt(pos);
|
|
71225
|
+
let val;
|
|
71226
|
+
if (code === 95 && allowNumSeparator !== "bail") {
|
|
71227
|
+
const prev = input.charCodeAt(pos - 1);
|
|
71228
|
+
const next = input.charCodeAt(pos + 1);
|
|
71229
|
+
if (!allowNumSeparator) {
|
|
71230
|
+
if (bailOnError) return {
|
|
71231
|
+
n: null,
|
|
71232
|
+
pos
|
|
71233
|
+
};
|
|
71234
|
+
errors.numericSeparatorInEscapeSequence(pos, lineStart, curLine);
|
|
71235
|
+
} else if (Number.isNaN(next) || !isAllowedSibling(next) || forbiddenSiblings.has(prev) || forbiddenSiblings.has(next)) {
|
|
71236
|
+
if (bailOnError) return {
|
|
71237
|
+
n: null,
|
|
71238
|
+
pos
|
|
71239
|
+
};
|
|
71240
|
+
errors.unexpectedNumericSeparator(pos, lineStart, curLine);
|
|
71241
|
+
}
|
|
71242
|
+
++pos;
|
|
71243
|
+
continue;
|
|
71244
|
+
}
|
|
71245
|
+
if (code >= 97) {
|
|
71246
|
+
val = code - 97 + 10;
|
|
71247
|
+
} else if (code >= 65) {
|
|
71248
|
+
val = code - 65 + 10;
|
|
71249
|
+
} else if (_isDigit(code)) {
|
|
71250
|
+
val = code - 48;
|
|
71251
|
+
} else {
|
|
71252
|
+
val = Infinity;
|
|
71253
|
+
}
|
|
71254
|
+
if (val >= radix) {
|
|
71255
|
+
if (val <= 9 && bailOnError) {
|
|
71256
|
+
return {
|
|
71257
|
+
n: null,
|
|
71258
|
+
pos
|
|
71259
|
+
};
|
|
71260
|
+
} else if (val <= 9 && errors.invalidDigit(pos, lineStart, curLine, radix)) {
|
|
71261
|
+
val = 0;
|
|
71262
|
+
} else if (forceLen) {
|
|
71263
|
+
val = 0;
|
|
71264
|
+
invalid = true;
|
|
71265
|
+
} else {
|
|
71266
|
+
break;
|
|
71267
|
+
}
|
|
71268
|
+
}
|
|
71269
|
+
++pos;
|
|
71270
|
+
total = total * radix + val;
|
|
71271
|
+
}
|
|
71272
|
+
if (pos === start || len != null && pos - start !== len || invalid) {
|
|
71273
|
+
return {
|
|
71274
|
+
n: null,
|
|
71275
|
+
pos
|
|
71276
|
+
};
|
|
71277
|
+
}
|
|
71278
|
+
return {
|
|
71279
|
+
n: total,
|
|
71280
|
+
pos
|
|
71281
|
+
};
|
|
71282
|
+
}
|
|
71283
|
+
function readCodePoint(input, pos, lineStart, curLine, throwOnInvalid, errors) {
|
|
71284
|
+
const ch = input.charCodeAt(pos);
|
|
71285
|
+
let code;
|
|
71286
|
+
if (ch === 123) {
|
|
71287
|
+
++pos;
|
|
71288
|
+
({
|
|
71289
|
+
code,
|
|
71290
|
+
pos
|
|
71291
|
+
} = readHexChar(input, pos, lineStart, curLine, input.indexOf("}", pos) - pos, true, throwOnInvalid, errors));
|
|
71292
|
+
++pos;
|
|
71293
|
+
if (code !== null && code > 0x10ffff) {
|
|
71294
|
+
if (throwOnInvalid) {
|
|
71295
|
+
errors.invalidCodePoint(pos, lineStart, curLine);
|
|
71296
|
+
} else {
|
|
71297
|
+
return {
|
|
71298
|
+
code: null,
|
|
71299
|
+
pos
|
|
71300
|
+
};
|
|
71301
|
+
}
|
|
71302
|
+
}
|
|
71303
|
+
} else {
|
|
71304
|
+
({
|
|
71305
|
+
code,
|
|
71306
|
+
pos
|
|
71307
|
+
} = readHexChar(input, pos, lineStart, curLine, 4, false, throwOnInvalid, errors));
|
|
71308
|
+
}
|
|
71309
|
+
return {
|
|
71310
|
+
code,
|
|
71311
|
+
pos
|
|
71312
|
+
};
|
|
71313
|
+
}
|
|
71314
|
+
|
|
71315
|
+
|
|
71316
|
+
return lib$m;
|
|
71317
|
+
}
|
|
71318
|
+
|
|
71319
|
+
var constants$4 = {};
|
|
71320
|
+
|
|
71321
|
+
Object.defineProperty(constants$4, "__esModule", {
|
|
71322
|
+
value: true
|
|
71323
|
+
});
|
|
71324
|
+
constants$4.UPDATE_OPERATORS = constants$4.UNARY_OPERATORS = constants$4.STRING_UNARY_OPERATORS = constants$4.STATEMENT_OR_BLOCK_KEYS = constants$4.NUMBER_UNARY_OPERATORS = constants$4.NUMBER_BINARY_OPERATORS = constants$4.NOT_LOCAL_BINDING = constants$4.LOGICAL_OPERATORS = constants$4.INHERIT_KEYS = constants$4.FOR_INIT_KEYS = constants$4.FLATTENABLE_KEYS = constants$4.EQUALITY_BINARY_OPERATORS = constants$4.COMPARISON_BINARY_OPERATORS = constants$4.COMMENT_KEYS = constants$4.BOOLEAN_UNARY_OPERATORS = constants$4.BOOLEAN_NUMBER_BINARY_OPERATORS = constants$4.BOOLEAN_BINARY_OPERATORS = constants$4.BLOCK_SCOPED_SYMBOL = constants$4.BINARY_OPERATORS = constants$4.ASSIGNMENT_OPERATORS = void 0;
|
|
71325
|
+
const STATEMENT_OR_BLOCK_KEYS$5 = ["consequent", "body", "alternate"];
|
|
71326
|
+
constants$4.STATEMENT_OR_BLOCK_KEYS = STATEMENT_OR_BLOCK_KEYS$5;
|
|
71327
|
+
const FLATTENABLE_KEYS$4 = ["body", "expressions"];
|
|
71328
|
+
constants$4.FLATTENABLE_KEYS = FLATTENABLE_KEYS$4;
|
|
71329
|
+
const FOR_INIT_KEYS$4 = ["left", "init"];
|
|
71330
|
+
constants$4.FOR_INIT_KEYS = FOR_INIT_KEYS$4;
|
|
71331
|
+
const COMMENT_KEYS$4 = ["leadingComments", "trailingComments", "innerComments"];
|
|
71332
|
+
constants$4.COMMENT_KEYS = COMMENT_KEYS$4;
|
|
71333
|
+
const LOGICAL_OPERATORS$5 = ["||", "&&", "??"];
|
|
71334
|
+
constants$4.LOGICAL_OPERATORS = LOGICAL_OPERATORS$5;
|
|
71335
|
+
const UPDATE_OPERATORS$4 = ["++", "--"];
|
|
71336
|
+
constants$4.UPDATE_OPERATORS = UPDATE_OPERATORS$4;
|
|
71337
|
+
const BOOLEAN_NUMBER_BINARY_OPERATORS$5 = [">", "<", ">=", "<="];
|
|
71338
|
+
constants$4.BOOLEAN_NUMBER_BINARY_OPERATORS = BOOLEAN_NUMBER_BINARY_OPERATORS$5;
|
|
71339
|
+
const EQUALITY_BINARY_OPERATORS$4 = ["==", "===", "!=", "!=="];
|
|
71340
|
+
constants$4.EQUALITY_BINARY_OPERATORS = EQUALITY_BINARY_OPERATORS$4;
|
|
71341
|
+
const COMPARISON_BINARY_OPERATORS$4 = [...EQUALITY_BINARY_OPERATORS$4, "in", "instanceof"];
|
|
71342
|
+
constants$4.COMPARISON_BINARY_OPERATORS = COMPARISON_BINARY_OPERATORS$4;
|
|
71343
|
+
const BOOLEAN_BINARY_OPERATORS$4 = [...COMPARISON_BINARY_OPERATORS$4, ...BOOLEAN_NUMBER_BINARY_OPERATORS$5];
|
|
71344
|
+
constants$4.BOOLEAN_BINARY_OPERATORS = BOOLEAN_BINARY_OPERATORS$4;
|
|
71345
|
+
const NUMBER_BINARY_OPERATORS$4 = ["-", "/", "%", "*", "**", "&", "|", ">>", ">>>", "<<", "^"];
|
|
71346
|
+
constants$4.NUMBER_BINARY_OPERATORS = NUMBER_BINARY_OPERATORS$4;
|
|
71347
|
+
const BINARY_OPERATORS$4 = ["+", ...NUMBER_BINARY_OPERATORS$4, ...BOOLEAN_BINARY_OPERATORS$4, "|>"];
|
|
71348
|
+
constants$4.BINARY_OPERATORS = BINARY_OPERATORS$4;
|
|
71349
|
+
const ASSIGNMENT_OPERATORS$4 = ["=", "+=", ...NUMBER_BINARY_OPERATORS$4.map(op => op + "="), ...LOGICAL_OPERATORS$5.map(op => op + "=")];
|
|
71350
|
+
constants$4.ASSIGNMENT_OPERATORS = ASSIGNMENT_OPERATORS$4;
|
|
71351
|
+
const BOOLEAN_UNARY_OPERATORS$4 = ["delete", "!"];
|
|
71352
|
+
constants$4.BOOLEAN_UNARY_OPERATORS = BOOLEAN_UNARY_OPERATORS$4;
|
|
71353
|
+
const NUMBER_UNARY_OPERATORS$4 = ["+", "-", "~"];
|
|
71354
|
+
constants$4.NUMBER_UNARY_OPERATORS = NUMBER_UNARY_OPERATORS$4;
|
|
71355
|
+
const STRING_UNARY_OPERATORS$4 = ["typeof"];
|
|
71356
|
+
constants$4.STRING_UNARY_OPERATORS = STRING_UNARY_OPERATORS$4;
|
|
71357
|
+
const UNARY_OPERATORS$4 = ["void", "throw", ...BOOLEAN_UNARY_OPERATORS$4, ...NUMBER_UNARY_OPERATORS$4, ...STRING_UNARY_OPERATORS$4];
|
|
71358
|
+
constants$4.UNARY_OPERATORS = UNARY_OPERATORS$4;
|
|
71359
|
+
const INHERIT_KEYS$4 = {
|
|
71360
|
+
optional: ["typeAnnotation", "typeParameters", "returnType"],
|
|
71361
|
+
force: ["start", "loc", "end"]
|
|
71362
|
+
};
|
|
71363
|
+
constants$4.INHERIT_KEYS = INHERIT_KEYS$4;
|
|
71364
|
+
const BLOCK_SCOPED_SYMBOL$4 = Symbol.for("var used to be block scoped");
|
|
71365
|
+
constants$4.BLOCK_SCOPED_SYMBOL = BLOCK_SCOPED_SYMBOL$4;
|
|
71366
|
+
const NOT_LOCAL_BINDING$5 = Symbol.for("should not be considered a local binding");
|
|
71367
|
+
constants$4.NOT_LOCAL_BINDING = NOT_LOCAL_BINDING$5;
|
|
71368
|
+
|
|
71369
|
+
var utils$5 = {};
|
|
71370
|
+
|
|
71371
|
+
var hasRequiredUtils$4;
|
|
71372
|
+
|
|
71373
|
+
function requireUtils$4 () {
|
|
71374
|
+
if (hasRequiredUtils$4) return utils$5;
|
|
71375
|
+
hasRequiredUtils$4 = 1;
|
|
71376
|
+
|
|
71377
|
+
Object.defineProperty(utils$5, "__esModule", {
|
|
71378
|
+
value: true
|
|
71379
|
+
});
|
|
71380
|
+
utils$5.VISITOR_KEYS = utils$5.NODE_PARENT_VALIDATIONS = utils$5.NODE_FIELDS = utils$5.FLIPPED_ALIAS_KEYS = utils$5.DEPRECATED_KEYS = utils$5.BUILDER_KEYS = utils$5.ALIAS_KEYS = void 0;
|
|
71381
|
+
utils$5.arrayOf = arrayOf;
|
|
71382
|
+
utils$5.arrayOfType = arrayOfType;
|
|
71383
|
+
utils$5.assertEach = assertEach;
|
|
71384
|
+
utils$5.assertNodeOrValueType = assertNodeOrValueType;
|
|
71385
|
+
utils$5.assertNodeType = assertNodeType;
|
|
71386
|
+
utils$5.assertOneOf = assertOneOf;
|
|
71387
|
+
utils$5.assertOptionalChainStart = assertOptionalChainStart;
|
|
71388
|
+
utils$5.assertShape = assertShape;
|
|
71389
|
+
utils$5.assertValueType = assertValueType;
|
|
71390
|
+
utils$5.chain = chain;
|
|
71391
|
+
utils$5.default = defineType;
|
|
71392
|
+
utils$5.defineAliasedType = defineAliasedType;
|
|
71393
|
+
utils$5.typeIs = typeIs;
|
|
71394
|
+
utils$5.validate = validate;
|
|
71395
|
+
utils$5.validateArrayOfType = validateArrayOfType;
|
|
71396
|
+
utils$5.validateOptional = validateOptional;
|
|
71397
|
+
utils$5.validateOptionalType = validateOptionalType;
|
|
71398
|
+
utils$5.validateType = validateType;
|
|
71399
|
+
var _is = requireIs$4();
|
|
71400
|
+
var _validate = requireValidate$4();
|
|
71401
|
+
const VISITOR_KEYS = {};
|
|
71402
|
+
utils$5.VISITOR_KEYS = VISITOR_KEYS;
|
|
71403
|
+
const ALIAS_KEYS = {};
|
|
71404
|
+
utils$5.ALIAS_KEYS = ALIAS_KEYS;
|
|
71405
|
+
const FLIPPED_ALIAS_KEYS = {};
|
|
71406
|
+
utils$5.FLIPPED_ALIAS_KEYS = FLIPPED_ALIAS_KEYS;
|
|
71407
|
+
const NODE_FIELDS = {};
|
|
71408
|
+
utils$5.NODE_FIELDS = NODE_FIELDS;
|
|
71409
|
+
const BUILDER_KEYS = {};
|
|
71410
|
+
utils$5.BUILDER_KEYS = BUILDER_KEYS;
|
|
71411
|
+
const DEPRECATED_KEYS = {};
|
|
71412
|
+
utils$5.DEPRECATED_KEYS = DEPRECATED_KEYS;
|
|
71413
|
+
const NODE_PARENT_VALIDATIONS = {};
|
|
71414
|
+
utils$5.NODE_PARENT_VALIDATIONS = NODE_PARENT_VALIDATIONS;
|
|
71415
|
+
function getType(val) {
|
|
71416
|
+
if (Array.isArray(val)) {
|
|
71417
|
+
return "array";
|
|
71418
|
+
} else if (val === null) {
|
|
71419
|
+
return "null";
|
|
71420
|
+
} else {
|
|
71421
|
+
return typeof val;
|
|
71422
|
+
}
|
|
71423
|
+
}
|
|
71424
|
+
function validate(validate) {
|
|
71425
|
+
return {
|
|
71426
|
+
validate
|
|
71427
|
+
};
|
|
71428
|
+
}
|
|
71429
|
+
function typeIs(typeName) {
|
|
71430
|
+
return typeof typeName === "string" ? assertNodeType(typeName) : assertNodeType(...typeName);
|
|
71431
|
+
}
|
|
71432
|
+
function validateType(typeName) {
|
|
71433
|
+
return validate(typeIs(typeName));
|
|
71434
|
+
}
|
|
71435
|
+
function validateOptional(validate) {
|
|
71436
|
+
return {
|
|
71437
|
+
validate,
|
|
71438
|
+
optional: true
|
|
71439
|
+
};
|
|
71440
|
+
}
|
|
71441
|
+
function validateOptionalType(typeName) {
|
|
71442
|
+
return {
|
|
71443
|
+
validate: typeIs(typeName),
|
|
71444
|
+
optional: true
|
|
71445
|
+
};
|
|
71446
|
+
}
|
|
71447
|
+
function arrayOf(elementType) {
|
|
71448
|
+
return chain(assertValueType("array"), assertEach(elementType));
|
|
71449
|
+
}
|
|
71450
|
+
function arrayOfType(typeName) {
|
|
71451
|
+
return arrayOf(typeIs(typeName));
|
|
71452
|
+
}
|
|
71453
|
+
function validateArrayOfType(typeName) {
|
|
71454
|
+
return validate(arrayOfType(typeName));
|
|
71455
|
+
}
|
|
71456
|
+
function assertEach(callback) {
|
|
71457
|
+
function validator(node, key, val) {
|
|
71458
|
+
if (!Array.isArray(val)) return;
|
|
71459
|
+
for (let i = 0; i < val.length; i++) {
|
|
71460
|
+
const subkey = `${key}[${i}]`;
|
|
71461
|
+
const v = val[i];
|
|
71462
|
+
callback(node, subkey, v);
|
|
71463
|
+
(0, _validate.validateChild)(node, subkey, v);
|
|
71464
|
+
}
|
|
71465
|
+
}
|
|
71466
|
+
validator.each = callback;
|
|
71467
|
+
return validator;
|
|
71468
|
+
}
|
|
71469
|
+
function assertOneOf(...values) {
|
|
71470
|
+
function validate(node, key, val) {
|
|
71471
|
+
if (values.indexOf(val) < 0) {
|
|
71472
|
+
throw new TypeError(`Property ${key} expected value to be one of ${JSON.stringify(values)} but got ${JSON.stringify(val)}`);
|
|
71473
|
+
}
|
|
71474
|
+
}
|
|
71475
|
+
validate.oneOf = values;
|
|
71476
|
+
return validate;
|
|
71477
|
+
}
|
|
71478
|
+
function assertNodeType(...types) {
|
|
71479
|
+
function validate(node, key, val) {
|
|
71480
|
+
for (const type of types) {
|
|
71481
|
+
if ((0, _is.default)(type, val)) {
|
|
71482
|
+
(0, _validate.validateChild)(node, key, val);
|
|
71483
|
+
return;
|
|
71484
|
+
}
|
|
71485
|
+
}
|
|
71486
|
+
throw new TypeError(`Property ${key} of ${node.type} expected node to be of a type ${JSON.stringify(types)} but instead got ${JSON.stringify(val == null ? void 0 : val.type)}`);
|
|
71487
|
+
}
|
|
71488
|
+
validate.oneOfNodeTypes = types;
|
|
71489
|
+
return validate;
|
|
71490
|
+
}
|
|
71491
|
+
function assertNodeOrValueType(...types) {
|
|
71492
|
+
function validate(node, key, val) {
|
|
71493
|
+
for (const type of types) {
|
|
71494
|
+
if (getType(val) === type || (0, _is.default)(type, val)) {
|
|
71495
|
+
(0, _validate.validateChild)(node, key, val);
|
|
71496
|
+
return;
|
|
71497
|
+
}
|
|
71498
|
+
}
|
|
71499
|
+
throw new TypeError(`Property ${key} of ${node.type} expected node to be of a type ${JSON.stringify(types)} but instead got ${JSON.stringify(val == null ? void 0 : val.type)}`);
|
|
71500
|
+
}
|
|
71501
|
+
validate.oneOfNodeOrValueTypes = types;
|
|
71502
|
+
return validate;
|
|
71503
|
+
}
|
|
71504
|
+
function assertValueType(type) {
|
|
71505
|
+
function validate(node, key, val) {
|
|
71496
71506
|
const valid = getType(val) === type;
|
|
71497
71507
|
if (!valid) {
|
|
71498
71508
|
throw new TypeError(`Property ${key} expected type of ${type} but got ${getType(val)}`);
|
|
@@ -71658,7 +71668,7 @@ function requireCore$4 () {
|
|
|
71658
71668
|
var _is = requireIs$4();
|
|
71659
71669
|
var _isValidIdentifier = isValidIdentifier$9;
|
|
71660
71670
|
var _helperValidatorIdentifier = lib$n;
|
|
71661
|
-
var _helperStringParser =
|
|
71671
|
+
var _helperStringParser = requireLib$9();
|
|
71662
71672
|
var _constants = constants$4;
|
|
71663
71673
|
var _utils = requireUtils$4();
|
|
71664
71674
|
const defineType = (0, _utils.defineAliasedType)("Standardized");
|
|
@@ -74817,7 +74827,7 @@ function requireValidateNode$4 () {
|
|
|
74817
74827
|
});
|
|
74818
74828
|
validateNode$4.default = validateNode;
|
|
74819
74829
|
var _validate = requireValidate$4();
|
|
74820
|
-
var _ = requireLib$
|
|
74830
|
+
var _ = requireLib$8();
|
|
74821
74831
|
function validateNode(node) {
|
|
74822
74832
|
const keys = _.BUILDER_KEYS[node.type];
|
|
74823
74833
|
for (const key of keys) {
|
|
@@ -76833,7 +76843,7 @@ function requireCleanJSXElementLiteralChild$4 () {
|
|
|
76833
76843
|
});
|
|
76834
76844
|
cleanJSXElementLiteralChild$4.default = cleanJSXElementLiteralChild;
|
|
76835
76845
|
var _generated = requireGenerated$4();
|
|
76836
|
-
var _ = requireLib$
|
|
76846
|
+
var _ = requireLib$8();
|
|
76837
76847
|
function cleanJSXElementLiteralChild(child, args) {
|
|
76838
76848
|
const lines = child.value.split(/\r\n|\n|\r/);
|
|
76839
76849
|
let lastNonEmptyLine = 0;
|
|
@@ -80919,7 +80929,7 @@ function requirePrependToMemberExpression$4 () {
|
|
|
80919
80929
|
});
|
|
80920
80930
|
prependToMemberExpression$4.default = prependToMemberExpression;
|
|
80921
80931
|
var _generated = requireGenerated$4();
|
|
80922
|
-
var _ = requireLib$
|
|
80932
|
+
var _ = requireLib$8();
|
|
80923
80933
|
function prependToMemberExpression(member, prepend) {
|
|
80924
80934
|
if ((0, _.isSuper)(member.object)) {
|
|
80925
80935
|
throw new Error("Cannot prepend node to super property access (`super.foo`).");
|
|
@@ -81271,11 +81281,11 @@ function isVar$9(node) {
|
|
|
81271
81281
|
}) && !node[_constants$k.BLOCK_SCOPED_SYMBOL];
|
|
81272
81282
|
}
|
|
81273
81283
|
|
|
81274
|
-
var hasRequiredLib$
|
|
81284
|
+
var hasRequiredLib$8;
|
|
81275
81285
|
|
|
81276
|
-
function requireLib$
|
|
81277
|
-
if (hasRequiredLib$
|
|
81278
|
-
hasRequiredLib$
|
|
81286
|
+
function requireLib$8 () {
|
|
81287
|
+
if (hasRequiredLib$8) return lib$o;
|
|
81288
|
+
hasRequiredLib$8 = 1;
|
|
81279
81289
|
(function (exports) {
|
|
81280
81290
|
|
|
81281
81291
|
Object.defineProperty(exports, "__esModule", {
|
|
@@ -81858,7 +81868,7 @@ visitors.isExplodedVisitor = isExplodedVisitor;
|
|
|
81858
81868
|
visitors.merge = merge$4;
|
|
81859
81869
|
visitors.verify = verify;
|
|
81860
81870
|
var virtualTypes = virtualTypes$1;
|
|
81861
|
-
var _t$p = requireLib$
|
|
81871
|
+
var _t$p = requireLib$8();
|
|
81862
81872
|
const {
|
|
81863
81873
|
DEPRECATED_KEYS,
|
|
81864
81874
|
DEPRECATED_ALIASES: DEPRECATED_ALIASES$4,
|
|
@@ -82125,7 +82135,7 @@ Object.defineProperty(lib$l, "__esModule", {
|
|
|
82125
82135
|
value: true
|
|
82126
82136
|
});
|
|
82127
82137
|
lib$l.default = splitExportDeclaration;
|
|
82128
|
-
var _t$o = requireLib$
|
|
82138
|
+
var _t$o = requireLib$8();
|
|
82129
82139
|
const {
|
|
82130
82140
|
cloneNode: cloneNode$b,
|
|
82131
82141
|
exportNamedDeclaration,
|
|
@@ -82243,7 +82253,7 @@ function requireRenamer () {
|
|
|
82243
82253
|
});
|
|
82244
82254
|
renamer.default = void 0;
|
|
82245
82255
|
var _helperSplitExportDeclaration = lib$l;
|
|
82246
|
-
var t = requireLib$
|
|
82256
|
+
var t = requireLib$8();
|
|
82247
82257
|
var _helperEnvironmentVisitor = lib$k;
|
|
82248
82258
|
var _traverseNode = requireTraverseNode();
|
|
82249
82259
|
var _visitors = visitors;
|
|
@@ -84048,7 +84058,7 @@ function requireScope () {
|
|
|
84048
84058
|
var _index = requireLib$3();
|
|
84049
84059
|
var _binding = binding;
|
|
84050
84060
|
var _globals = globals;
|
|
84051
|
-
var _t = requireLib$
|
|
84061
|
+
var _t = requireLib$8();
|
|
84052
84062
|
var t = _t;
|
|
84053
84063
|
var _cache = cache;
|
|
84054
84064
|
var _visitors = visitors;
|
|
@@ -86653,7 +86663,7 @@ Object.defineProperty(whitespace$1, "__esModule", {
|
|
|
86653
86663
|
value: true
|
|
86654
86664
|
});
|
|
86655
86665
|
whitespace$1.nodes = void 0;
|
|
86656
|
-
var _t$n = requireLib$
|
|
86666
|
+
var _t$n = requireLib$8();
|
|
86657
86667
|
const {
|
|
86658
86668
|
FLIPPED_ALIAS_KEYS: FLIPPED_ALIAS_KEYS$1,
|
|
86659
86669
|
isArrayExpression: isArrayExpression$6,
|
|
@@ -86821,7 +86831,7 @@ parentheses.UnaryLike = UnaryLike;
|
|
|
86821
86831
|
parentheses.IntersectionTypeAnnotation = parentheses.UnionTypeAnnotation = UnionTypeAnnotation;
|
|
86822
86832
|
parentheses.UpdateExpression = UpdateExpression$1;
|
|
86823
86833
|
parentheses.AwaitExpression = parentheses.YieldExpression = YieldExpression$1;
|
|
86824
|
-
var _t$m = requireLib$
|
|
86834
|
+
var _t$m = requireLib$8();
|
|
86825
86835
|
const {
|
|
86826
86836
|
isArrayTypeAnnotation: isArrayTypeAnnotation$5,
|
|
86827
86837
|
isArrowFunctionExpression: isArrowFunctionExpression$6,
|
|
@@ -87105,7 +87115,7 @@ node.needsWhitespaceAfter = needsWhitespaceAfter;
|
|
|
87105
87115
|
node.needsWhitespaceBefore = needsWhitespaceBefore;
|
|
87106
87116
|
var whitespace = whitespace$1;
|
|
87107
87117
|
var parens$2 = parentheses;
|
|
87108
|
-
var _t$l = requireLib$
|
|
87118
|
+
var _t$l = requireLib$8();
|
|
87109
87119
|
const {
|
|
87110
87120
|
FLIPPED_ALIAS_KEYS,
|
|
87111
87121
|
isCallExpression: isCallExpression$8,
|
|
@@ -87234,7 +87244,7 @@ expressions$2.UpdateExpression = UpdateExpression;
|
|
|
87234
87244
|
expressions$2.V8IntrinsicIdentifier = V8IntrinsicIdentifier;
|
|
87235
87245
|
expressions$2.YieldExpression = YieldExpression;
|
|
87236
87246
|
expressions$2._shouldPrintDecoratorsBeforeExport = _shouldPrintDecoratorsBeforeExport;
|
|
87237
|
-
var _t$k = requireLib$
|
|
87247
|
+
var _t$k = requireLib$8();
|
|
87238
87248
|
var n$1 = node;
|
|
87239
87249
|
const {
|
|
87240
87250
|
isCallExpression: isCallExpression$7,
|
|
@@ -87533,7 +87543,7 @@ statements$4.VariableDeclaration = VariableDeclaration$1;
|
|
|
87533
87543
|
statements$4.VariableDeclarator = VariableDeclarator;
|
|
87534
87544
|
statements$4.WhileStatement = WhileStatement$1;
|
|
87535
87545
|
statements$4.WithStatement = WithStatement;
|
|
87536
|
-
var _t$j = requireLib$
|
|
87546
|
+
var _t$j = requireLib$8();
|
|
87537
87547
|
const {
|
|
87538
87548
|
isFor: isFor$4,
|
|
87539
87549
|
isForStatement: isForStatement$5,
|
|
@@ -87800,7 +87810,7 @@ classes.ClassPrivateProperty = ClassPrivateProperty$1;
|
|
|
87800
87810
|
classes.ClassProperty = ClassProperty$2;
|
|
87801
87811
|
classes.StaticBlock = StaticBlock$1;
|
|
87802
87812
|
classes._classMethodHead = _classMethodHead;
|
|
87803
|
-
var _t$i = requireLib$
|
|
87813
|
+
var _t$i = requireLib$8();
|
|
87804
87814
|
const {
|
|
87805
87815
|
isExportDefaultDeclaration: isExportDefaultDeclaration$4,
|
|
87806
87816
|
isExportNamedDeclaration: isExportNamedDeclaration$4
|
|
@@ -87975,7 +87985,7 @@ methods._param = _param;
|
|
|
87975
87985
|
methods._parameters = _parameters;
|
|
87976
87986
|
methods._params = _params;
|
|
87977
87987
|
methods._predicate = _predicate;
|
|
87978
|
-
var _t$h = requireLib$
|
|
87988
|
+
var _t$h = requireLib$8();
|
|
87979
87989
|
const {
|
|
87980
87990
|
isIdentifier: isIdentifier$k
|
|
87981
87991
|
} = _t$h;
|
|
@@ -88151,7 +88161,7 @@ modules.ImportDefaultSpecifier = ImportDefaultSpecifier;
|
|
|
88151
88161
|
modules.ImportNamespaceSpecifier = ImportNamespaceSpecifier;
|
|
88152
88162
|
modules.ImportSpecifier = ImportSpecifier;
|
|
88153
88163
|
modules._printAttributes = _printAttributes;
|
|
88154
|
-
var _t$g = requireLib$
|
|
88164
|
+
var _t$g = requireLib$8();
|
|
88155
88165
|
const {
|
|
88156
88166
|
isClassDeclaration: isClassDeclaration$4,
|
|
88157
88167
|
isExportDefaultSpecifier: isExportDefaultSpecifier$4,
|
|
@@ -88740,7 +88750,7 @@ types$k.SpreadElement = types$k.RestElement = RestElement$1;
|
|
|
88740
88750
|
types$k.StringLiteral = StringLiteral$1;
|
|
88741
88751
|
types$k.TopicReference = TopicReference;
|
|
88742
88752
|
types$k.TupleExpression = TupleExpression$1;
|
|
88743
|
-
var _t$f = requireLib$
|
|
88753
|
+
var _t$f = requireLib$8();
|
|
88744
88754
|
var _jsesc = jsesc_1;
|
|
88745
88755
|
const {
|
|
88746
88756
|
isAssignmentPattern: isAssignmentPattern$6,
|
|
@@ -89015,7 +89025,7 @@ var flow$5 = {};
|
|
|
89015
89025
|
exports.VoidTypeAnnotation = VoidTypeAnnotation;
|
|
89016
89026
|
exports._interfaceish = _interfaceish;
|
|
89017
89027
|
exports._variance = _variance;
|
|
89018
|
-
var _t = requireLib$
|
|
89028
|
+
var _t = requireLib$8();
|
|
89019
89029
|
var _modules = modules;
|
|
89020
89030
|
var _types2 = types$k;
|
|
89021
89031
|
const {
|
|
@@ -90652,7 +90662,7 @@ Object.defineProperty(printer, "__esModule", {
|
|
|
90652
90662
|
printer.default = void 0;
|
|
90653
90663
|
var _buffer = buffer;
|
|
90654
90664
|
var n = node;
|
|
90655
|
-
var _t$e = requireLib$
|
|
90665
|
+
var _t$e = requireLib$8();
|
|
90656
90666
|
var generatorFunctions = generators;
|
|
90657
90667
|
const {
|
|
90658
90668
|
isFunction: isFunction$8,
|
|
@@ -91400,7 +91410,7 @@ ancestry.getStatementParent = getStatementParent;
|
|
|
91400
91410
|
ancestry.inType = inType;
|
|
91401
91411
|
ancestry.isAncestor = isAncestor;
|
|
91402
91412
|
ancestry.isDescendant = isDescendant;
|
|
91403
|
-
var _t$d = requireLib$
|
|
91413
|
+
var _t$d = requireLib$8();
|
|
91404
91414
|
const {
|
|
91405
91415
|
VISITOR_KEYS: VISITOR_KEYS$1
|
|
91406
91416
|
} = _t$d;
|
|
@@ -91537,7 +91547,7 @@ Object.defineProperty(util, "__esModule", {
|
|
|
91537
91547
|
value: true
|
|
91538
91548
|
});
|
|
91539
91549
|
util.createUnionType = createUnionType;
|
|
91540
|
-
var _t$c = requireLib$
|
|
91550
|
+
var _t$c = requireLib$8();
|
|
91541
91551
|
const {
|
|
91542
91552
|
createFlowUnionType: createFlowUnionType$4,
|
|
91543
91553
|
createTSUnionType: createTSUnionType$4,
|
|
@@ -91564,7 +91574,7 @@ Object.defineProperty(infererReference, "__esModule", {
|
|
|
91564
91574
|
value: true
|
|
91565
91575
|
});
|
|
91566
91576
|
infererReference.default = _default$f;
|
|
91567
|
-
var _t$b = requireLib$
|
|
91577
|
+
var _t$b = requireLib$8();
|
|
91568
91578
|
var _util = util;
|
|
91569
91579
|
const {
|
|
91570
91580
|
BOOLEAN_NUMBER_BINARY_OPERATORS: BOOLEAN_NUMBER_BINARY_OPERATORS$4,
|
|
@@ -91744,7 +91754,7 @@ function getConditionalAnnotation(binding, path, name) {
|
|
|
91744
91754
|
exports.UnaryExpression = UnaryExpression;
|
|
91745
91755
|
exports.UpdateExpression = UpdateExpression;
|
|
91746
91756
|
exports.VariableDeclarator = VariableDeclarator;
|
|
91747
|
-
var _t = requireLib$
|
|
91757
|
+
var _t = requireLib$8();
|
|
91748
91758
|
var _infererReference = infererReference;
|
|
91749
91759
|
var _util = util;
|
|
91750
91760
|
const {
|
|
@@ -91929,7 +91939,7 @@ inference.getTypeAnnotation = getTypeAnnotation;
|
|
|
91929
91939
|
inference.isBaseType = isBaseType;
|
|
91930
91940
|
inference.isGenericType = isGenericType;
|
|
91931
91941
|
var inferers = inferers$1;
|
|
91932
|
-
var _t$a = requireLib$
|
|
91942
|
+
var _t$a = requireLib$8();
|
|
91933
91943
|
const {
|
|
91934
91944
|
anyTypeAnnotation,
|
|
91935
91945
|
isAnyTypeAnnotation: isAnyTypeAnnotation$4,
|
|
@@ -94409,20 +94419,20 @@ let State$2 = class State {
|
|
|
94409
94419
|
return state;
|
|
94410
94420
|
}
|
|
94411
94421
|
};
|
|
94412
|
-
var _isDigit$
|
|
94422
|
+
var _isDigit$1 = function isDigit(code) {
|
|
94413
94423
|
return code >= 48 && code <= 57;
|
|
94414
94424
|
};
|
|
94415
|
-
const forbiddenNumericSeparatorSiblings$
|
|
94425
|
+
const forbiddenNumericSeparatorSiblings$1 = {
|
|
94416
94426
|
decBinOct: new Set([46, 66, 69, 79, 95, 98, 101, 111]),
|
|
94417
94427
|
hex: new Set([46, 88, 95, 120])
|
|
94418
94428
|
};
|
|
94419
|
-
const isAllowedNumericSeparatorSibling$
|
|
94429
|
+
const isAllowedNumericSeparatorSibling$1 = {
|
|
94420
94430
|
bin: ch => ch === 48 || ch === 49,
|
|
94421
94431
|
oct: ch => ch >= 48 && ch <= 55,
|
|
94422
94432
|
dec: ch => ch >= 48 && ch <= 57,
|
|
94423
94433
|
hex: ch => ch >= 48 && ch <= 57 || ch >= 65 && ch <= 70 || ch >= 97 && ch <= 102
|
|
94424
94434
|
};
|
|
94425
|
-
function readStringContents$
|
|
94435
|
+
function readStringContents$1(type, input, pos, lineStart, curLine, errors) {
|
|
94426
94436
|
const initialPos = pos;
|
|
94427
94437
|
const initialLineStart = lineStart;
|
|
94428
94438
|
const initialCurLine = curLine;
|
|
@@ -94439,13 +94449,13 @@ function readStringContents$2(type, input, pos, lineStart, curLine, errors) {
|
|
|
94439
94449
|
break;
|
|
94440
94450
|
}
|
|
94441
94451
|
const ch = input.charCodeAt(pos);
|
|
94442
|
-
if (isStringEnd$
|
|
94452
|
+
if (isStringEnd$1(type, ch, input, pos)) {
|
|
94443
94453
|
out += input.slice(chunkStart, pos);
|
|
94444
94454
|
break;
|
|
94445
94455
|
}
|
|
94446
94456
|
if (ch === 92) {
|
|
94447
94457
|
out += input.slice(chunkStart, pos);
|
|
94448
|
-
const res = readEscapedChar$
|
|
94458
|
+
const res = readEscapedChar$1(input, pos, lineStart, curLine, type === "template", errors);
|
|
94449
94459
|
if (res.ch === null && !firstInvalidLoc) {
|
|
94450
94460
|
firstInvalidLoc = {
|
|
94451
94461
|
pos,
|
|
@@ -94490,13 +94500,13 @@ function readStringContents$2(type, input, pos, lineStart, curLine, errors) {
|
|
|
94490
94500
|
containsInvalid: !!firstInvalidLoc
|
|
94491
94501
|
};
|
|
94492
94502
|
}
|
|
94493
|
-
function isStringEnd$
|
|
94503
|
+
function isStringEnd$1(type, ch, input, pos) {
|
|
94494
94504
|
if (type === "template") {
|
|
94495
94505
|
return ch === 96 || ch === 36 && input.charCodeAt(pos + 1) === 123;
|
|
94496
94506
|
}
|
|
94497
94507
|
return ch === (type === "double" ? 34 : 39);
|
|
94498
94508
|
}
|
|
94499
|
-
function readEscapedChar$
|
|
94509
|
+
function readEscapedChar$1(input, pos, lineStart, curLine, inTemplate, errors) {
|
|
94500
94510
|
const throwOnInvalid = !inTemplate;
|
|
94501
94511
|
pos++;
|
|
94502
94512
|
const res = ch => ({
|
|
@@ -94517,7 +94527,7 @@ function readEscapedChar$2(input, pos, lineStart, curLine, inTemplate, errors) {
|
|
|
94517
94527
|
({
|
|
94518
94528
|
code,
|
|
94519
94529
|
pos
|
|
94520
|
-
} = readHexChar$
|
|
94530
|
+
} = readHexChar$1(input, pos, lineStart, curLine, 2, false, throwOnInvalid, errors));
|
|
94521
94531
|
return res(code === null ? null : String.fromCharCode(code));
|
|
94522
94532
|
}
|
|
94523
94533
|
case 117:
|
|
@@ -94526,7 +94536,7 @@ function readEscapedChar$2(input, pos, lineStart, curLine, inTemplate, errors) {
|
|
|
94526
94536
|
({
|
|
94527
94537
|
code,
|
|
94528
94538
|
pos
|
|
94529
|
-
} = readCodePoint$
|
|
94539
|
+
} = readCodePoint$1(input, pos, lineStart, curLine, throwOnInvalid, errors));
|
|
94530
94540
|
return res(code === null ? null : String.fromCodePoint(code));
|
|
94531
94541
|
}
|
|
94532
94542
|
case 116:
|
|
@@ -94578,13 +94588,13 @@ function readEscapedChar$2(input, pos, lineStart, curLine, inTemplate, errors) {
|
|
|
94578
94588
|
return res(String.fromCharCode(ch));
|
|
94579
94589
|
}
|
|
94580
94590
|
}
|
|
94581
|
-
function readHexChar$
|
|
94591
|
+
function readHexChar$1(input, pos, lineStart, curLine, len, forceLen, throwOnInvalid, errors) {
|
|
94582
94592
|
const initialPos = pos;
|
|
94583
94593
|
let n;
|
|
94584
94594
|
({
|
|
94585
94595
|
n,
|
|
94586
94596
|
pos
|
|
94587
|
-
} = readInt$
|
|
94597
|
+
} = readInt$1(input, pos, lineStart, curLine, 16, len, forceLen, false, errors, !throwOnInvalid));
|
|
94588
94598
|
if (n === null) {
|
|
94589
94599
|
if (throwOnInvalid) {
|
|
94590
94600
|
errors.invalidEscapeSequence(initialPos, lineStart, curLine);
|
|
@@ -94597,10 +94607,10 @@ function readHexChar$2(input, pos, lineStart, curLine, len, forceLen, throwOnInv
|
|
|
94597
94607
|
pos
|
|
94598
94608
|
};
|
|
94599
94609
|
}
|
|
94600
|
-
function readInt$
|
|
94610
|
+
function readInt$1(input, pos, lineStart, curLine, radix, len, forceLen, allowNumSeparator, errors, bailOnError) {
|
|
94601
94611
|
const start = pos;
|
|
94602
|
-
const forbiddenSiblings = radix === 16 ? forbiddenNumericSeparatorSiblings$
|
|
94603
|
-
const isAllowedSibling = radix === 16 ? isAllowedNumericSeparatorSibling$
|
|
94612
|
+
const forbiddenSiblings = radix === 16 ? forbiddenNumericSeparatorSiblings$1.hex : forbiddenNumericSeparatorSiblings$1.decBinOct;
|
|
94613
|
+
const isAllowedSibling = radix === 16 ? isAllowedNumericSeparatorSibling$1.hex : radix === 10 ? isAllowedNumericSeparatorSibling$1.dec : radix === 8 ? isAllowedNumericSeparatorSibling$1.oct : isAllowedNumericSeparatorSibling$1.bin;
|
|
94604
94614
|
let invalid = false;
|
|
94605
94615
|
let total = 0;
|
|
94606
94616
|
for (let i = 0, e = len == null ? Infinity : len; i < e; ++i) {
|
|
@@ -94629,7 +94639,7 @@ function readInt$2(input, pos, lineStart, curLine, radix, len, forceLen, allowNu
|
|
|
94629
94639
|
val = code - 97 + 10;
|
|
94630
94640
|
} else if (code >= 65) {
|
|
94631
94641
|
val = code - 65 + 10;
|
|
94632
|
-
} else if (_isDigit$
|
|
94642
|
+
} else if (_isDigit$1(code)) {
|
|
94633
94643
|
val = code - 48;
|
|
94634
94644
|
} else {
|
|
94635
94645
|
val = Infinity;
|
|
@@ -94663,7 +94673,7 @@ function readInt$2(input, pos, lineStart, curLine, radix, len, forceLen, allowNu
|
|
|
94663
94673
|
pos
|
|
94664
94674
|
};
|
|
94665
94675
|
}
|
|
94666
|
-
function readCodePoint$
|
|
94676
|
+
function readCodePoint$1(input, pos, lineStart, curLine, throwOnInvalid, errors) {
|
|
94667
94677
|
const ch = input.charCodeAt(pos);
|
|
94668
94678
|
let code;
|
|
94669
94679
|
if (ch === 123) {
|
|
@@ -94671,7 +94681,7 @@ function readCodePoint$2(input, pos, lineStart, curLine, throwOnInvalid, errors)
|
|
|
94671
94681
|
({
|
|
94672
94682
|
code,
|
|
94673
94683
|
pos
|
|
94674
|
-
} = readHexChar$
|
|
94684
|
+
} = readHexChar$1(input, pos, lineStart, curLine, input.indexOf("}", pos) - pos, true, throwOnInvalid, errors));
|
|
94675
94685
|
++pos;
|
|
94676
94686
|
if (code !== null && code > 0x10ffff) {
|
|
94677
94687
|
if (throwOnInvalid) {
|
|
@@ -94687,7 +94697,7 @@ function readCodePoint$2(input, pos, lineStart, curLine, throwOnInvalid, errors)
|
|
|
94687
94697
|
({
|
|
94688
94698
|
code,
|
|
94689
94699
|
pos
|
|
94690
|
-
} = readHexChar$
|
|
94700
|
+
} = readHexChar$1(input, pos, lineStart, curLine, 4, false, throwOnInvalid, errors));
|
|
94691
94701
|
}
|
|
94692
94702
|
return {
|
|
94693
94703
|
code,
|
|
@@ -95484,7 +95494,7 @@ class Tokenizer extends CommentsParser {
|
|
|
95484
95494
|
const {
|
|
95485
95495
|
n,
|
|
95486
95496
|
pos
|
|
95487
|
-
} = readInt$
|
|
95497
|
+
} = readInt$1(this.input, this.state.pos, this.state.lineStart, this.state.curLine, radix, len, forceLen, allowNumSeparator, this.errorHandlers_readInt, false);
|
|
95488
95498
|
this.state.pos = pos;
|
|
95489
95499
|
return n;
|
|
95490
95500
|
}
|
|
@@ -95610,7 +95620,7 @@ class Tokenizer extends CommentsParser {
|
|
|
95610
95620
|
const {
|
|
95611
95621
|
code,
|
|
95612
95622
|
pos
|
|
95613
|
-
} = readCodePoint$
|
|
95623
|
+
} = readCodePoint$1(this.input, this.state.pos, this.state.lineStart, this.state.curLine, throwOnInvalid, this.errorHandlers_readCodePoint);
|
|
95614
95624
|
this.state.pos = pos;
|
|
95615
95625
|
return code;
|
|
95616
95626
|
}
|
|
@@ -95620,7 +95630,7 @@ class Tokenizer extends CommentsParser {
|
|
|
95620
95630
|
pos,
|
|
95621
95631
|
curLine,
|
|
95622
95632
|
lineStart
|
|
95623
|
-
} = readStringContents$
|
|
95633
|
+
} = readStringContents$1(quote === 34 ? "double" : "single", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_string);
|
|
95624
95634
|
this.state.pos = pos + 1;
|
|
95625
95635
|
this.state.lineStart = lineStart;
|
|
95626
95636
|
this.state.curLine = curLine;
|
|
@@ -95641,7 +95651,7 @@ class Tokenizer extends CommentsParser {
|
|
|
95641
95651
|
pos,
|
|
95642
95652
|
curLine,
|
|
95643
95653
|
lineStart
|
|
95644
|
-
} = readStringContents$
|
|
95654
|
+
} = readStringContents$1("template", this.input, this.state.pos + 1, this.state.lineStart, this.state.curLine, this.errorHandlers_readStringContents_template);
|
|
95645
95655
|
this.state.pos = pos + 1;
|
|
95646
95656
|
this.state.lineStart = lineStart;
|
|
95647
95657
|
this.state.curLine = curLine;
|
|
@@ -110106,11 +110116,11 @@ function isValidIdentifier$6(name, reserved = true) {
|
|
|
110106
110116
|
|
|
110107
110117
|
var lib$b = {};
|
|
110108
110118
|
|
|
110109
|
-
var hasRequiredLib$
|
|
110119
|
+
var hasRequiredLib$7;
|
|
110110
110120
|
|
|
110111
|
-
function requireLib$
|
|
110112
|
-
if (hasRequiredLib$
|
|
110113
|
-
hasRequiredLib$
|
|
110121
|
+
function requireLib$7 () {
|
|
110122
|
+
if (hasRequiredLib$7) return lib$b;
|
|
110123
|
+
hasRequiredLib$7 = 1;
|
|
110114
110124
|
|
|
110115
110125
|
Object.defineProperty(lib$b, "__esModule", {
|
|
110116
110126
|
value: true
|
|
@@ -110760,7 +110770,7 @@ function requireCore$3 () {
|
|
|
110760
110770
|
var _is = requireIs$3();
|
|
110761
110771
|
var _isValidIdentifier = isValidIdentifier$7;
|
|
110762
110772
|
var _helperValidatorIdentifier = lib$c;
|
|
110763
|
-
var _helperStringParser = requireLib$
|
|
110773
|
+
var _helperStringParser = requireLib$7();
|
|
110764
110774
|
var _constants = constants$3;
|
|
110765
110775
|
var _utils = requireUtils$3();
|
|
110766
110776
|
const defineType = (0, _utils.defineAliasedType)("Standardized");
|
|
@@ -113919,7 +113929,7 @@ function requireValidateNode$3 () {
|
|
|
113919
113929
|
});
|
|
113920
113930
|
validateNode$3.default = validateNode;
|
|
113921
113931
|
var _validate = requireValidate$3();
|
|
113922
|
-
var _ = requireLib$
|
|
113932
|
+
var _ = requireLib$6();
|
|
113923
113933
|
function validateNode(node) {
|
|
113924
113934
|
const keys = _.BUILDER_KEYS[node.type];
|
|
113925
113935
|
for (const key of keys) {
|
|
@@ -115935,7 +115945,7 @@ function requireCleanJSXElementLiteralChild$3 () {
|
|
|
115935
115945
|
});
|
|
115936
115946
|
cleanJSXElementLiteralChild$3.default = cleanJSXElementLiteralChild;
|
|
115937
115947
|
var _generated = requireGenerated$3();
|
|
115938
|
-
var _ = requireLib$
|
|
115948
|
+
var _ = requireLib$6();
|
|
115939
115949
|
function cleanJSXElementLiteralChild(child, args) {
|
|
115940
115950
|
const lines = child.value.split(/\r\n|\n|\r/);
|
|
115941
115951
|
let lastNonEmptyLine = 0;
|
|
@@ -120021,7 +120031,7 @@ function requirePrependToMemberExpression$3 () {
|
|
|
120021
120031
|
});
|
|
120022
120032
|
prependToMemberExpression$3.default = prependToMemberExpression;
|
|
120023
120033
|
var _generated = requireGenerated$3();
|
|
120024
|
-
var _ = requireLib$
|
|
120034
|
+
var _ = requireLib$6();
|
|
120025
120035
|
function prependToMemberExpression(member, prepend) {
|
|
120026
120036
|
if ((0, _.isSuper)(member.object)) {
|
|
120027
120037
|
throw new Error("Cannot prepend node to super property access (`super.foo`).");
|
|
@@ -120373,11 +120383,11 @@ function isVar$7(node) {
|
|
|
120373
120383
|
}) && !node[_constants$f.BLOCK_SCOPED_SYMBOL];
|
|
120374
120384
|
}
|
|
120375
120385
|
|
|
120376
|
-
var hasRequiredLib$
|
|
120386
|
+
var hasRequiredLib$6;
|
|
120377
120387
|
|
|
120378
|
-
function requireLib$
|
|
120379
|
-
if (hasRequiredLib$
|
|
120380
|
-
hasRequiredLib$
|
|
120388
|
+
function requireLib$6 () {
|
|
120389
|
+
if (hasRequiredLib$6) return lib$d;
|
|
120390
|
+
hasRequiredLib$6 = 1;
|
|
120381
120391
|
(function (exports) {
|
|
120382
120392
|
|
|
120383
120393
|
Object.defineProperty(exports, "__esModule", {
|
|
@@ -120956,7 +120966,7 @@ Object.defineProperty(lib$e, "__esModule", {
|
|
|
120956
120966
|
value: true
|
|
120957
120967
|
});
|
|
120958
120968
|
lib$e.default = hoistVariables;
|
|
120959
|
-
var _t$9 = requireLib$
|
|
120969
|
+
var _t$9 = requireLib$6();
|
|
120960
120970
|
const {
|
|
120961
120971
|
assignmentExpression: assignmentExpression$2,
|
|
120962
120972
|
expressionStatement: expressionStatement$3,
|
|
@@ -121019,7 +121029,7 @@ function requireReplacement () {
|
|
|
121019
121029
|
var _index2 = requirePath();
|
|
121020
121030
|
var _cache = cache;
|
|
121021
121031
|
var _parser = lib$f;
|
|
121022
|
-
var _t = requireLib$
|
|
121032
|
+
var _t = requireLib$8();
|
|
121023
121033
|
var _helperHoistVariables = lib$e;
|
|
121024
121034
|
const {
|
|
121025
121035
|
FUNCTION_TYPES,
|
|
@@ -124750,296 +124760,306 @@ function isValidIdentifier$4(name, reserved = true) {
|
|
|
124750
124760
|
|
|
124751
124761
|
var lib$6 = {};
|
|
124752
124762
|
|
|
124753
|
-
|
|
124754
|
-
|
|
124755
|
-
|
|
124756
|
-
|
|
124757
|
-
|
|
124758
|
-
|
|
124759
|
-
|
|
124760
|
-
|
|
124761
|
-
};
|
|
124762
|
-
|
|
124763
|
-
|
|
124764
|
-
|
|
124765
|
-
|
|
124766
|
-
|
|
124767
|
-
|
|
124768
|
-
|
|
124769
|
-
|
|
124770
|
-
|
|
124771
|
-
};
|
|
124772
|
-
|
|
124773
|
-
|
|
124774
|
-
|
|
124775
|
-
|
|
124776
|
-
|
|
124777
|
-
|
|
124778
|
-
|
|
124779
|
-
|
|
124780
|
-
|
|
124781
|
-
|
|
124782
|
-
|
|
124783
|
-
|
|
124784
|
-
|
|
124785
|
-
|
|
124786
|
-
|
|
124787
|
-
|
|
124788
|
-
|
|
124789
|
-
|
|
124790
|
-
|
|
124791
|
-
|
|
124792
|
-
|
|
124793
|
-
|
|
124794
|
-
|
|
124795
|
-
|
|
124796
|
-
|
|
124797
|
-
|
|
124798
|
-
|
|
124799
|
-
|
|
124800
|
-
|
|
124801
|
-
|
|
124802
|
-
|
|
124803
|
-
|
|
124804
|
-
|
|
124805
|
-
|
|
124806
|
-
|
|
124807
|
-
|
|
124808
|
-
|
|
124809
|
-
|
|
124810
|
-
|
|
124811
|
-
|
|
124812
|
-
|
|
124813
|
-
|
|
124814
|
-
|
|
124815
|
-
|
|
124816
|
-
|
|
124817
|
-
|
|
124818
|
-
|
|
124819
|
-
|
|
124820
|
-
|
|
124821
|
-
|
|
124822
|
-
|
|
124823
|
-
|
|
124824
|
-
|
|
124825
|
-
|
|
124826
|
-
|
|
124827
|
-
|
|
124828
|
-
|
|
124829
|
-
|
|
124830
|
-
|
|
124831
|
-
|
|
124832
|
-
|
|
124833
|
-
|
|
124834
|
-
|
|
124835
|
-
|
|
124836
|
-
|
|
124837
|
-
|
|
124838
|
-
|
|
124839
|
-
|
|
124840
|
-
|
|
124841
|
-
|
|
124842
|
-
|
|
124843
|
-
|
|
124844
|
-
|
|
124845
|
-
}
|
|
124846
|
-
function
|
|
124847
|
-
|
|
124848
|
-
|
|
124849
|
-
|
|
124850
|
-
|
|
124851
|
-
|
|
124852
|
-
|
|
124853
|
-
|
|
124854
|
-
|
|
124855
|
-
|
|
124856
|
-
|
|
124857
|
-
|
|
124858
|
-
|
|
124859
|
-
|
|
124860
|
-
|
|
124861
|
-
|
|
124862
|
-
|
|
124863
|
-
|
|
124864
|
-
|
|
124865
|
-
|
|
124866
|
-
|
|
124867
|
-
|
|
124868
|
-
|
|
124869
|
-
|
|
124870
|
-
|
|
124871
|
-
|
|
124872
|
-
|
|
124873
|
-
|
|
124874
|
-
|
|
124875
|
-
|
|
124876
|
-
|
|
124877
|
-
|
|
124878
|
-
|
|
124879
|
-
|
|
124880
|
-
|
|
124881
|
-
|
|
124882
|
-
|
|
124883
|
-
|
|
124884
|
-
|
|
124885
|
-
|
|
124886
|
-
|
|
124887
|
-
|
|
124888
|
-
|
|
124889
|
-
|
|
124890
|
-
|
|
124891
|
-
|
|
124892
|
-
|
|
124893
|
-
|
|
124894
|
-
|
|
124895
|
-
|
|
124896
|
-
|
|
124897
|
-
|
|
124898
|
-
|
|
124899
|
-
|
|
124900
|
-
|
|
124901
|
-
|
|
124902
|
-
|
|
124903
|
-
|
|
124904
|
-
|
|
124905
|
-
|
|
124906
|
-
|
|
124907
|
-
|
|
124908
|
-
|
|
124909
|
-
|
|
124910
|
-
|
|
124911
|
-
|
|
124912
|
-
|
|
124913
|
-
|
|
124914
|
-
|
|
124915
|
-
|
|
124916
|
-
|
|
124917
|
-
|
|
124918
|
-
|
|
124919
|
-
|
|
124920
|
-
|
|
124921
|
-
|
|
124922
|
-
|
|
124923
|
-
|
|
124924
|
-
|
|
124925
|
-
|
|
124926
|
-
|
|
124927
|
-
}
|
|
124928
|
-
|
|
124929
|
-
|
|
124930
|
-
|
|
124931
|
-
|
|
124932
|
-
|
|
124933
|
-
|
|
124934
|
-
|
|
124935
|
-
|
|
124936
|
-
|
|
124937
|
-
|
|
124938
|
-
|
|
124939
|
-
|
|
124940
|
-
|
|
124941
|
-
|
|
124942
|
-
|
|
124943
|
-
|
|
124944
|
-
|
|
124945
|
-
|
|
124946
|
-
}
|
|
124947
|
-
|
|
124948
|
-
|
|
124949
|
-
|
|
124950
|
-
|
|
124951
|
-
|
|
124952
|
-
|
|
124953
|
-
|
|
124954
|
-
|
|
124955
|
-
|
|
124956
|
-
|
|
124957
|
-
|
|
124958
|
-
|
|
124959
|
-
|
|
124960
|
-
|
|
124961
|
-
|
|
124962
|
-
|
|
124963
|
-
|
|
124964
|
-
|
|
124965
|
-
|
|
124966
|
-
|
|
124967
|
-
|
|
124968
|
-
|
|
124969
|
-
|
|
124970
|
-
|
|
124971
|
-
|
|
124972
|
-
|
|
124973
|
-
|
|
124974
|
-
|
|
124975
|
-
|
|
124976
|
-
|
|
124977
|
-
|
|
124978
|
-
|
|
124979
|
-
|
|
124980
|
-
|
|
124981
|
-
|
|
124982
|
-
|
|
124983
|
-
|
|
124984
|
-
|
|
124985
|
-
|
|
124986
|
-
|
|
124987
|
-
|
|
124988
|
-
|
|
124989
|
-
|
|
124990
|
-
|
|
124991
|
-
|
|
124992
|
-
|
|
124993
|
-
|
|
124994
|
-
|
|
124995
|
-
|
|
124996
|
-
|
|
124997
|
-
|
|
124998
|
-
|
|
124999
|
-
|
|
125000
|
-
|
|
125001
|
-
|
|
125002
|
-
|
|
125003
|
-
|
|
125004
|
-
|
|
125005
|
-
|
|
125006
|
-
|
|
125007
|
-
|
|
125008
|
-
|
|
125009
|
-
|
|
125010
|
-
|
|
125011
|
-
|
|
125012
|
-
}
|
|
125013
|
-
|
|
125014
|
-
|
|
125015
|
-
|
|
125016
|
-
|
|
125017
|
-
|
|
125018
|
-
|
|
125019
|
-
|
|
125020
|
-
|
|
125021
|
-
|
|
125022
|
-
|
|
125023
|
-
|
|
125024
|
-
|
|
125025
|
-
|
|
125026
|
-
|
|
125027
|
-
|
|
125028
|
-
|
|
125029
|
-
|
|
125030
|
-
|
|
125031
|
-
|
|
125032
|
-
|
|
125033
|
-
|
|
125034
|
-
|
|
125035
|
-
|
|
125036
|
-
|
|
125037
|
-
|
|
125038
|
-
|
|
125039
|
-
|
|
125040
|
-
|
|
125041
|
-
|
|
125042
|
-
|
|
124763
|
+
var hasRequiredLib$5;
|
|
124764
|
+
|
|
124765
|
+
function requireLib$5 () {
|
|
124766
|
+
if (hasRequiredLib$5) return lib$6;
|
|
124767
|
+
hasRequiredLib$5 = 1;
|
|
124768
|
+
|
|
124769
|
+
Object.defineProperty(lib$6, "__esModule", {
|
|
124770
|
+
value: true
|
|
124771
|
+
});
|
|
124772
|
+
lib$6.readCodePoint = readCodePoint;
|
|
124773
|
+
lib$6.readInt = readInt;
|
|
124774
|
+
lib$6.readStringContents = readStringContents;
|
|
124775
|
+
var _isDigit = function isDigit(code) {
|
|
124776
|
+
return code >= 48 && code <= 57;
|
|
124777
|
+
};
|
|
124778
|
+
const forbiddenNumericSeparatorSiblings = {
|
|
124779
|
+
decBinOct: new Set([46, 66, 69, 79, 95, 98, 101, 111]),
|
|
124780
|
+
hex: new Set([46, 88, 95, 120])
|
|
124781
|
+
};
|
|
124782
|
+
const isAllowedNumericSeparatorSibling = {
|
|
124783
|
+
bin: ch => ch === 48 || ch === 49,
|
|
124784
|
+
oct: ch => ch >= 48 && ch <= 55,
|
|
124785
|
+
dec: ch => ch >= 48 && ch <= 57,
|
|
124786
|
+
hex: ch => ch >= 48 && ch <= 57 || ch >= 65 && ch <= 70 || ch >= 97 && ch <= 102
|
|
124787
|
+
};
|
|
124788
|
+
function readStringContents(type, input, pos, lineStart, curLine, errors) {
|
|
124789
|
+
const initialPos = pos;
|
|
124790
|
+
const initialLineStart = lineStart;
|
|
124791
|
+
const initialCurLine = curLine;
|
|
124792
|
+
let out = "";
|
|
124793
|
+
let firstInvalidLoc = null;
|
|
124794
|
+
let chunkStart = pos;
|
|
124795
|
+
const {
|
|
124796
|
+
length
|
|
124797
|
+
} = input;
|
|
124798
|
+
for (;;) {
|
|
124799
|
+
if (pos >= length) {
|
|
124800
|
+
errors.unterminated(initialPos, initialLineStart, initialCurLine);
|
|
124801
|
+
out += input.slice(chunkStart, pos);
|
|
124802
|
+
break;
|
|
124803
|
+
}
|
|
124804
|
+
const ch = input.charCodeAt(pos);
|
|
124805
|
+
if (isStringEnd(type, ch, input, pos)) {
|
|
124806
|
+
out += input.slice(chunkStart, pos);
|
|
124807
|
+
break;
|
|
124808
|
+
}
|
|
124809
|
+
if (ch === 92) {
|
|
124810
|
+
out += input.slice(chunkStart, pos);
|
|
124811
|
+
const res = readEscapedChar(input, pos, lineStart, curLine, type === "template", errors);
|
|
124812
|
+
if (res.ch === null && !firstInvalidLoc) {
|
|
124813
|
+
firstInvalidLoc = {
|
|
124814
|
+
pos,
|
|
124815
|
+
lineStart,
|
|
124816
|
+
curLine
|
|
124817
|
+
};
|
|
124818
|
+
} else {
|
|
124819
|
+
out += res.ch;
|
|
124820
|
+
}
|
|
124821
|
+
({
|
|
124822
|
+
pos,
|
|
124823
|
+
lineStart,
|
|
124824
|
+
curLine
|
|
124825
|
+
} = res);
|
|
124826
|
+
chunkStart = pos;
|
|
124827
|
+
} else if (ch === 8232 || ch === 8233) {
|
|
124828
|
+
++pos;
|
|
124829
|
+
++curLine;
|
|
124830
|
+
lineStart = pos;
|
|
124831
|
+
} else if (ch === 10 || ch === 13) {
|
|
124832
|
+
if (type === "template") {
|
|
124833
|
+
out += input.slice(chunkStart, pos) + "\n";
|
|
124834
|
+
++pos;
|
|
124835
|
+
if (ch === 13 && input.charCodeAt(pos) === 10) {
|
|
124836
|
+
++pos;
|
|
124837
|
+
}
|
|
124838
|
+
++curLine;
|
|
124839
|
+
chunkStart = lineStart = pos;
|
|
124840
|
+
} else {
|
|
124841
|
+
errors.unterminated(initialPos, initialLineStart, initialCurLine);
|
|
124842
|
+
}
|
|
124843
|
+
} else {
|
|
124844
|
+
++pos;
|
|
124845
|
+
}
|
|
124846
|
+
}
|
|
124847
|
+
return {
|
|
124848
|
+
pos,
|
|
124849
|
+
str: out,
|
|
124850
|
+
firstInvalidLoc,
|
|
124851
|
+
lineStart,
|
|
124852
|
+
curLine,
|
|
124853
|
+
containsInvalid: !!firstInvalidLoc
|
|
124854
|
+
};
|
|
124855
|
+
}
|
|
124856
|
+
function isStringEnd(type, ch, input, pos) {
|
|
124857
|
+
if (type === "template") {
|
|
124858
|
+
return ch === 96 || ch === 36 && input.charCodeAt(pos + 1) === 123;
|
|
124859
|
+
}
|
|
124860
|
+
return ch === (type === "double" ? 34 : 39);
|
|
124861
|
+
}
|
|
124862
|
+
function readEscapedChar(input, pos, lineStart, curLine, inTemplate, errors) {
|
|
124863
|
+
const throwOnInvalid = !inTemplate;
|
|
124864
|
+
pos++;
|
|
124865
|
+
const res = ch => ({
|
|
124866
|
+
pos,
|
|
124867
|
+
ch,
|
|
124868
|
+
lineStart,
|
|
124869
|
+
curLine
|
|
124870
|
+
});
|
|
124871
|
+
const ch = input.charCodeAt(pos++);
|
|
124872
|
+
switch (ch) {
|
|
124873
|
+
case 110:
|
|
124874
|
+
return res("\n");
|
|
124875
|
+
case 114:
|
|
124876
|
+
return res("\r");
|
|
124877
|
+
case 120:
|
|
124878
|
+
{
|
|
124879
|
+
let code;
|
|
124880
|
+
({
|
|
124881
|
+
code,
|
|
124882
|
+
pos
|
|
124883
|
+
} = readHexChar(input, pos, lineStart, curLine, 2, false, throwOnInvalid, errors));
|
|
124884
|
+
return res(code === null ? null : String.fromCharCode(code));
|
|
124885
|
+
}
|
|
124886
|
+
case 117:
|
|
124887
|
+
{
|
|
124888
|
+
let code;
|
|
124889
|
+
({
|
|
124890
|
+
code,
|
|
124891
|
+
pos
|
|
124892
|
+
} = readCodePoint(input, pos, lineStart, curLine, throwOnInvalid, errors));
|
|
124893
|
+
return res(code === null ? null : String.fromCodePoint(code));
|
|
124894
|
+
}
|
|
124895
|
+
case 116:
|
|
124896
|
+
return res("\t");
|
|
124897
|
+
case 98:
|
|
124898
|
+
return res("\b");
|
|
124899
|
+
case 118:
|
|
124900
|
+
return res("\u000b");
|
|
124901
|
+
case 102:
|
|
124902
|
+
return res("\f");
|
|
124903
|
+
case 13:
|
|
124904
|
+
if (input.charCodeAt(pos) === 10) {
|
|
124905
|
+
++pos;
|
|
124906
|
+
}
|
|
124907
|
+
case 10:
|
|
124908
|
+
lineStart = pos;
|
|
124909
|
+
++curLine;
|
|
124910
|
+
case 8232:
|
|
124911
|
+
case 8233:
|
|
124912
|
+
return res("");
|
|
124913
|
+
case 56:
|
|
124914
|
+
case 57:
|
|
124915
|
+
if (inTemplate) {
|
|
124916
|
+
return res(null);
|
|
124917
|
+
} else {
|
|
124918
|
+
errors.strictNumericEscape(pos - 1, lineStart, curLine);
|
|
124919
|
+
}
|
|
124920
|
+
default:
|
|
124921
|
+
if (ch >= 48 && ch <= 55) {
|
|
124922
|
+
const startPos = pos - 1;
|
|
124923
|
+
const match = input.slice(startPos, pos + 2).match(/^[0-7]+/);
|
|
124924
|
+
let octalStr = match[0];
|
|
124925
|
+
let octal = parseInt(octalStr, 8);
|
|
124926
|
+
if (octal > 255) {
|
|
124927
|
+
octalStr = octalStr.slice(0, -1);
|
|
124928
|
+
octal = parseInt(octalStr, 8);
|
|
124929
|
+
}
|
|
124930
|
+
pos += octalStr.length - 1;
|
|
124931
|
+
const next = input.charCodeAt(pos);
|
|
124932
|
+
if (octalStr !== "0" || next === 56 || next === 57) {
|
|
124933
|
+
if (inTemplate) {
|
|
124934
|
+
return res(null);
|
|
124935
|
+
} else {
|
|
124936
|
+
errors.strictNumericEscape(startPos, lineStart, curLine);
|
|
124937
|
+
}
|
|
124938
|
+
}
|
|
124939
|
+
return res(String.fromCharCode(octal));
|
|
124940
|
+
}
|
|
124941
|
+
return res(String.fromCharCode(ch));
|
|
124942
|
+
}
|
|
124943
|
+
}
|
|
124944
|
+
function readHexChar(input, pos, lineStart, curLine, len, forceLen, throwOnInvalid, errors) {
|
|
124945
|
+
const initialPos = pos;
|
|
124946
|
+
let n;
|
|
124947
|
+
({
|
|
124948
|
+
n,
|
|
124949
|
+
pos
|
|
124950
|
+
} = readInt(input, pos, lineStart, curLine, 16, len, forceLen, false, errors, !throwOnInvalid));
|
|
124951
|
+
if (n === null) {
|
|
124952
|
+
if (throwOnInvalid) {
|
|
124953
|
+
errors.invalidEscapeSequence(initialPos, lineStart, curLine);
|
|
124954
|
+
} else {
|
|
124955
|
+
pos = initialPos - 1;
|
|
124956
|
+
}
|
|
124957
|
+
}
|
|
124958
|
+
return {
|
|
124959
|
+
code: n,
|
|
124960
|
+
pos
|
|
124961
|
+
};
|
|
124962
|
+
}
|
|
124963
|
+
function readInt(input, pos, lineStart, curLine, radix, len, forceLen, allowNumSeparator, errors, bailOnError) {
|
|
124964
|
+
const start = pos;
|
|
124965
|
+
const forbiddenSiblings = radix === 16 ? forbiddenNumericSeparatorSiblings.hex : forbiddenNumericSeparatorSiblings.decBinOct;
|
|
124966
|
+
const isAllowedSibling = radix === 16 ? isAllowedNumericSeparatorSibling.hex : radix === 10 ? isAllowedNumericSeparatorSibling.dec : radix === 8 ? isAllowedNumericSeparatorSibling.oct : isAllowedNumericSeparatorSibling.bin;
|
|
124967
|
+
let invalid = false;
|
|
124968
|
+
let total = 0;
|
|
124969
|
+
for (let i = 0, e = len == null ? Infinity : len; i < e; ++i) {
|
|
124970
|
+
const code = input.charCodeAt(pos);
|
|
124971
|
+
let val;
|
|
124972
|
+
if (code === 95 && allowNumSeparator !== "bail") {
|
|
124973
|
+
const prev = input.charCodeAt(pos - 1);
|
|
124974
|
+
const next = input.charCodeAt(pos + 1);
|
|
124975
|
+
if (!allowNumSeparator) {
|
|
124976
|
+
if (bailOnError) return {
|
|
124977
|
+
n: null,
|
|
124978
|
+
pos
|
|
124979
|
+
};
|
|
124980
|
+
errors.numericSeparatorInEscapeSequence(pos, lineStart, curLine);
|
|
124981
|
+
} else if (Number.isNaN(next) || !isAllowedSibling(next) || forbiddenSiblings.has(prev) || forbiddenSiblings.has(next)) {
|
|
124982
|
+
if (bailOnError) return {
|
|
124983
|
+
n: null,
|
|
124984
|
+
pos
|
|
124985
|
+
};
|
|
124986
|
+
errors.unexpectedNumericSeparator(pos, lineStart, curLine);
|
|
124987
|
+
}
|
|
124988
|
+
++pos;
|
|
124989
|
+
continue;
|
|
124990
|
+
}
|
|
124991
|
+
if (code >= 97) {
|
|
124992
|
+
val = code - 97 + 10;
|
|
124993
|
+
} else if (code >= 65) {
|
|
124994
|
+
val = code - 65 + 10;
|
|
124995
|
+
} else if (_isDigit(code)) {
|
|
124996
|
+
val = code - 48;
|
|
124997
|
+
} else {
|
|
124998
|
+
val = Infinity;
|
|
124999
|
+
}
|
|
125000
|
+
if (val >= radix) {
|
|
125001
|
+
if (val <= 9 && bailOnError) {
|
|
125002
|
+
return {
|
|
125003
|
+
n: null,
|
|
125004
|
+
pos
|
|
125005
|
+
};
|
|
125006
|
+
} else if (val <= 9 && errors.invalidDigit(pos, lineStart, curLine, radix)) {
|
|
125007
|
+
val = 0;
|
|
125008
|
+
} else if (forceLen) {
|
|
125009
|
+
val = 0;
|
|
125010
|
+
invalid = true;
|
|
125011
|
+
} else {
|
|
125012
|
+
break;
|
|
125013
|
+
}
|
|
125014
|
+
}
|
|
125015
|
+
++pos;
|
|
125016
|
+
total = total * radix + val;
|
|
125017
|
+
}
|
|
125018
|
+
if (pos === start || len != null && pos - start !== len || invalid) {
|
|
125019
|
+
return {
|
|
125020
|
+
n: null,
|
|
125021
|
+
pos
|
|
125022
|
+
};
|
|
125023
|
+
}
|
|
125024
|
+
return {
|
|
125025
|
+
n: total,
|
|
125026
|
+
pos
|
|
125027
|
+
};
|
|
125028
|
+
}
|
|
125029
|
+
function readCodePoint(input, pos, lineStart, curLine, throwOnInvalid, errors) {
|
|
125030
|
+
const ch = input.charCodeAt(pos);
|
|
125031
|
+
let code;
|
|
125032
|
+
if (ch === 123) {
|
|
125033
|
+
++pos;
|
|
125034
|
+
({
|
|
125035
|
+
code,
|
|
125036
|
+
pos
|
|
125037
|
+
} = readHexChar(input, pos, lineStart, curLine, input.indexOf("}", pos) - pos, true, throwOnInvalid, errors));
|
|
125038
|
+
++pos;
|
|
125039
|
+
if (code !== null && code > 0x10ffff) {
|
|
125040
|
+
if (throwOnInvalid) {
|
|
125041
|
+
errors.invalidCodePoint(pos, lineStart, curLine);
|
|
125042
|
+
} else {
|
|
125043
|
+
return {
|
|
125044
|
+
code: null,
|
|
125045
|
+
pos
|
|
125046
|
+
};
|
|
125047
|
+
}
|
|
125048
|
+
}
|
|
125049
|
+
} else {
|
|
125050
|
+
({
|
|
125051
|
+
code,
|
|
125052
|
+
pos
|
|
125053
|
+
} = readHexChar(input, pos, lineStart, curLine, 4, false, throwOnInvalid, errors));
|
|
125054
|
+
}
|
|
125055
|
+
return {
|
|
125056
|
+
code,
|
|
125057
|
+
pos
|
|
125058
|
+
};
|
|
125059
|
+
}
|
|
125060
|
+
|
|
125061
|
+
|
|
125062
|
+
return lib$6;
|
|
125043
125063
|
}
|
|
125044
125064
|
|
|
125045
125065
|
var constants$2 = {};
|
|
@@ -125394,7 +125414,7 @@ function requireCore$2 () {
|
|
|
125394
125414
|
var _is = requireIs$2();
|
|
125395
125415
|
var _isValidIdentifier = isValidIdentifier$5;
|
|
125396
125416
|
var _helperValidatorIdentifier = lib$7;
|
|
125397
|
-
var _helperStringParser =
|
|
125417
|
+
var _helperStringParser = requireLib$5();
|
|
125398
125418
|
var _constants = constants$2;
|
|
125399
125419
|
var _utils = requireUtils$2();
|
|
125400
125420
|
const defineType = (0, _utils.defineAliasedType)("Standardized");
|
|
@@ -136356,7 +136376,7 @@ conversion.arrowFunctionToExpression = arrowFunctionToExpression;
|
|
|
136356
136376
|
conversion.ensureBlock = ensureBlock$2;
|
|
136357
136377
|
conversion.toComputedKey = toComputedKey$2;
|
|
136358
136378
|
conversion.unwrapFunctionEnvironment = unwrapFunctionEnvironment;
|
|
136359
|
-
var _t$4 = requireLib$
|
|
136379
|
+
var _t$4 = requireLib$8();
|
|
136360
136380
|
var _helperEnvironmentVisitor = lib$k;
|
|
136361
136381
|
var _helperFunctionName = lib$a;
|
|
136362
136382
|
var _visitors = visitors;
|
|
@@ -136840,7 +136860,7 @@ introspection.matchesPattern = matchesPattern$5;
|
|
|
136840
136860
|
introspection.referencesImport = referencesImport;
|
|
136841
136861
|
introspection.resolve = resolve$1;
|
|
136842
136862
|
introspection.willIMaybeExecuteBefore = willIMaybeExecuteBefore;
|
|
136843
|
-
var _t$3 = requireLib$
|
|
136863
|
+
var _t$3 = requireLib$8();
|
|
136844
136864
|
const {
|
|
136845
136865
|
STATEMENT_OR_BLOCK_KEYS: STATEMENT_OR_BLOCK_KEYS$2,
|
|
136846
136866
|
VISITOR_KEYS,
|
|
@@ -137544,7 +137564,7 @@ Object.defineProperty(hoister, "__esModule", {
|
|
|
137544
137564
|
value: true
|
|
137545
137565
|
});
|
|
137546
137566
|
hoister.default = void 0;
|
|
137547
|
-
var _t$2 = requireLib$
|
|
137567
|
+
var _t$2 = requireLib$8();
|
|
137548
137568
|
var _t2 = _t$2;
|
|
137549
137569
|
const {
|
|
137550
137570
|
react: react$1
|
|
@@ -137730,7 +137750,7 @@ function requireModification () {
|
|
|
137730
137750
|
var _cache = cache;
|
|
137731
137751
|
var _hoister = hoister;
|
|
137732
137752
|
var _index = requirePath();
|
|
137733
|
-
var _t = requireLib$
|
|
137753
|
+
var _t = requireLib$8();
|
|
137734
137754
|
const {
|
|
137735
137755
|
arrowFunctionExpression,
|
|
137736
137756
|
assertExpression,
|
|
@@ -137966,7 +137986,7 @@ function requireFamily () {
|
|
|
137966
137986
|
family.getPrevSibling = getPrevSibling;
|
|
137967
137987
|
family.getSibling = getSibling;
|
|
137968
137988
|
var _index = requirePath();
|
|
137969
|
-
var _t = requireLib$
|
|
137989
|
+
var _t = requireLib$8();
|
|
137970
137990
|
const {
|
|
137971
137991
|
getBindingIdentifiers: _getBindingIdentifiers,
|
|
137972
137992
|
getOuterBindingIdentifiers: _getOuterBindingIdentifiers,
|
|
@@ -138293,7 +138313,7 @@ Object.defineProperty(comments$1, "__esModule", {
|
|
|
138293
138313
|
comments$1.addComment = addComment$4;
|
|
138294
138314
|
comments$1.addComments = addComments$4;
|
|
138295
138315
|
comments$1.shareCommentsWithSiblings = shareCommentsWithSiblings;
|
|
138296
|
-
var _t$1 = requireLib$
|
|
138316
|
+
var _t$1 = requireLib$8();
|
|
138297
138317
|
const {
|
|
138298
138318
|
addComment: _addComment,
|
|
138299
138319
|
addComments: _addComments$2
|
|
@@ -138359,7 +138379,7 @@ virtualTypesValidator.isSpreadProperty = isSpreadProperty$2;
|
|
|
138359
138379
|
virtualTypesValidator.isStatement = isStatement$7;
|
|
138360
138380
|
virtualTypesValidator.isUser = isUser;
|
|
138361
138381
|
virtualTypesValidator.isVar = isVar$4;
|
|
138362
|
-
var _t = requireLib$
|
|
138382
|
+
var _t = requireLib$8();
|
|
138363
138383
|
const {
|
|
138364
138384
|
isBinding: isBinding$5,
|
|
138365
138385
|
isBlockScoped: nodeIsBlockScoped,
|
|
@@ -138514,7 +138534,7 @@ function requirePath () {
|
|
|
138514
138534
|
var _debug = browserExports;
|
|
138515
138535
|
var _index = requireLib$3();
|
|
138516
138536
|
var _scope = requireScope();
|
|
138517
|
-
var _t = requireLib$
|
|
138537
|
+
var _t = requireLib$8();
|
|
138518
138538
|
var t = _t;
|
|
138519
138539
|
var cache$1 = cache;
|
|
138520
138540
|
var _generator = lib$j;
|
|
@@ -138711,7 +138731,7 @@ function requireContext () {
|
|
|
138711
138731
|
});
|
|
138712
138732
|
context$1.default = void 0;
|
|
138713
138733
|
var _path = requirePath();
|
|
138714
|
-
var _t = requireLib$
|
|
138734
|
+
var _t = requireLib$8();
|
|
138715
138735
|
const {
|
|
138716
138736
|
VISITOR_KEYS
|
|
138717
138737
|
} = _t;
|
|
@@ -138833,7 +138853,7 @@ function requireTraverseNode () {
|
|
|
138833
138853
|
});
|
|
138834
138854
|
traverseNode.traverseNode = traverseNode$1;
|
|
138835
138855
|
var _context = requireContext();
|
|
138836
|
-
var _t = requireLib$
|
|
138856
|
+
var _t = requireLib$8();
|
|
138837
138857
|
const {
|
|
138838
138858
|
VISITOR_KEYS
|
|
138839
138859
|
} = _t;
|
|
@@ -138907,7 +138927,7 @@ function requireLib$3 () {
|
|
|
138907
138927
|
exports.visitors = exports.default = void 0;
|
|
138908
138928
|
var visitors$1 = visitors;
|
|
138909
138929
|
exports.visitors = visitors$1;
|
|
138910
|
-
var _t = requireLib$
|
|
138930
|
+
var _t = requireLib$8();
|
|
138911
138931
|
var cache$1 = cache;
|
|
138912
138932
|
var _traverseNode = requireTraverseNode();
|
|
138913
138933
|
var _path = requirePath();
|