okno 1.0.0-alpha.6 → 1.0.0-alpha.8

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.
@@ -0,0 +1,3143 @@
1
+ var ft = [509, 0, 227, 0, 150, 4, 294, 9, 1368, 2, 2, 1, 6, 3, 41, 2, 5, 0, 166, 1, 574, 3, 9, 9, 7, 9, 32, 4, 318, 1, 78, 5, 71, 10, 50, 3, 123, 2, 54, 14, 32, 10, 3, 1, 11, 3, 46, 10, 8, 0, 46, 9, 7, 2, 37, 13, 2, 9, 6, 1, 45, 0, 13, 2, 49, 13, 9, 3, 2, 11, 83, 11, 7, 0, 3, 0, 158, 11, 6, 9, 7, 3, 56, 1, 2, 6, 3, 1, 3, 2, 10, 0, 11, 1, 3, 6, 4, 4, 68, 8, 2, 0, 3, 0, 2, 3, 2, 4, 2, 0, 15, 1, 83, 17, 10, 9, 5, 0, 82, 19, 13, 9, 214, 6, 3, 8, 28, 1, 83, 16, 16, 9, 82, 12, 9, 9, 7, 19, 58, 14, 5, 9, 243, 14, 166, 9, 71, 5, 2, 1, 3, 3, 2, 0, 2, 1, 13, 9, 120, 6, 3, 6, 4, 0, 29, 9, 41, 6, 2, 3, 9, 0, 10, 10, 47, 15, 199, 7, 137, 9, 54, 7, 2, 7, 17, 9, 57, 21, 2, 13, 123, 5, 4, 0, 2, 1, 2, 6, 2, 0, 9, 9, 49, 4, 2, 1, 2, 4, 9, 9, 55, 9, 266, 3, 10, 1, 2, 0, 49, 6, 4, 4, 14, 10, 5350, 0, 7, 14, 11465, 27, 2343, 9, 87, 9, 39, 4, 60, 6, 26, 9, 535, 9, 470, 0, 2, 54, 8, 3, 82, 0, 12, 1, 19628, 1, 4178, 9, 519, 45, 3, 22, 543, 4, 4, 5, 9, 7, 3, 6, 31, 3, 149, 2, 1418, 49, 513, 54, 5, 49, 9, 0, 15, 0, 23, 4, 2, 14, 1361, 6, 2, 16, 3, 6, 2, 1, 2, 4, 101, 0, 161, 6, 10, 9, 357, 0, 62, 13, 499, 13, 245, 1, 2, 9, 233, 0, 3, 0, 8, 1, 6, 0, 475, 6, 110, 6, 6, 9, 4759, 9, 787719, 239], Ne = [0, 11, 2, 25, 2, 18, 2, 1, 2, 14, 3, 13, 35, 122, 70, 52, 268, 28, 4, 48, 48, 31, 14, 29, 6, 37, 11, 29, 3, 35, 5, 7, 2, 4, 43, 157, 19, 35, 5, 35, 5, 39, 9, 51, 13, 10, 2, 14, 2, 6, 2, 1, 2, 10, 2, 14, 2, 6, 2, 1, 4, 51, 13, 310, 10, 21, 11, 7, 25, 5, 2, 41, 2, 8, 70, 5, 3, 0, 2, 43, 2, 1, 4, 0, 3, 22, 11, 22, 10, 30, 66, 18, 2, 1, 11, 21, 11, 25, 7, 25, 39, 55, 7, 1, 65, 0, 16, 3, 2, 2, 2, 28, 43, 28, 4, 28, 36, 7, 2, 27, 28, 53, 11, 21, 11, 18, 14, 17, 111, 72, 56, 50, 14, 50, 14, 35, 39, 27, 10, 22, 251, 41, 7, 1, 17, 5, 57, 28, 11, 0, 9, 21, 43, 17, 47, 20, 28, 22, 13, 52, 58, 1, 3, 0, 14, 44, 33, 24, 27, 35, 30, 0, 3, 0, 9, 34, 4, 0, 13, 47, 15, 3, 22, 0, 2, 0, 36, 17, 2, 24, 20, 1, 64, 6, 2, 0, 2, 3, 2, 14, 2, 9, 8, 46, 39, 7, 3, 1, 3, 21, 2, 6, 2, 1, 2, 4, 4, 0, 19, 0, 13, 4, 31, 9, 2, 0, 3, 0, 2, 37, 2, 0, 26, 0, 2, 0, 45, 52, 19, 3, 21, 2, 31, 47, 21, 1, 2, 0, 185, 46, 42, 3, 37, 47, 21, 0, 60, 42, 14, 0, 72, 26, 38, 6, 186, 43, 117, 63, 32, 7, 3, 0, 3, 7, 2, 1, 2, 23, 16, 0, 2, 0, 95, 7, 3, 38, 17, 0, 2, 0, 29, 0, 11, 39, 8, 0, 22, 0, 12, 45, 20, 0, 19, 72, 200, 32, 32, 8, 2, 36, 18, 0, 50, 29, 113, 6, 2, 1, 2, 37, 22, 0, 26, 5, 2, 1, 2, 31, 15, 0, 24, 43, 261, 18, 16, 0, 2, 12, 2, 33, 125, 0, 80, 921, 103, 110, 18, 195, 2637, 96, 16, 1071, 18, 5, 26, 3994, 6, 582, 6842, 29, 1763, 568, 8, 30, 18, 78, 18, 29, 19, 47, 17, 3, 32, 20, 6, 18, 433, 44, 212, 63, 33, 24, 3, 24, 45, 74, 6, 0, 67, 12, 65, 1, 2, 0, 15, 4, 10, 7381, 42, 31, 98, 114, 8702, 3, 2, 6, 2, 1, 2, 290, 16, 0, 30, 2, 3, 0, 15, 3, 9, 395, 2309, 106, 6, 12, 4, 8, 8, 9, 5991, 84, 2, 70, 2, 1, 3, 0, 3, 1, 3, 3, 2, 11, 2, 0, 2, 6, 2, 64, 2, 3, 3, 7, 2, 6, 2, 27, 2, 3, 2, 4, 2, 0, 4, 6, 2, 339, 3, 24, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 7, 1845, 30, 7, 5, 262, 61, 147, 44, 11, 6, 17, 0, 322, 29, 19, 43, 485, 27, 229, 29, 3, 0, 208, 30, 2, 2, 2, 1, 2, 6, 3, 4, 10, 1, 225, 6, 2, 3, 2, 1, 2, 14, 2, 196, 60, 67, 8, 0, 1205, 3, 2, 26, 2, 1, 2, 0, 3, 0, 2, 9, 2, 3, 2, 0, 2, 0, 7, 0, 5, 0, 2, 0, 2, 0, 2, 2, 2, 1, 2, 0, 3, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 3, 3, 2, 6, 2, 3, 2, 3, 2, 0, 2, 9, 2, 16, 6, 2, 2, 4, 2, 16, 4421, 42719, 33, 4381, 3, 5773, 3, 7472, 16, 621, 2467, 541, 1507, 4938, 6, 8489], dt = "‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛ࢗ-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-᫝᫠-᫫ᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・", Ve = "ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-࢏ࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚ౜ౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽ೜-ೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲊᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-Ƛ꟱-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ", le = {
2
+ 3: "abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile",
3
+ 5: "class enum extends super const export import",
4
+ 6: "enum",
5
+ strict: "implements interface let package private protected public static yield",
6
+ strictBind: "eval arguments"
7
+ }, pe = "break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this", xt = {
8
+ 5: pe,
9
+ "5module": pe + " export import",
10
+ 6: pe + " const class extends export import super"
11
+ }, Te = /^in(stanceof)?$/, mt = new RegExp("[" + Ve + "]"), vt = new RegExp("[" + Ve + dt + "]");
12
+ function de(e, t) {
13
+ for (var i = 65536, s = 0; s < t.length; s += 2) {
14
+ if (i += t[s], i > e)
15
+ return !1;
16
+ if (i += t[s + 1], i >= e)
17
+ return !0;
18
+ }
19
+ return !1;
20
+ }
21
+ function T(e, t) {
22
+ return e < 65 ? e === 36 : e < 91 ? !0 : e < 97 ? e === 95 : e < 123 ? !0 : e <= 65535 ? e >= 170 && mt.test(String.fromCharCode(e)) : t === !1 ? !1 : de(e, Ne);
23
+ }
24
+ function F(e, t) {
25
+ return e < 48 ? e === 36 : e < 58 ? !0 : e < 65 ? !1 : e < 91 ? !0 : e < 97 ? e === 95 : e < 123 ? !0 : e <= 65535 ? e >= 170 && vt.test(String.fromCharCode(e)) : t === !1 ? !1 : de(e, Ne) || de(e, ft);
26
+ }
27
+ var v = function(t, i) {
28
+ i === void 0 && (i = {}), this.label = t, this.keyword = i.keyword, this.beforeExpr = !!i.beforeExpr, this.startsExpr = !!i.startsExpr, this.isLoop = !!i.isLoop, this.isAssign = !!i.isAssign, this.prefix = !!i.prefix, this.postfix = !!i.postfix, this.binop = i.binop || null, this.updateContext = null;
29
+ };
30
+ function A(e, t) {
31
+ return new v(e, { beforeExpr: !0, binop: t });
32
+ }
33
+ var E = { beforeExpr: !0 }, k = { startsExpr: !0 }, ge = {};
34
+ function m(e, t) {
35
+ return t === void 0 && (t = {}), t.keyword = e, ge[e] = new v(e, t);
36
+ }
37
+ var a = {
38
+ num: new v("num", k),
39
+ regexp: new v("regexp", k),
40
+ string: new v("string", k),
41
+ name: new v("name", k),
42
+ privateId: new v("privateId", k),
43
+ eof: new v("eof"),
44
+ // Punctuation token types.
45
+ bracketL: new v("[", { beforeExpr: !0, startsExpr: !0 }),
46
+ bracketR: new v("]"),
47
+ braceL: new v("{", { beforeExpr: !0, startsExpr: !0 }),
48
+ braceR: new v("}"),
49
+ parenL: new v("(", { beforeExpr: !0, startsExpr: !0 }),
50
+ parenR: new v(")"),
51
+ comma: new v(",", E),
52
+ semi: new v(";", E),
53
+ colon: new v(":", E),
54
+ dot: new v("."),
55
+ question: new v("?", E),
56
+ questionDot: new v("?."),
57
+ arrow: new v("=>", E),
58
+ template: new v("template"),
59
+ invalidTemplate: new v("invalidTemplate"),
60
+ ellipsis: new v("...", E),
61
+ backQuote: new v("`", k),
62
+ dollarBraceL: new v("${", { beforeExpr: !0, startsExpr: !0 }),
63
+ // Operators. These carry several kinds of properties to help the
64
+ // parser use them properly (the presence of these properties is
65
+ // what categorizes them as operators).
66
+ //
67
+ // `binop`, when present, specifies that this operator is a binary
68
+ // operator, and will refer to its precedence.
69
+ //
70
+ // `prefix` and `postfix` mark the operator as a prefix or postfix
71
+ // unary operator.
72
+ //
73
+ // `isAssign` marks all of `=`, `+=`, `-=` etcetera, which act as
74
+ // binary operators with a very low precedence, that should result
75
+ // in AssignmentExpression nodes.
76
+ eq: new v("=", { beforeExpr: !0, isAssign: !0 }),
77
+ assign: new v("_=", { beforeExpr: !0, isAssign: !0 }),
78
+ incDec: new v("++/--", { prefix: !0, postfix: !0, startsExpr: !0 }),
79
+ prefix: new v("!/~", { beforeExpr: !0, prefix: !0, startsExpr: !0 }),
80
+ logicalOR: A("||", 1),
81
+ logicalAND: A("&&", 2),
82
+ bitwiseOR: A("|", 3),
83
+ bitwiseXOR: A("^", 4),
84
+ bitwiseAND: A("&", 5),
85
+ equality: A("==/!=/===/!==", 6),
86
+ relational: A("</>/<=/>=", 7),
87
+ bitShift: A("<</>>/>>>", 8),
88
+ plusMin: new v("+/-", { beforeExpr: !0, binop: 9, prefix: !0, startsExpr: !0 }),
89
+ modulo: A("%", 10),
90
+ star: A("*", 10),
91
+ slash: A("/", 10),
92
+ starstar: new v("**", { beforeExpr: !0 }),
93
+ coalesce: A("??", 1),
94
+ // Keyword token types.
95
+ _break: m("break"),
96
+ _case: m("case", E),
97
+ _catch: m("catch"),
98
+ _continue: m("continue"),
99
+ _debugger: m("debugger"),
100
+ _default: m("default", E),
101
+ _do: m("do", { isLoop: !0, beforeExpr: !0 }),
102
+ _else: m("else", E),
103
+ _finally: m("finally"),
104
+ _for: m("for", { isLoop: !0 }),
105
+ _function: m("function", k),
106
+ _if: m("if"),
107
+ _return: m("return", E),
108
+ _switch: m("switch"),
109
+ _throw: m("throw", E),
110
+ _try: m("try"),
111
+ _var: m("var"),
112
+ _const: m("const"),
113
+ _while: m("while", { isLoop: !0 }),
114
+ _with: m("with"),
115
+ _new: m("new", { beforeExpr: !0, startsExpr: !0 }),
116
+ _this: m("this", k),
117
+ _super: m("super", k),
118
+ _class: m("class", k),
119
+ _extends: m("extends", E),
120
+ _export: m("export"),
121
+ _import: m("import", k),
122
+ _null: m("null", k),
123
+ _true: m("true", k),
124
+ _false: m("false", k),
125
+ _in: m("in", { beforeExpr: !0, binop: 7 }),
126
+ _instanceof: m("instanceof", { beforeExpr: !0, binop: 7 }),
127
+ _typeof: m("typeof", { beforeExpr: !0, prefix: !0, startsExpr: !0 }),
128
+ _void: m("void", { beforeExpr: !0, prefix: !0, startsExpr: !0 }),
129
+ _delete: m("delete", { beforeExpr: !0, prefix: !0, startsExpr: !0 })
130
+ }, w = /\r\n?|\n|\u2028|\u2029/, gt = new RegExp(w.source, "g");
131
+ function z(e) {
132
+ return e === 10 || e === 13 || e === 8232 || e === 8233;
133
+ }
134
+ function Le(e, t, i) {
135
+ i === void 0 && (i = e.length);
136
+ for (var s = t; s < i; s++) {
137
+ var r = e.charCodeAt(s);
138
+ if (z(r))
139
+ return s < i - 1 && r === 13 && e.charCodeAt(s + 1) === 10 ? s + 2 : s + 1;
140
+ }
141
+ return -1;
142
+ }
143
+ var Re = /[\u1680\u2000-\u200a\u202f\u205f\u3000\ufeff]/, C = /(?:\s|\/\/.*|\/\*[^]*?\*\/)*/g, Oe = Object.prototype, bt = Oe.hasOwnProperty, yt = Oe.toString, K = Object.hasOwn || (function(e, t) {
144
+ return bt.call(e, t);
145
+ }), we = Array.isArray || (function(e) {
146
+ return yt.call(e) === "[object Array]";
147
+ }), Ae = /* @__PURE__ */ Object.create(null);
148
+ function D(e) {
149
+ return Ae[e] || (Ae[e] = new RegExp("^(?:" + e.replace(/ /g, "|") + ")$"));
150
+ }
151
+ function R(e) {
152
+ return e <= 65535 ? String.fromCharCode(e) : (e -= 65536, String.fromCharCode((e >> 10) + 55296, (e & 1023) + 56320));
153
+ }
154
+ var _t = /(?:[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])/, Z = function(t, i) {
155
+ this.line = t, this.column = i;
156
+ };
157
+ Z.prototype.offset = function(t) {
158
+ return new Z(this.line, this.column + t);
159
+ };
160
+ var re = function(t, i, s) {
161
+ this.start = i, this.end = s, t.sourceFile !== null && (this.source = t.sourceFile);
162
+ };
163
+ function Be(e, t) {
164
+ for (var i = 1, s = 0; ; ) {
165
+ var r = Le(e, s, t);
166
+ if (r < 0)
167
+ return new Z(i, t - s);
168
+ ++i, s = r;
169
+ }
170
+ }
171
+ var xe = {
172
+ // `ecmaVersion` indicates the ECMAScript version to parse. Must be
173
+ // either 3, 5, 6 (or 2015), 7 (2016), 8 (2017), 9 (2018), 10
174
+ // (2019), 11 (2020), 12 (2021), 13 (2022), 14 (2023), or `"latest"`
175
+ // (the latest version the library supports). This influences
176
+ // support for strict mode, the set of reserved words, and support
177
+ // for new syntax features.
178
+ ecmaVersion: null,
179
+ // `sourceType` indicates the mode the code should be parsed in.
180
+ // Can be either `"script"`, `"module"` or `"commonjs"`. This influences global
181
+ // strict mode and parsing of `import` and `export` declarations.
182
+ sourceType: "script",
183
+ // `onInsertedSemicolon` can be a callback that will be called when
184
+ // a semicolon is automatically inserted. It will be passed the
185
+ // position of the inserted semicolon as an offset, and if
186
+ // `locations` is enabled, it is given the location as a `{line,
187
+ // column}` object as second argument.
188
+ onInsertedSemicolon: null,
189
+ // `onTrailingComma` is similar to `onInsertedSemicolon`, but for
190
+ // trailing commas.
191
+ onTrailingComma: null,
192
+ // By default, reserved words are only enforced if ecmaVersion >= 5.
193
+ // Set `allowReserved` to a boolean value to explicitly turn this on
194
+ // an off. When this option has the value "never", reserved words
195
+ // and keywords can also not be used as property names.
196
+ allowReserved: null,
197
+ // When enabled, a return at the top level is not considered an
198
+ // error.
199
+ allowReturnOutsideFunction: !1,
200
+ // When enabled, import/export statements are not constrained to
201
+ // appearing at the top of the program, and an import.meta expression
202
+ // in a script isn't considered an error.
203
+ allowImportExportEverywhere: !1,
204
+ // By default, await identifiers are allowed to appear at the top-level scope only if ecmaVersion >= 2022.
205
+ // When enabled, await identifiers are allowed to appear at the top-level scope,
206
+ // but they are still not allowed in non-async functions.
207
+ allowAwaitOutsideFunction: null,
208
+ // When enabled, super identifiers are not constrained to
209
+ // appearing in methods and do not raise an error when they appear elsewhere.
210
+ allowSuperOutsideMethod: null,
211
+ // When enabled, hashbang directive in the beginning of file is
212
+ // allowed and treated as a line comment. Enabled by default when
213
+ // `ecmaVersion` >= 2023.
214
+ allowHashBang: !1,
215
+ // By default, the parser will verify that private properties are
216
+ // only used in places where they are valid and have been declared.
217
+ // Set this to false to turn such checks off.
218
+ checkPrivateFields: !0,
219
+ // When `locations` is on, `loc` properties holding objects with
220
+ // `start` and `end` properties in `{line, column}` form (with
221
+ // line being 1-based and column 0-based) will be attached to the
222
+ // nodes.
223
+ locations: !1,
224
+ // A function can be passed as `onToken` option, which will
225
+ // cause Acorn to call that function with object in the same
226
+ // format as tokens returned from `tokenizer().getToken()`. Note
227
+ // that you are not allowed to call the parser from the
228
+ // callback—that will corrupt its internal state.
229
+ onToken: null,
230
+ // A function can be passed as `onComment` option, which will
231
+ // cause Acorn to call that function with `(block, text, start,
232
+ // end)` parameters whenever a comment is skipped. `block` is a
233
+ // boolean indicating whether this is a block (`/* */`) comment,
234
+ // `text` is the content of the comment, and `start` and `end` are
235
+ // character offsets that denote the start and end of the comment.
236
+ // When the `locations` option is on, two more parameters are
237
+ // passed, the full `{line, column}` locations of the start and
238
+ // end of the comments. Note that you are not allowed to call the
239
+ // parser from the callback—that will corrupt its internal state.
240
+ // When this option has an array as value, objects representing the
241
+ // comments are pushed to it.
242
+ onComment: null,
243
+ // Nodes have their start and end characters offsets recorded in
244
+ // `start` and `end` properties (directly on the node, rather than
245
+ // the `loc` object, which holds line/column data. To also add a
246
+ // [semi-standardized][range] `range` property holding a `[start,
247
+ // end]` array with the same numbers, set the `ranges` option to
248
+ // `true`.
249
+ //
250
+ // [range]: https://bugzilla.mozilla.org/show_bug.cgi?id=745678
251
+ ranges: !1,
252
+ // It is possible to parse multiple files into a single AST by
253
+ // passing the tree produced by parsing the first file as
254
+ // `program` option in subsequent parses. This will add the
255
+ // toplevel forms of the parsed file to the `Program` (top) node
256
+ // of an existing parse tree.
257
+ program: null,
258
+ // When `locations` is on, you can pass this to record the source
259
+ // file in every node's `loc` object.
260
+ sourceFile: null,
261
+ // This value, if given, is stored in every node, whether
262
+ // `locations` is on or off.
263
+ directSourceFile: null,
264
+ // When enabled, parenthesized expressions are represented by
265
+ // (non-standard) ParenthesizedExpression nodes
266
+ preserveParens: !1
267
+ }, Ee = !1;
268
+ function Ct(e) {
269
+ var t = {};
270
+ for (var i in xe)
271
+ t[i] = e && K(e, i) ? e[i] : xe[i];
272
+ if (t.ecmaVersion === "latest" ? t.ecmaVersion = 1e8 : t.ecmaVersion == null ? (!Ee && typeof console == "object" && console.warn && (Ee = !0, console.warn(`Since Acorn 8.0.0, options.ecmaVersion is required.
273
+ Defaulting to 2020, but this will stop working in the future.`)), t.ecmaVersion = 11) : t.ecmaVersion >= 2015 && (t.ecmaVersion -= 2009), t.allowReserved == null && (t.allowReserved = t.ecmaVersion < 5), (!e || e.allowHashBang == null) && (t.allowHashBang = t.ecmaVersion >= 14), we(t.onToken)) {
274
+ var s = t.onToken;
275
+ t.onToken = function(r) {
276
+ return s.push(r);
277
+ };
278
+ }
279
+ if (we(t.onComment) && (t.onComment = St(t, t.onComment)), t.sourceType === "commonjs" && t.allowAwaitOutsideFunction)
280
+ throw new Error("Cannot use allowAwaitOutsideFunction with sourceType: commonjs");
281
+ return t;
282
+ }
283
+ function St(e, t) {
284
+ return function(i, s, r, n, u, o) {
285
+ var h = {
286
+ type: i ? "Block" : "Line",
287
+ value: s,
288
+ start: r,
289
+ end: n
290
+ };
291
+ e.locations && (h.loc = new re(this, u, o)), e.ranges && (h.range = [r, n]), t.push(h);
292
+ };
293
+ }
294
+ var U = 1, q = 2, be = 4, De = 8, ye = 16, Fe = 32, ne = 64, Me = 128, j = 256, J = 512, Ue = 1024, ue = U | q | j;
295
+ function _e(e, t) {
296
+ return q | (e ? be : 0) | (t ? De : 0);
297
+ }
298
+ var te = 0, Ce = 1, B = 2, qe = 3, je = 4, Ge = 5, y = function(t, i, s) {
299
+ this.options = t = Ct(t), this.sourceFile = t.sourceFile, this.keywords = D(xt[t.ecmaVersion >= 6 ? 6 : t.sourceType === "module" ? "5module" : 5]);
300
+ var r = "";
301
+ t.allowReserved !== !0 && (r = le[t.ecmaVersion >= 6 ? 6 : t.ecmaVersion === 5 ? 5 : 3], t.sourceType === "module" && (r += " await")), this.reservedWords = D(r);
302
+ var n = (r ? r + " " : "") + le.strict;
303
+ this.reservedWordsStrict = D(n), this.reservedWordsStrictBind = D(n + " " + le.strictBind), this.input = String(i), this.containsEsc = !1, s ? (this.pos = s, this.lineStart = this.input.lastIndexOf(`
304
+ `, s - 1) + 1, this.curLine = this.input.slice(0, this.lineStart).split(w).length) : (this.pos = this.lineStart = 0, this.curLine = 1), this.type = a.eof, this.value = null, this.start = this.end = this.pos, this.startLoc = this.endLoc = this.curPosition(), this.lastTokEndLoc = this.lastTokStartLoc = null, this.lastTokStart = this.lastTokEnd = this.pos, this.context = this.initialContext(), this.exprAllowed = !0, this.inModule = t.sourceType === "module", this.strict = this.inModule || this.strictDirective(this.pos), this.potentialArrowAt = -1, this.potentialArrowInForAwait = !1, this.yieldPos = this.awaitPos = this.awaitIdentPos = 0, this.labels = [], this.undefinedExports = /* @__PURE__ */ Object.create(null), this.pos === 0 && t.allowHashBang && this.input.slice(0, 2) === "#!" && this.skipLineComment(2), this.scopeStack = [], this.enterScope(
305
+ this.options.sourceType === "commonjs" ? q : U
306
+ ), this.regexpState = null, this.privateNameStack = [];
307
+ }, P = { inFunction: { configurable: !0 }, inGenerator: { configurable: !0 }, inAsync: { configurable: !0 }, canAwait: { configurable: !0 }, allowReturn: { configurable: !0 }, allowSuper: { configurable: !0 }, allowDirectSuper: { configurable: !0 }, treatFunctionsAsVar: { configurable: !0 }, allowNewDotTarget: { configurable: !0 }, allowUsing: { configurable: !0 }, inClassStaticBlock: { configurable: !0 } };
308
+ y.prototype.parse = function() {
309
+ var t = this.options.program || this.startNode();
310
+ return this.nextToken(), this.parseTopLevel(t);
311
+ };
312
+ P.inFunction.get = function() {
313
+ return (this.currentVarScope().flags & q) > 0;
314
+ };
315
+ P.inGenerator.get = function() {
316
+ return (this.currentVarScope().flags & De) > 0;
317
+ };
318
+ P.inAsync.get = function() {
319
+ return (this.currentVarScope().flags & be) > 0;
320
+ };
321
+ P.canAwait.get = function() {
322
+ for (var e = this.scopeStack.length - 1; e >= 0; e--) {
323
+ var t = this.scopeStack[e], i = t.flags;
324
+ if (i & (j | J))
325
+ return !1;
326
+ if (i & q)
327
+ return (i & be) > 0;
328
+ }
329
+ return this.inModule && this.options.ecmaVersion >= 13 || this.options.allowAwaitOutsideFunction;
330
+ };
331
+ P.allowReturn.get = function() {
332
+ return !!(this.inFunction || this.options.allowReturnOutsideFunction && this.currentVarScope().flags & U);
333
+ };
334
+ P.allowSuper.get = function() {
335
+ var e = this.currentThisScope(), t = e.flags;
336
+ return (t & ne) > 0 || this.options.allowSuperOutsideMethod;
337
+ };
338
+ P.allowDirectSuper.get = function() {
339
+ return (this.currentThisScope().flags & Me) > 0;
340
+ };
341
+ P.treatFunctionsAsVar.get = function() {
342
+ return this.treatFunctionsAsVarInScope(this.currentScope());
343
+ };
344
+ P.allowNewDotTarget.get = function() {
345
+ for (var e = this.scopeStack.length - 1; e >= 0; e--) {
346
+ var t = this.scopeStack[e], i = t.flags;
347
+ if (i & (j | J) || i & q && !(i & ye))
348
+ return !0;
349
+ }
350
+ return !1;
351
+ };
352
+ P.allowUsing.get = function() {
353
+ var e = this.currentScope(), t = e.flags;
354
+ return !(t & Ue || !this.inModule && t & U);
355
+ };
356
+ P.inClassStaticBlock.get = function() {
357
+ return (this.currentVarScope().flags & j) > 0;
358
+ };
359
+ y.extend = function() {
360
+ for (var t = [], i = arguments.length; i--; ) t[i] = arguments[i];
361
+ for (var s = this, r = 0; r < t.length; r++)
362
+ s = t[r](s);
363
+ return s;
364
+ };
365
+ y.parse = function(t, i) {
366
+ return new this(i, t).parse();
367
+ };
368
+ y.parseExpressionAt = function(t, i, s) {
369
+ var r = new this(s, t, i);
370
+ return r.nextToken(), r.parseExpression();
371
+ };
372
+ y.tokenizer = function(t, i) {
373
+ return new this(i, t);
374
+ };
375
+ Object.defineProperties(y.prototype, P);
376
+ var S = y.prototype, kt = /^(?:'((?:\\[^]|[^'\\])*?)'|"((?:\\[^]|[^"\\])*?)")/;
377
+ S.strictDirective = function(e) {
378
+ if (this.options.ecmaVersion < 5)
379
+ return !1;
380
+ for (; ; ) {
381
+ C.lastIndex = e, e += C.exec(this.input)[0].length;
382
+ var t = kt.exec(this.input.slice(e));
383
+ if (!t)
384
+ return !1;
385
+ if ((t[1] || t[2]) === "use strict") {
386
+ C.lastIndex = e + t[0].length;
387
+ var i = C.exec(this.input), s = i.index + i[0].length, r = this.input.charAt(s);
388
+ return r === ";" || r === "}" || w.test(i[0]) && !(/[(`.[+\-/*%<>=,?^&]/.test(r) || r === "!" && this.input.charAt(s + 1) === "=");
389
+ }
390
+ e += t[0].length, C.lastIndex = e, e += C.exec(this.input)[0].length, this.input[e] === ";" && e++;
391
+ }
392
+ };
393
+ S.eat = function(e) {
394
+ return this.type === e ? (this.next(), !0) : !1;
395
+ };
396
+ S.isContextual = function(e) {
397
+ return this.type === a.name && this.value === e && !this.containsEsc;
398
+ };
399
+ S.eatContextual = function(e) {
400
+ return this.isContextual(e) ? (this.next(), !0) : !1;
401
+ };
402
+ S.expectContextual = function(e) {
403
+ this.eatContextual(e) || this.unexpected();
404
+ };
405
+ S.canInsertSemicolon = function() {
406
+ return this.type === a.eof || this.type === a.braceR || w.test(this.input.slice(this.lastTokEnd, this.start));
407
+ };
408
+ S.insertSemicolon = function() {
409
+ if (this.canInsertSemicolon())
410
+ return this.options.onInsertedSemicolon && this.options.onInsertedSemicolon(this.lastTokEnd, this.lastTokEndLoc), !0;
411
+ };
412
+ S.semicolon = function() {
413
+ !this.eat(a.semi) && !this.insertSemicolon() && this.unexpected();
414
+ };
415
+ S.afterTrailingComma = function(e, t) {
416
+ if (this.type === e)
417
+ return this.options.onTrailingComma && this.options.onTrailingComma(this.lastTokStart, this.lastTokStartLoc), t || this.next(), !0;
418
+ };
419
+ S.expect = function(e) {
420
+ this.eat(e) || this.unexpected();
421
+ };
422
+ S.unexpected = function(e) {
423
+ this.raise(e ?? this.start, "Unexpected token");
424
+ };
425
+ var oe = function() {
426
+ this.shorthandAssign = this.trailingComma = this.parenthesizedAssign = this.parenthesizedBind = this.doubleProto = -1;
427
+ };
428
+ S.checkPatternErrors = function(e, t) {
429
+ if (e) {
430
+ e.trailingComma > -1 && this.raiseRecoverable(e.trailingComma, "Comma is not permitted after the rest element");
431
+ var i = t ? e.parenthesizedAssign : e.parenthesizedBind;
432
+ i > -1 && this.raiseRecoverable(i, t ? "Assigning to rvalue" : "Parenthesized pattern");
433
+ }
434
+ };
435
+ S.checkExpressionErrors = function(e, t) {
436
+ if (!e)
437
+ return !1;
438
+ var i = e.shorthandAssign, s = e.doubleProto;
439
+ if (!t)
440
+ return i >= 0 || s >= 0;
441
+ i >= 0 && this.raise(i, "Shorthand property assignments are valid only in destructuring patterns"), s >= 0 && this.raiseRecoverable(s, "Redefinition of __proto__ property");
442
+ };
443
+ S.checkYieldAwaitInDefaultParams = function() {
444
+ this.yieldPos && (!this.awaitPos || this.yieldPos < this.awaitPos) && this.raise(this.yieldPos, "Yield expression cannot be a default value"), this.awaitPos && this.raise(this.awaitPos, "Await expression cannot be a default value");
445
+ };
446
+ S.isSimpleAssignTarget = function(e) {
447
+ return e.type === "ParenthesizedExpression" ? this.isSimpleAssignTarget(e.expression) : e.type === "Identifier" || e.type === "MemberExpression";
448
+ };
449
+ var l = y.prototype;
450
+ l.parseTopLevel = function(e) {
451
+ var t = /* @__PURE__ */ Object.create(null);
452
+ for (e.body || (e.body = []); this.type !== a.eof; ) {
453
+ var i = this.parseStatement(null, !0, t);
454
+ e.body.push(i);
455
+ }
456
+ if (this.inModule)
457
+ for (var s = 0, r = Object.keys(this.undefinedExports); s < r.length; s += 1) {
458
+ var n = r[s];
459
+ this.raiseRecoverable(this.undefinedExports[n].start, "Export '" + n + "' is not defined");
460
+ }
461
+ return this.adaptDirectivePrologue(e.body), this.next(), e.sourceType = this.options.sourceType === "commonjs" ? "script" : this.options.sourceType, this.finishNode(e, "Program");
462
+ };
463
+ var Se = { kind: "loop" }, wt = { kind: "switch" };
464
+ l.isLet = function(e) {
465
+ if (this.options.ecmaVersion < 6 || !this.isContextual("let"))
466
+ return !1;
467
+ C.lastIndex = this.pos;
468
+ var t = C.exec(this.input), i = this.pos + t[0].length, s = this.fullCharCodeAt(i);
469
+ if (s === 91 || s === 92)
470
+ return !0;
471
+ if (e)
472
+ return !1;
473
+ if (s === 123)
474
+ return !0;
475
+ if (T(s)) {
476
+ var r = i;
477
+ do
478
+ i += s <= 65535 ? 1 : 2;
479
+ while (F(s = this.fullCharCodeAt(i)));
480
+ if (s === 92)
481
+ return !0;
482
+ var n = this.input.slice(r, i);
483
+ if (!Te.test(n))
484
+ return !0;
485
+ }
486
+ return !1;
487
+ };
488
+ l.isAsyncFunction = function() {
489
+ if (this.options.ecmaVersion < 8 || !this.isContextual("async"))
490
+ return !1;
491
+ C.lastIndex = this.pos;
492
+ var e = C.exec(this.input), t = this.pos + e[0].length, i;
493
+ return !w.test(this.input.slice(this.pos, t)) && this.input.slice(t, t + 8) === "function" && (t + 8 === this.input.length || !(F(i = this.fullCharCodeAt(t + 8)) || i === 92));
494
+ };
495
+ l.isUsingKeyword = function(e, t) {
496
+ if (this.options.ecmaVersion < 17 || !this.isContextual(e ? "await" : "using"))
497
+ return !1;
498
+ C.lastIndex = this.pos;
499
+ var i = C.exec(this.input), s = this.pos + i[0].length;
500
+ if (w.test(this.input.slice(this.pos, s)))
501
+ return !1;
502
+ if (e) {
503
+ var r = s + 5, n;
504
+ if (this.input.slice(s, r) !== "using" || r === this.input.length || F(n = this.fullCharCodeAt(r)) || n === 92)
505
+ return !1;
506
+ C.lastIndex = r;
507
+ var u = C.exec(this.input);
508
+ if (s = r + u[0].length, u && w.test(this.input.slice(r, s)))
509
+ return !1;
510
+ }
511
+ var o = this.fullCharCodeAt(s);
512
+ if (!T(o) && o !== 92)
513
+ return !1;
514
+ var h = s;
515
+ do
516
+ s += o <= 65535 ? 1 : 2;
517
+ while (F(o = this.fullCharCodeAt(s)));
518
+ if (o === 92)
519
+ return !0;
520
+ var p = this.input.slice(h, s);
521
+ return !(Te.test(p) || t && p === "of");
522
+ };
523
+ l.isAwaitUsing = function(e) {
524
+ return this.isUsingKeyword(!0, e);
525
+ };
526
+ l.isUsing = function(e) {
527
+ return this.isUsingKeyword(!1, e);
528
+ };
529
+ l.parseStatement = function(e, t, i) {
530
+ var s = this.type, r = this.startNode(), n;
531
+ switch (this.isLet(e) && (s = a._var, n = "let"), s) {
532
+ case a._break:
533
+ case a._continue:
534
+ return this.parseBreakContinueStatement(r, s.keyword);
535
+ case a._debugger:
536
+ return this.parseDebuggerStatement(r);
537
+ case a._do:
538
+ return this.parseDoStatement(r);
539
+ case a._for:
540
+ return this.parseForStatement(r);
541
+ case a._function:
542
+ return e && (this.strict || e !== "if" && e !== "label") && this.options.ecmaVersion >= 6 && this.unexpected(), this.parseFunctionStatement(r, !1, !e);
543
+ case a._class:
544
+ return e && this.unexpected(), this.parseClass(r, !0);
545
+ case a._if:
546
+ return this.parseIfStatement(r);
547
+ case a._return:
548
+ return this.parseReturnStatement(r);
549
+ case a._switch:
550
+ return this.parseSwitchStatement(r);
551
+ case a._throw:
552
+ return this.parseThrowStatement(r);
553
+ case a._try:
554
+ return this.parseTryStatement(r);
555
+ case a._const:
556
+ case a._var:
557
+ return n = n || this.value, e && n !== "var" && this.unexpected(), this.parseVarStatement(r, n);
558
+ case a._while:
559
+ return this.parseWhileStatement(r);
560
+ case a._with:
561
+ return this.parseWithStatement(r);
562
+ case a.braceL:
563
+ return this.parseBlock(!0, r);
564
+ case a.semi:
565
+ return this.parseEmptyStatement(r);
566
+ case a._export:
567
+ case a._import:
568
+ if (this.options.ecmaVersion > 10 && s === a._import) {
569
+ C.lastIndex = this.pos;
570
+ var u = C.exec(this.input), o = this.pos + u[0].length, h = this.input.charCodeAt(o);
571
+ if (h === 40 || h === 46)
572
+ return this.parseExpressionStatement(r, this.parseExpression());
573
+ }
574
+ return this.options.allowImportExportEverywhere || (t || this.raise(this.start, "'import' and 'export' may only appear at the top level"), this.inModule || this.raise(this.start, "'import' and 'export' may appear only with 'sourceType: module'")), s === a._import ? this.parseImport(r) : this.parseExport(r, i);
575
+ // If the statement does not start with a statement keyword or a
576
+ // brace, it's an ExpressionStatement or LabeledStatement. We
577
+ // simply start parsing an expression, and afterwards, if the
578
+ // next token is a colon and the expression was a simple
579
+ // Identifier node, we switch to interpreting it as a label.
580
+ default:
581
+ if (this.isAsyncFunction())
582
+ return e && this.unexpected(), this.next(), this.parseFunctionStatement(r, !0, !e);
583
+ var p = this.isAwaitUsing(!1) ? "await using" : this.isUsing(!1) ? "using" : null;
584
+ if (p)
585
+ return this.allowUsing || this.raise(this.start, "Using declaration cannot appear in the top level when source type is `script` or in the bare case statement"), p === "await using" && (this.canAwait || this.raise(this.start, "Await using cannot appear outside of async function"), this.next()), this.next(), this.parseVar(r, !1, p), this.semicolon(), this.finishNode(r, "VariableDeclaration");
586
+ var d = this.value, g = this.parseExpression();
587
+ return s === a.name && g.type === "Identifier" && this.eat(a.colon) ? this.parseLabeledStatement(r, d, g, e) : this.parseExpressionStatement(r, g);
588
+ }
589
+ };
590
+ l.parseBreakContinueStatement = function(e, t) {
591
+ var i = t === "break";
592
+ this.next(), this.eat(a.semi) || this.insertSemicolon() ? e.label = null : this.type !== a.name ? this.unexpected() : (e.label = this.parseIdent(), this.semicolon());
593
+ for (var s = 0; s < this.labels.length; ++s) {
594
+ var r = this.labels[s];
595
+ if ((e.label == null || r.name === e.label.name) && (r.kind != null && (i || r.kind === "loop") || e.label && i))
596
+ break;
597
+ }
598
+ return s === this.labels.length && this.raise(e.start, "Unsyntactic " + t), this.finishNode(e, i ? "BreakStatement" : "ContinueStatement");
599
+ };
600
+ l.parseDebuggerStatement = function(e) {
601
+ return this.next(), this.semicolon(), this.finishNode(e, "DebuggerStatement");
602
+ };
603
+ l.parseDoStatement = function(e) {
604
+ return this.next(), this.labels.push(Se), e.body = this.parseStatement("do"), this.labels.pop(), this.expect(a._while), e.test = this.parseParenExpression(), this.options.ecmaVersion >= 6 ? this.eat(a.semi) : this.semicolon(), this.finishNode(e, "DoWhileStatement");
605
+ };
606
+ l.parseForStatement = function(e) {
607
+ this.next();
608
+ var t = this.options.ecmaVersion >= 9 && this.canAwait && this.eatContextual("await") ? this.lastTokStart : -1;
609
+ if (this.labels.push(Se), this.enterScope(0), this.expect(a.parenL), this.type === a.semi)
610
+ return t > -1 && this.unexpected(t), this.parseFor(e, null);
611
+ var i = this.isLet();
612
+ if (this.type === a._var || this.type === a._const || i) {
613
+ var s = this.startNode(), r = i ? "let" : this.value;
614
+ return this.next(), this.parseVar(s, !0, r), this.finishNode(s, "VariableDeclaration"), this.parseForAfterInit(e, s, t);
615
+ }
616
+ var n = this.isContextual("let"), u = !1, o = this.isUsing(!0) ? "using" : this.isAwaitUsing(!0) ? "await using" : null;
617
+ if (o) {
618
+ var h = this.startNode();
619
+ return this.next(), o === "await using" && (this.canAwait || this.raise(this.start, "Await using cannot appear outside of async function"), this.next()), this.parseVar(h, !0, o), this.finishNode(h, "VariableDeclaration"), this.parseForAfterInit(e, h, t);
620
+ }
621
+ var p = this.containsEsc, d = new oe(), g = this.start, _ = t > -1 ? this.parseExprSubscripts(d, "await") : this.parseExpression(!0, d);
622
+ return this.type === a._in || (u = this.options.ecmaVersion >= 6 && this.isContextual("of")) ? (t > -1 ? (this.type === a._in && this.unexpected(t), e.await = !0) : u && this.options.ecmaVersion >= 8 && (_.start === g && !p && _.type === "Identifier" && _.name === "async" ? this.unexpected() : this.options.ecmaVersion >= 9 && (e.await = !1)), n && u && this.raise(_.start, "The left-hand side of a for-of loop may not start with 'let'."), this.toAssignable(_, !1, d), this.checkLValPattern(_), this.parseForIn(e, _)) : (this.checkExpressionErrors(d, !0), t > -1 && this.unexpected(t), this.parseFor(e, _));
623
+ };
624
+ l.parseForAfterInit = function(e, t, i) {
625
+ return (this.type === a._in || this.options.ecmaVersion >= 6 && this.isContextual("of")) && t.declarations.length === 1 ? (this.options.ecmaVersion >= 9 && (this.type === a._in ? i > -1 && this.unexpected(i) : e.await = i > -1), this.parseForIn(e, t)) : (i > -1 && this.unexpected(i), this.parseFor(e, t));
626
+ };
627
+ l.parseFunctionStatement = function(e, t, i) {
628
+ return this.next(), this.parseFunction(e, X | (i ? 0 : me), !1, t);
629
+ };
630
+ l.parseIfStatement = function(e) {
631
+ return this.next(), e.test = this.parseParenExpression(), e.consequent = this.parseStatement("if"), e.alternate = this.eat(a._else) ? this.parseStatement("if") : null, this.finishNode(e, "IfStatement");
632
+ };
633
+ l.parseReturnStatement = function(e) {
634
+ return this.allowReturn || this.raise(this.start, "'return' outside of function"), this.next(), this.eat(a.semi) || this.insertSemicolon() ? e.argument = null : (e.argument = this.parseExpression(), this.semicolon()), this.finishNode(e, "ReturnStatement");
635
+ };
636
+ l.parseSwitchStatement = function(e) {
637
+ this.next(), e.discriminant = this.parseParenExpression(), e.cases = [], this.expect(a.braceL), this.labels.push(wt), this.enterScope(Ue);
638
+ for (var t, i = !1; this.type !== a.braceR; )
639
+ if (this.type === a._case || this.type === a._default) {
640
+ var s = this.type === a._case;
641
+ t && this.finishNode(t, "SwitchCase"), e.cases.push(t = this.startNode()), t.consequent = [], this.next(), s ? t.test = this.parseExpression() : (i && this.raiseRecoverable(this.lastTokStart, "Multiple default clauses"), i = !0, t.test = null), this.expect(a.colon);
642
+ } else
643
+ t || this.unexpected(), t.consequent.push(this.parseStatement(null));
644
+ return this.exitScope(), t && this.finishNode(t, "SwitchCase"), this.next(), this.labels.pop(), this.finishNode(e, "SwitchStatement");
645
+ };
646
+ l.parseThrowStatement = function(e) {
647
+ return this.next(), w.test(this.input.slice(this.lastTokEnd, this.start)) && this.raise(this.lastTokEnd, "Illegal newline after throw"), e.argument = this.parseExpression(), this.semicolon(), this.finishNode(e, "ThrowStatement");
648
+ };
649
+ var At = [];
650
+ l.parseCatchClauseParam = function() {
651
+ var e = this.parseBindingAtom(), t = e.type === "Identifier";
652
+ return this.enterScope(t ? Fe : 0), this.checkLValPattern(e, t ? je : B), this.expect(a.parenR), e;
653
+ };
654
+ l.parseTryStatement = function(e) {
655
+ if (this.next(), e.block = this.parseBlock(), e.handler = null, this.type === a._catch) {
656
+ var t = this.startNode();
657
+ this.next(), this.eat(a.parenL) ? t.param = this.parseCatchClauseParam() : (this.options.ecmaVersion < 10 && this.unexpected(), t.param = null, this.enterScope(0)), t.body = this.parseBlock(!1), this.exitScope(), e.handler = this.finishNode(t, "CatchClause");
658
+ }
659
+ return e.finalizer = this.eat(a._finally) ? this.parseBlock() : null, !e.handler && !e.finalizer && this.raise(e.start, "Missing catch or finally clause"), this.finishNode(e, "TryStatement");
660
+ };
661
+ l.parseVarStatement = function(e, t, i) {
662
+ return this.next(), this.parseVar(e, !1, t, i), this.semicolon(), this.finishNode(e, "VariableDeclaration");
663
+ };
664
+ l.parseWhileStatement = function(e) {
665
+ return this.next(), e.test = this.parseParenExpression(), this.labels.push(Se), e.body = this.parseStatement("while"), this.labels.pop(), this.finishNode(e, "WhileStatement");
666
+ };
667
+ l.parseWithStatement = function(e) {
668
+ return this.strict && this.raise(this.start, "'with' in strict mode"), this.next(), e.object = this.parseParenExpression(), e.body = this.parseStatement("with"), this.finishNode(e, "WithStatement");
669
+ };
670
+ l.parseEmptyStatement = function(e) {
671
+ return this.next(), this.finishNode(e, "EmptyStatement");
672
+ };
673
+ l.parseLabeledStatement = function(e, t, i, s) {
674
+ for (var r = 0, n = this.labels; r < n.length; r += 1) {
675
+ var u = n[r];
676
+ u.name === t && this.raise(i.start, "Label '" + t + "' is already declared");
677
+ }
678
+ for (var o = this.type.isLoop ? "loop" : this.type === a._switch ? "switch" : null, h = this.labels.length - 1; h >= 0; h--) {
679
+ var p = this.labels[h];
680
+ if (p.statementStart === e.start)
681
+ p.statementStart = this.start, p.kind = o;
682
+ else
683
+ break;
684
+ }
685
+ return this.labels.push({ name: t, kind: o, statementStart: this.start }), e.body = this.parseStatement(s ? s.indexOf("label") === -1 ? s + "label" : s : "label"), this.labels.pop(), e.label = i, this.finishNode(e, "LabeledStatement");
686
+ };
687
+ l.parseExpressionStatement = function(e, t) {
688
+ return e.expression = t, this.semicolon(), this.finishNode(e, "ExpressionStatement");
689
+ };
690
+ l.parseBlock = function(e, t, i) {
691
+ for (e === void 0 && (e = !0), t === void 0 && (t = this.startNode()), t.body = [], this.expect(a.braceL), e && this.enterScope(0); this.type !== a.braceR; ) {
692
+ var s = this.parseStatement(null);
693
+ t.body.push(s);
694
+ }
695
+ return i && (this.strict = !1), this.next(), e && this.exitScope(), this.finishNode(t, "BlockStatement");
696
+ };
697
+ l.parseFor = function(e, t) {
698
+ return e.init = t, this.expect(a.semi), e.test = this.type === a.semi ? null : this.parseExpression(), this.expect(a.semi), e.update = this.type === a.parenR ? null : this.parseExpression(), this.expect(a.parenR), e.body = this.parseStatement("for"), this.exitScope(), this.labels.pop(), this.finishNode(e, "ForStatement");
699
+ };
700
+ l.parseForIn = function(e, t) {
701
+ var i = this.type === a._in;
702
+ return this.next(), t.type === "VariableDeclaration" && t.declarations[0].init != null && (!i || this.options.ecmaVersion < 8 || this.strict || t.kind !== "var" || t.declarations[0].id.type !== "Identifier") && this.raise(
703
+ t.start,
704
+ (i ? "for-in" : "for-of") + " loop variable declaration may not have an initializer"
705
+ ), e.left = t, e.right = i ? this.parseExpression() : this.parseMaybeAssign(), this.expect(a.parenR), e.body = this.parseStatement("for"), this.exitScope(), this.labels.pop(), this.finishNode(e, i ? "ForInStatement" : "ForOfStatement");
706
+ };
707
+ l.parseVar = function(e, t, i, s) {
708
+ for (e.declarations = [], e.kind = i; ; ) {
709
+ var r = this.startNode();
710
+ if (this.parseVarId(r, i), this.eat(a.eq) ? r.init = this.parseMaybeAssign(t) : !s && i === "const" && !(this.type === a._in || this.options.ecmaVersion >= 6 && this.isContextual("of")) ? this.unexpected() : !s && (i === "using" || i === "await using") && this.options.ecmaVersion >= 17 && this.type !== a._in && !this.isContextual("of") ? this.raise(this.lastTokEnd, "Missing initializer in " + i + " declaration") : !s && r.id.type !== "Identifier" && !(t && (this.type === a._in || this.isContextual("of"))) ? this.raise(this.lastTokEnd, "Complex binding patterns require an initialization value") : r.init = null, e.declarations.push(this.finishNode(r, "VariableDeclarator")), !this.eat(a.comma))
711
+ break;
712
+ }
713
+ return e;
714
+ };
715
+ l.parseVarId = function(e, t) {
716
+ e.id = t === "using" || t === "await using" ? this.parseIdent() : this.parseBindingAtom(), this.checkLValPattern(e.id, t === "var" ? Ce : B, !1);
717
+ };
718
+ var X = 1, me = 2, He = 4;
719
+ l.parseFunction = function(e, t, i, s, r) {
720
+ this.initFunction(e), (this.options.ecmaVersion >= 9 || this.options.ecmaVersion >= 6 && !s) && (this.type === a.star && t & me && this.unexpected(), e.generator = this.eat(a.star)), this.options.ecmaVersion >= 8 && (e.async = !!s), t & X && (e.id = t & He && this.type !== a.name ? null : this.parseIdent(), e.id && !(t & me) && this.checkLValSimple(e.id, this.strict || e.generator || e.async ? this.treatFunctionsAsVar ? Ce : B : qe));
721
+ var n = this.yieldPos, u = this.awaitPos, o = this.awaitIdentPos;
722
+ return this.yieldPos = 0, this.awaitPos = 0, this.awaitIdentPos = 0, this.enterScope(_e(e.async, e.generator)), t & X || (e.id = this.type === a.name ? this.parseIdent() : null), this.parseFunctionParams(e), this.parseFunctionBody(e, i, !1, r), this.yieldPos = n, this.awaitPos = u, this.awaitIdentPos = o, this.finishNode(e, t & X ? "FunctionDeclaration" : "FunctionExpression");
723
+ };
724
+ l.parseFunctionParams = function(e) {
725
+ this.expect(a.parenL), e.params = this.parseBindingList(a.parenR, !1, this.options.ecmaVersion >= 8), this.checkYieldAwaitInDefaultParams();
726
+ };
727
+ l.parseClass = function(e, t) {
728
+ this.next();
729
+ var i = this.strict;
730
+ this.strict = !0, this.parseClassId(e, t), this.parseClassSuper(e);
731
+ var s = this.enterClassBody(), r = this.startNode(), n = !1;
732
+ for (r.body = [], this.expect(a.braceL); this.type !== a.braceR; ) {
733
+ var u = this.parseClassElement(e.superClass !== null);
734
+ u && (r.body.push(u), u.type === "MethodDefinition" && u.kind === "constructor" ? (n && this.raiseRecoverable(u.start, "Duplicate constructor in the same class"), n = !0) : u.key && u.key.type === "PrivateIdentifier" && Et(s, u) && this.raiseRecoverable(u.key.start, "Identifier '#" + u.key.name + "' has already been declared"));
735
+ }
736
+ return this.strict = i, this.next(), e.body = this.finishNode(r, "ClassBody"), this.exitClassBody(), this.finishNode(e, t ? "ClassDeclaration" : "ClassExpression");
737
+ };
738
+ l.parseClassElement = function(e) {
739
+ if (this.eat(a.semi))
740
+ return null;
741
+ var t = this.options.ecmaVersion, i = this.startNode(), s = "", r = !1, n = !1, u = "method", o = !1;
742
+ if (this.eatContextual("static")) {
743
+ if (t >= 13 && this.eat(a.braceL))
744
+ return this.parseClassStaticBlock(i), i;
745
+ this.isClassElementNameStart() || this.type === a.star ? o = !0 : s = "static";
746
+ }
747
+ if (i.static = o, !s && t >= 8 && this.eatContextual("async") && ((this.isClassElementNameStart() || this.type === a.star) && !this.canInsertSemicolon() ? n = !0 : s = "async"), !s && (t >= 9 || !n) && this.eat(a.star) && (r = !0), !s && !n && !r) {
748
+ var h = this.value;
749
+ (this.eatContextual("get") || this.eatContextual("set")) && (this.isClassElementNameStart() ? u = h : s = h);
750
+ }
751
+ if (s ? (i.computed = !1, i.key = this.startNodeAt(this.lastTokStart, this.lastTokStartLoc), i.key.name = s, this.finishNode(i.key, "Identifier")) : this.parseClassElementName(i), t < 13 || this.type === a.parenL || u !== "method" || r || n) {
752
+ var p = !i.static && ie(i, "constructor"), d = p && e;
753
+ p && u !== "method" && this.raise(i.key.start, "Constructor can't have get/set modifier"), i.kind = p ? "constructor" : u, this.parseClassMethod(i, r, n, d);
754
+ } else
755
+ this.parseClassField(i);
756
+ return i;
757
+ };
758
+ l.isClassElementNameStart = function() {
759
+ return this.type === a.name || this.type === a.privateId || this.type === a.num || this.type === a.string || this.type === a.bracketL || this.type.keyword;
760
+ };
761
+ l.parseClassElementName = function(e) {
762
+ this.type === a.privateId ? (this.value === "constructor" && this.raise(this.start, "Classes can't have an element named '#constructor'"), e.computed = !1, e.key = this.parsePrivateIdent()) : this.parsePropertyName(e);
763
+ };
764
+ l.parseClassMethod = function(e, t, i, s) {
765
+ var r = e.key;
766
+ e.kind === "constructor" ? (t && this.raise(r.start, "Constructor can't be a generator"), i && this.raise(r.start, "Constructor can't be an async method")) : e.static && ie(e, "prototype") && this.raise(r.start, "Classes may not have a static property named prototype");
767
+ var n = e.value = this.parseMethod(t, i, s);
768
+ return e.kind === "get" && n.params.length !== 0 && this.raiseRecoverable(n.start, "getter should have no params"), e.kind === "set" && n.params.length !== 1 && this.raiseRecoverable(n.start, "setter should have exactly one param"), e.kind === "set" && n.params[0].type === "RestElement" && this.raiseRecoverable(n.params[0].start, "Setter cannot use rest params"), this.finishNode(e, "MethodDefinition");
769
+ };
770
+ l.parseClassField = function(e) {
771
+ return ie(e, "constructor") ? this.raise(e.key.start, "Classes can't have a field named 'constructor'") : e.static && ie(e, "prototype") && this.raise(e.key.start, "Classes can't have a static field named 'prototype'"), this.eat(a.eq) ? (this.enterScope(J | ne), e.value = this.parseMaybeAssign(), this.exitScope()) : e.value = null, this.semicolon(), this.finishNode(e, "PropertyDefinition");
772
+ };
773
+ l.parseClassStaticBlock = function(e) {
774
+ e.body = [];
775
+ var t = this.labels;
776
+ for (this.labels = [], this.enterScope(j | ne); this.type !== a.braceR; ) {
777
+ var i = this.parseStatement(null);
778
+ e.body.push(i);
779
+ }
780
+ return this.next(), this.exitScope(), this.labels = t, this.finishNode(e, "StaticBlock");
781
+ };
782
+ l.parseClassId = function(e, t) {
783
+ this.type === a.name ? (e.id = this.parseIdent(), t && this.checkLValSimple(e.id, B, !1)) : (t === !0 && this.unexpected(), e.id = null);
784
+ };
785
+ l.parseClassSuper = function(e) {
786
+ e.superClass = this.eat(a._extends) ? this.parseExprSubscripts(null, !1) : null;
787
+ };
788
+ l.enterClassBody = function() {
789
+ var e = { declared: /* @__PURE__ */ Object.create(null), used: [] };
790
+ return this.privateNameStack.push(e), e.declared;
791
+ };
792
+ l.exitClassBody = function() {
793
+ var e = this.privateNameStack.pop(), t = e.declared, i = e.used;
794
+ if (this.options.checkPrivateFields)
795
+ for (var s = this.privateNameStack.length, r = s === 0 ? null : this.privateNameStack[s - 1], n = 0; n < i.length; ++n) {
796
+ var u = i[n];
797
+ K(t, u.name) || (r ? r.used.push(u) : this.raiseRecoverable(u.start, "Private field '#" + u.name + "' must be declared in an enclosing class"));
798
+ }
799
+ };
800
+ function Et(e, t) {
801
+ var i = t.key.name, s = e[i], r = "true";
802
+ return t.type === "MethodDefinition" && (t.kind === "get" || t.kind === "set") && (r = (t.static ? "s" : "i") + t.kind), s === "iget" && r === "iset" || s === "iset" && r === "iget" || s === "sget" && r === "sset" || s === "sset" && r === "sget" ? (e[i] = "true", !1) : s ? !0 : (e[i] = r, !1);
803
+ }
804
+ function ie(e, t) {
805
+ var i = e.computed, s = e.key;
806
+ return !i && (s.type === "Identifier" && s.name === t || s.type === "Literal" && s.value === t);
807
+ }
808
+ l.parseExportAllDeclaration = function(e, t) {
809
+ return this.options.ecmaVersion >= 11 && (this.eatContextual("as") ? (e.exported = this.parseModuleExportName(), this.checkExport(t, e.exported, this.lastTokStart)) : e.exported = null), this.expectContextual("from"), this.type !== a.string && this.unexpected(), e.source = this.parseExprAtom(), this.options.ecmaVersion >= 16 && (e.attributes = this.parseWithClause()), this.semicolon(), this.finishNode(e, "ExportAllDeclaration");
810
+ };
811
+ l.parseExport = function(e, t) {
812
+ if (this.next(), this.eat(a.star))
813
+ return this.parseExportAllDeclaration(e, t);
814
+ if (this.eat(a._default))
815
+ return this.checkExport(t, "default", this.lastTokStart), e.declaration = this.parseExportDefaultDeclaration(), this.finishNode(e, "ExportDefaultDeclaration");
816
+ if (this.shouldParseExportStatement())
817
+ e.declaration = this.parseExportDeclaration(e), e.declaration.type === "VariableDeclaration" ? this.checkVariableExport(t, e.declaration.declarations) : this.checkExport(t, e.declaration.id, e.declaration.id.start), e.specifiers = [], e.source = null, this.options.ecmaVersion >= 16 && (e.attributes = []);
818
+ else {
819
+ if (e.declaration = null, e.specifiers = this.parseExportSpecifiers(t), this.eatContextual("from"))
820
+ this.type !== a.string && this.unexpected(), e.source = this.parseExprAtom(), this.options.ecmaVersion >= 16 && (e.attributes = this.parseWithClause());
821
+ else {
822
+ for (var i = 0, s = e.specifiers; i < s.length; i += 1) {
823
+ var r = s[i];
824
+ this.checkUnreserved(r.local), this.checkLocalExport(r.local), r.local.type === "Literal" && this.raise(r.local.start, "A string literal cannot be used as an exported binding without `from`.");
825
+ }
826
+ e.source = null, this.options.ecmaVersion >= 16 && (e.attributes = []);
827
+ }
828
+ this.semicolon();
829
+ }
830
+ return this.finishNode(e, "ExportNamedDeclaration");
831
+ };
832
+ l.parseExportDeclaration = function(e) {
833
+ return this.parseStatement(null);
834
+ };
835
+ l.parseExportDefaultDeclaration = function() {
836
+ var e;
837
+ if (this.type === a._function || (e = this.isAsyncFunction())) {
838
+ var t = this.startNode();
839
+ return this.next(), e && this.next(), this.parseFunction(t, X | He, !1, e);
840
+ } else if (this.type === a._class) {
841
+ var i = this.startNode();
842
+ return this.parseClass(i, "nullableID");
843
+ } else {
844
+ var s = this.parseMaybeAssign();
845
+ return this.semicolon(), s;
846
+ }
847
+ };
848
+ l.checkExport = function(e, t, i) {
849
+ e && (typeof t != "string" && (t = t.type === "Identifier" ? t.name : t.value), K(e, t) && this.raiseRecoverable(i, "Duplicate export '" + t + "'"), e[t] = !0);
850
+ };
851
+ l.checkPatternExport = function(e, t) {
852
+ var i = t.type;
853
+ if (i === "Identifier")
854
+ this.checkExport(e, t, t.start);
855
+ else if (i === "ObjectPattern")
856
+ for (var s = 0, r = t.properties; s < r.length; s += 1) {
857
+ var n = r[s];
858
+ this.checkPatternExport(e, n);
859
+ }
860
+ else if (i === "ArrayPattern")
861
+ for (var u = 0, o = t.elements; u < o.length; u += 1) {
862
+ var h = o[u];
863
+ h && this.checkPatternExport(e, h);
864
+ }
865
+ else i === "Property" ? this.checkPatternExport(e, t.value) : i === "AssignmentPattern" ? this.checkPatternExport(e, t.left) : i === "RestElement" && this.checkPatternExport(e, t.argument);
866
+ };
867
+ l.checkVariableExport = function(e, t) {
868
+ if (e)
869
+ for (var i = 0, s = t; i < s.length; i += 1) {
870
+ var r = s[i];
871
+ this.checkPatternExport(e, r.id);
872
+ }
873
+ };
874
+ l.shouldParseExportStatement = function() {
875
+ return this.type.keyword === "var" || this.type.keyword === "const" || this.type.keyword === "class" || this.type.keyword === "function" || this.isLet() || this.isAsyncFunction();
876
+ };
877
+ l.parseExportSpecifier = function(e) {
878
+ var t = this.startNode();
879
+ return t.local = this.parseModuleExportName(), t.exported = this.eatContextual("as") ? this.parseModuleExportName() : t.local, this.checkExport(
880
+ e,
881
+ t.exported,
882
+ t.exported.start
883
+ ), this.finishNode(t, "ExportSpecifier");
884
+ };
885
+ l.parseExportSpecifiers = function(e) {
886
+ var t = [], i = !0;
887
+ for (this.expect(a.braceL); !this.eat(a.braceR); ) {
888
+ if (i)
889
+ i = !1;
890
+ else if (this.expect(a.comma), this.afterTrailingComma(a.braceR))
891
+ break;
892
+ t.push(this.parseExportSpecifier(e));
893
+ }
894
+ return t;
895
+ };
896
+ l.parseImport = function(e) {
897
+ return this.next(), this.type === a.string ? (e.specifiers = At, e.source = this.parseExprAtom()) : (e.specifiers = this.parseImportSpecifiers(), this.expectContextual("from"), e.source = this.type === a.string ? this.parseExprAtom() : this.unexpected()), this.options.ecmaVersion >= 16 && (e.attributes = this.parseWithClause()), this.semicolon(), this.finishNode(e, "ImportDeclaration");
898
+ };
899
+ l.parseImportSpecifier = function() {
900
+ var e = this.startNode();
901
+ return e.imported = this.parseModuleExportName(), this.eatContextual("as") ? e.local = this.parseIdent() : (this.checkUnreserved(e.imported), e.local = e.imported), this.checkLValSimple(e.local, B), this.finishNode(e, "ImportSpecifier");
902
+ };
903
+ l.parseImportDefaultSpecifier = function() {
904
+ var e = this.startNode();
905
+ return e.local = this.parseIdent(), this.checkLValSimple(e.local, B), this.finishNode(e, "ImportDefaultSpecifier");
906
+ };
907
+ l.parseImportNamespaceSpecifier = function() {
908
+ var e = this.startNode();
909
+ return this.next(), this.expectContextual("as"), e.local = this.parseIdent(), this.checkLValSimple(e.local, B), this.finishNode(e, "ImportNamespaceSpecifier");
910
+ };
911
+ l.parseImportSpecifiers = function() {
912
+ var e = [], t = !0;
913
+ if (this.type === a.name && (e.push(this.parseImportDefaultSpecifier()), !this.eat(a.comma)))
914
+ return e;
915
+ if (this.type === a.star)
916
+ return e.push(this.parseImportNamespaceSpecifier()), e;
917
+ for (this.expect(a.braceL); !this.eat(a.braceR); ) {
918
+ if (t)
919
+ t = !1;
920
+ else if (this.expect(a.comma), this.afterTrailingComma(a.braceR))
921
+ break;
922
+ e.push(this.parseImportSpecifier());
923
+ }
924
+ return e;
925
+ };
926
+ l.parseWithClause = function() {
927
+ var e = [];
928
+ if (!this.eat(a._with))
929
+ return e;
930
+ this.expect(a.braceL);
931
+ for (var t = {}, i = !0; !this.eat(a.braceR); ) {
932
+ if (i)
933
+ i = !1;
934
+ else if (this.expect(a.comma), this.afterTrailingComma(a.braceR))
935
+ break;
936
+ var s = this.parseImportAttribute(), r = s.key.type === "Identifier" ? s.key.name : s.key.value;
937
+ K(t, r) && this.raiseRecoverable(s.key.start, "Duplicate attribute key '" + r + "'"), t[r] = !0, e.push(s);
938
+ }
939
+ return e;
940
+ };
941
+ l.parseImportAttribute = function() {
942
+ var e = this.startNode();
943
+ return e.key = this.type === a.string ? this.parseExprAtom() : this.parseIdent(this.options.allowReserved !== "never"), this.expect(a.colon), this.type !== a.string && this.unexpected(), e.value = this.parseExprAtom(), this.finishNode(e, "ImportAttribute");
944
+ };
945
+ l.parseModuleExportName = function() {
946
+ if (this.options.ecmaVersion >= 13 && this.type === a.string) {
947
+ var e = this.parseLiteral(this.value);
948
+ return _t.test(e.value) && this.raise(e.start, "An export name cannot include a lone surrogate."), e;
949
+ }
950
+ return this.parseIdent(!0);
951
+ };
952
+ l.adaptDirectivePrologue = function(e) {
953
+ for (var t = 0; t < e.length && this.isDirectiveCandidate(e[t]); ++t)
954
+ e[t].directive = e[t].expression.raw.slice(1, -1);
955
+ };
956
+ l.isDirectiveCandidate = function(e) {
957
+ return this.options.ecmaVersion >= 5 && e.type === "ExpressionStatement" && e.expression.type === "Literal" && typeof e.expression.value == "string" && // Reject parenthesized strings.
958
+ (this.input[e.start] === '"' || this.input[e.start] === "'");
959
+ };
960
+ var N = y.prototype;
961
+ N.toAssignable = function(e, t, i) {
962
+ if (this.options.ecmaVersion >= 6 && e)
963
+ switch (e.type) {
964
+ case "Identifier":
965
+ this.inAsync && e.name === "await" && this.raise(e.start, "Cannot use 'await' as identifier inside an async function");
966
+ break;
967
+ case "ObjectPattern":
968
+ case "ArrayPattern":
969
+ case "AssignmentPattern":
970
+ case "RestElement":
971
+ break;
972
+ case "ObjectExpression":
973
+ e.type = "ObjectPattern", i && this.checkPatternErrors(i, !0);
974
+ for (var s = 0, r = e.properties; s < r.length; s += 1) {
975
+ var n = r[s];
976
+ this.toAssignable(n, t), n.type === "RestElement" && (n.argument.type === "ArrayPattern" || n.argument.type === "ObjectPattern") && this.raise(n.argument.start, "Unexpected token");
977
+ }
978
+ break;
979
+ case "Property":
980
+ e.kind !== "init" && this.raise(e.key.start, "Object pattern can't contain getter or setter"), this.toAssignable(e.value, t);
981
+ break;
982
+ case "ArrayExpression":
983
+ e.type = "ArrayPattern", i && this.checkPatternErrors(i, !0), this.toAssignableList(e.elements, t);
984
+ break;
985
+ case "SpreadElement":
986
+ e.type = "RestElement", this.toAssignable(e.argument, t), e.argument.type === "AssignmentPattern" && this.raise(e.argument.start, "Rest elements cannot have a default value");
987
+ break;
988
+ case "AssignmentExpression":
989
+ e.operator !== "=" && this.raise(e.left.end, "Only '=' operator can be used for specifying default value."), e.type = "AssignmentPattern", delete e.operator, this.toAssignable(e.left, t);
990
+ break;
991
+ case "ParenthesizedExpression":
992
+ this.toAssignable(e.expression, t, i);
993
+ break;
994
+ case "ChainExpression":
995
+ this.raiseRecoverable(e.start, "Optional chaining cannot appear in left-hand side");
996
+ break;
997
+ case "MemberExpression":
998
+ if (!t)
999
+ break;
1000
+ default:
1001
+ this.raise(e.start, "Assigning to rvalue");
1002
+ }
1003
+ else i && this.checkPatternErrors(i, !0);
1004
+ return e;
1005
+ };
1006
+ N.toAssignableList = function(e, t) {
1007
+ for (var i = e.length, s = 0; s < i; s++) {
1008
+ var r = e[s];
1009
+ r && this.toAssignable(r, t);
1010
+ }
1011
+ if (i) {
1012
+ var n = e[i - 1];
1013
+ this.options.ecmaVersion === 6 && t && n && n.type === "RestElement" && n.argument.type !== "Identifier" && this.unexpected(n.argument.start);
1014
+ }
1015
+ return e;
1016
+ };
1017
+ N.parseSpread = function(e) {
1018
+ var t = this.startNode();
1019
+ return this.next(), t.argument = this.parseMaybeAssign(!1, e), this.finishNode(t, "SpreadElement");
1020
+ };
1021
+ N.parseRestBinding = function() {
1022
+ var e = this.startNode();
1023
+ return this.next(), this.options.ecmaVersion === 6 && this.type !== a.name && this.unexpected(), e.argument = this.parseBindingAtom(), this.finishNode(e, "RestElement");
1024
+ };
1025
+ N.parseBindingAtom = function() {
1026
+ if (this.options.ecmaVersion >= 6)
1027
+ switch (this.type) {
1028
+ case a.bracketL:
1029
+ var e = this.startNode();
1030
+ return this.next(), e.elements = this.parseBindingList(a.bracketR, !0, !0), this.finishNode(e, "ArrayPattern");
1031
+ case a.braceL:
1032
+ return this.parseObj(!0);
1033
+ }
1034
+ return this.parseIdent();
1035
+ };
1036
+ N.parseBindingList = function(e, t, i, s) {
1037
+ for (var r = [], n = !0; !this.eat(e); )
1038
+ if (n ? n = !1 : this.expect(a.comma), t && this.type === a.comma)
1039
+ r.push(null);
1040
+ else {
1041
+ if (i && this.afterTrailingComma(e))
1042
+ break;
1043
+ if (this.type === a.ellipsis) {
1044
+ var u = this.parseRestBinding();
1045
+ this.parseBindingListItem(u), r.push(u), this.type === a.comma && this.raiseRecoverable(this.start, "Comma is not permitted after the rest element"), this.expect(e);
1046
+ break;
1047
+ } else
1048
+ r.push(this.parseAssignableListItem(s));
1049
+ }
1050
+ return r;
1051
+ };
1052
+ N.parseAssignableListItem = function(e) {
1053
+ var t = this.parseMaybeDefault(this.start, this.startLoc);
1054
+ return this.parseBindingListItem(t), t;
1055
+ };
1056
+ N.parseBindingListItem = function(e) {
1057
+ return e;
1058
+ };
1059
+ N.parseMaybeDefault = function(e, t, i) {
1060
+ if (i = i || this.parseBindingAtom(), this.options.ecmaVersion < 6 || !this.eat(a.eq))
1061
+ return i;
1062
+ var s = this.startNodeAt(e, t);
1063
+ return s.left = i, s.right = this.parseMaybeAssign(), this.finishNode(s, "AssignmentPattern");
1064
+ };
1065
+ N.checkLValSimple = function(e, t, i) {
1066
+ t === void 0 && (t = te);
1067
+ var s = t !== te;
1068
+ switch (e.type) {
1069
+ case "Identifier":
1070
+ this.strict && this.reservedWordsStrictBind.test(e.name) && this.raiseRecoverable(e.start, (s ? "Binding " : "Assigning to ") + e.name + " in strict mode"), s && (t === B && e.name === "let" && this.raiseRecoverable(e.start, "let is disallowed as a lexically bound name"), i && (K(i, e.name) && this.raiseRecoverable(e.start, "Argument name clash"), i[e.name] = !0), t !== Ge && this.declareName(e.name, t, e.start));
1071
+ break;
1072
+ case "ChainExpression":
1073
+ this.raiseRecoverable(e.start, "Optional chaining cannot appear in left-hand side");
1074
+ break;
1075
+ case "MemberExpression":
1076
+ s && this.raiseRecoverable(e.start, "Binding member expression");
1077
+ break;
1078
+ case "ParenthesizedExpression":
1079
+ return s && this.raiseRecoverable(e.start, "Binding parenthesized expression"), this.checkLValSimple(e.expression, t, i);
1080
+ default:
1081
+ this.raise(e.start, (s ? "Binding" : "Assigning to") + " rvalue");
1082
+ }
1083
+ };
1084
+ N.checkLValPattern = function(e, t, i) {
1085
+ switch (t === void 0 && (t = te), e.type) {
1086
+ case "ObjectPattern":
1087
+ for (var s = 0, r = e.properties; s < r.length; s += 1) {
1088
+ var n = r[s];
1089
+ this.checkLValInnerPattern(n, t, i);
1090
+ }
1091
+ break;
1092
+ case "ArrayPattern":
1093
+ for (var u = 0, o = e.elements; u < o.length; u += 1) {
1094
+ var h = o[u];
1095
+ h && this.checkLValInnerPattern(h, t, i);
1096
+ }
1097
+ break;
1098
+ default:
1099
+ this.checkLValSimple(e, t, i);
1100
+ }
1101
+ };
1102
+ N.checkLValInnerPattern = function(e, t, i) {
1103
+ switch (t === void 0 && (t = te), e.type) {
1104
+ case "Property":
1105
+ this.checkLValInnerPattern(e.value, t, i);
1106
+ break;
1107
+ case "AssignmentPattern":
1108
+ this.checkLValPattern(e.left, t, i);
1109
+ break;
1110
+ case "RestElement":
1111
+ this.checkLValPattern(e.argument, t, i);
1112
+ break;
1113
+ default:
1114
+ this.checkLValPattern(e, t, i);
1115
+ }
1116
+ };
1117
+ var V = function(t, i, s, r, n) {
1118
+ this.token = t, this.isExpr = !!i, this.preserveSpace = !!s, this.override = r, this.generator = !!n;
1119
+ }, b = {
1120
+ b_stat: new V("{", !1),
1121
+ b_expr: new V("{", !0),
1122
+ b_tmpl: new V("${", !1),
1123
+ p_stat: new V("(", !1),
1124
+ p_expr: new V("(", !0),
1125
+ q_tmpl: new V("`", !0, !0, function(e) {
1126
+ return e.tryReadTemplateToken();
1127
+ }),
1128
+ f_stat: new V("function", !1),
1129
+ f_expr: new V("function", !0),
1130
+ f_expr_gen: new V("function", !0, !1, null, !0),
1131
+ f_gen: new V("function", !1, !1, null, !0)
1132
+ }, Q = y.prototype;
1133
+ Q.initialContext = function() {
1134
+ return [b.b_stat];
1135
+ };
1136
+ Q.curContext = function() {
1137
+ return this.context[this.context.length - 1];
1138
+ };
1139
+ Q.braceIsBlock = function(e) {
1140
+ var t = this.curContext();
1141
+ return t === b.f_expr || t === b.f_stat ? !0 : e === a.colon && (t === b.b_stat || t === b.b_expr) ? !t.isExpr : e === a._return || e === a.name && this.exprAllowed ? w.test(this.input.slice(this.lastTokEnd, this.start)) : e === a._else || e === a.semi || e === a.eof || e === a.parenR || e === a.arrow ? !0 : e === a.braceL ? t === b.b_stat : e === a._var || e === a._const || e === a.name ? !1 : !this.exprAllowed;
1142
+ };
1143
+ Q.inGeneratorContext = function() {
1144
+ for (var e = this.context.length - 1; e >= 1; e--) {
1145
+ var t = this.context[e];
1146
+ if (t.token === "function")
1147
+ return t.generator;
1148
+ }
1149
+ return !1;
1150
+ };
1151
+ Q.updateContext = function(e) {
1152
+ var t, i = this.type;
1153
+ i.keyword && e === a.dot ? this.exprAllowed = !1 : (t = i.updateContext) ? t.call(this, e) : this.exprAllowed = i.beforeExpr;
1154
+ };
1155
+ Q.overrideContext = function(e) {
1156
+ this.curContext() !== e && (this.context[this.context.length - 1] = e);
1157
+ };
1158
+ a.parenR.updateContext = a.braceR.updateContext = function() {
1159
+ if (this.context.length === 1) {
1160
+ this.exprAllowed = !0;
1161
+ return;
1162
+ }
1163
+ var e = this.context.pop();
1164
+ e === b.b_stat && this.curContext().token === "function" && (e = this.context.pop()), this.exprAllowed = !e.isExpr;
1165
+ };
1166
+ a.braceL.updateContext = function(e) {
1167
+ this.context.push(this.braceIsBlock(e) ? b.b_stat : b.b_expr), this.exprAllowed = !0;
1168
+ };
1169
+ a.dollarBraceL.updateContext = function() {
1170
+ this.context.push(b.b_tmpl), this.exprAllowed = !0;
1171
+ };
1172
+ a.parenL.updateContext = function(e) {
1173
+ var t = e === a._if || e === a._for || e === a._with || e === a._while;
1174
+ this.context.push(t ? b.p_stat : b.p_expr), this.exprAllowed = !0;
1175
+ };
1176
+ a.incDec.updateContext = function() {
1177
+ };
1178
+ a._function.updateContext = a._class.updateContext = function(e) {
1179
+ e.beforeExpr && e !== a._else && !(e === a.semi && this.curContext() !== b.p_stat) && !(e === a._return && w.test(this.input.slice(this.lastTokEnd, this.start))) && !((e === a.colon || e === a.braceL) && this.curContext() === b.b_stat) ? this.context.push(b.f_expr) : this.context.push(b.f_stat), this.exprAllowed = !1;
1180
+ };
1181
+ a.colon.updateContext = function() {
1182
+ this.curContext().token === "function" && this.context.pop(), this.exprAllowed = !0;
1183
+ };
1184
+ a.backQuote.updateContext = function() {
1185
+ this.curContext() === b.q_tmpl ? this.context.pop() : this.context.push(b.q_tmpl), this.exprAllowed = !1;
1186
+ };
1187
+ a.star.updateContext = function(e) {
1188
+ if (e === a._function) {
1189
+ var t = this.context.length - 1;
1190
+ this.context[t] === b.f_expr ? this.context[t] = b.f_expr_gen : this.context[t] = b.f_gen;
1191
+ }
1192
+ this.exprAllowed = !0;
1193
+ };
1194
+ a.name.updateContext = function(e) {
1195
+ var t = !1;
1196
+ this.options.ecmaVersion >= 6 && e !== a.dot && (this.value === "of" && !this.exprAllowed || this.value === "yield" && this.inGeneratorContext()) && (t = !0), this.exprAllowed = t;
1197
+ };
1198
+ var f = y.prototype;
1199
+ f.checkPropClash = function(e, t, i) {
1200
+ if (!(this.options.ecmaVersion >= 9 && e.type === "SpreadElement") && !(this.options.ecmaVersion >= 6 && (e.computed || e.method || e.shorthand))) {
1201
+ var s = e.key, r;
1202
+ switch (s.type) {
1203
+ case "Identifier":
1204
+ r = s.name;
1205
+ break;
1206
+ case "Literal":
1207
+ r = String(s.value);
1208
+ break;
1209
+ default:
1210
+ return;
1211
+ }
1212
+ var n = e.kind;
1213
+ if (this.options.ecmaVersion >= 6) {
1214
+ r === "__proto__" && n === "init" && (t.proto && (i ? i.doubleProto < 0 && (i.doubleProto = s.start) : this.raiseRecoverable(s.start, "Redefinition of __proto__ property")), t.proto = !0);
1215
+ return;
1216
+ }
1217
+ r = "$" + r;
1218
+ var u = t[r];
1219
+ if (u) {
1220
+ var o;
1221
+ n === "init" ? o = this.strict && u.init || u.get || u.set : o = u.init || u[n], o && this.raiseRecoverable(s.start, "Redefinition of property");
1222
+ } else
1223
+ u = t[r] = {
1224
+ init: !1,
1225
+ get: !1,
1226
+ set: !1
1227
+ };
1228
+ u[n] = !0;
1229
+ }
1230
+ };
1231
+ f.parseExpression = function(e, t) {
1232
+ var i = this.start, s = this.startLoc, r = this.parseMaybeAssign(e, t);
1233
+ if (this.type === a.comma) {
1234
+ var n = this.startNodeAt(i, s);
1235
+ for (n.expressions = [r]; this.eat(a.comma); )
1236
+ n.expressions.push(this.parseMaybeAssign(e, t));
1237
+ return this.finishNode(n, "SequenceExpression");
1238
+ }
1239
+ return r;
1240
+ };
1241
+ f.parseMaybeAssign = function(e, t, i) {
1242
+ if (this.isContextual("yield")) {
1243
+ if (this.inGenerator)
1244
+ return this.parseYield(e);
1245
+ this.exprAllowed = !1;
1246
+ }
1247
+ var s = !1, r = -1, n = -1, u = -1;
1248
+ t ? (r = t.parenthesizedAssign, n = t.trailingComma, u = t.doubleProto, t.parenthesizedAssign = t.trailingComma = -1) : (t = new oe(), s = !0);
1249
+ var o = this.start, h = this.startLoc;
1250
+ (this.type === a.parenL || this.type === a.name) && (this.potentialArrowAt = this.start, this.potentialArrowInForAwait = e === "await");
1251
+ var p = this.parseMaybeConditional(e, t);
1252
+ if (i && (p = i.call(this, p, o, h)), this.type.isAssign) {
1253
+ var d = this.startNodeAt(o, h);
1254
+ return d.operator = this.value, this.type === a.eq && (p = this.toAssignable(p, !1, t)), s || (t.parenthesizedAssign = t.trailingComma = t.doubleProto = -1), t.shorthandAssign >= p.start && (t.shorthandAssign = -1), this.type === a.eq ? this.checkLValPattern(p) : this.checkLValSimple(p), d.left = p, this.next(), d.right = this.parseMaybeAssign(e), u > -1 && (t.doubleProto = u), this.finishNode(d, "AssignmentExpression");
1255
+ } else
1256
+ s && this.checkExpressionErrors(t, !0);
1257
+ return r > -1 && (t.parenthesizedAssign = r), n > -1 && (t.trailingComma = n), p;
1258
+ };
1259
+ f.parseMaybeConditional = function(e, t) {
1260
+ var i = this.start, s = this.startLoc, r = this.parseExprOps(e, t);
1261
+ if (this.checkExpressionErrors(t))
1262
+ return r;
1263
+ if (this.eat(a.question)) {
1264
+ var n = this.startNodeAt(i, s);
1265
+ return n.test = r, n.consequent = this.parseMaybeAssign(), this.expect(a.colon), n.alternate = this.parseMaybeAssign(e), this.finishNode(n, "ConditionalExpression");
1266
+ }
1267
+ return r;
1268
+ };
1269
+ f.parseExprOps = function(e, t) {
1270
+ var i = this.start, s = this.startLoc, r = this.parseMaybeUnary(t, !1, !1, e);
1271
+ return this.checkExpressionErrors(t) || r.start === i && r.type === "ArrowFunctionExpression" ? r : this.parseExprOp(r, i, s, -1, e);
1272
+ };
1273
+ f.parseExprOp = function(e, t, i, s, r) {
1274
+ var n = this.type.binop;
1275
+ if (n != null && (!r || this.type !== a._in) && n > s) {
1276
+ var u = this.type === a.logicalOR || this.type === a.logicalAND, o = this.type === a.coalesce;
1277
+ o && (n = a.logicalAND.binop);
1278
+ var h = this.value;
1279
+ this.next();
1280
+ var p = this.start, d = this.startLoc, g = this.parseExprOp(this.parseMaybeUnary(null, !1, !1, r), p, d, n, r), _ = this.buildBinary(t, i, e, g, h, u || o);
1281
+ return (u && this.type === a.coalesce || o && (this.type === a.logicalOR || this.type === a.logicalAND)) && this.raiseRecoverable(this.start, "Logical expressions and coalesce expressions cannot be mixed. Wrap either by parentheses"), this.parseExprOp(_, t, i, s, r);
1282
+ }
1283
+ return e;
1284
+ };
1285
+ f.buildBinary = function(e, t, i, s, r, n) {
1286
+ s.type === "PrivateIdentifier" && this.raise(s.start, "Private identifier can only be left side of binary expression");
1287
+ var u = this.startNodeAt(e, t);
1288
+ return u.left = i, u.operator = r, u.right = s, this.finishNode(u, n ? "LogicalExpression" : "BinaryExpression");
1289
+ };
1290
+ f.parseMaybeUnary = function(e, t, i, s) {
1291
+ var r = this.start, n = this.startLoc, u;
1292
+ if (this.isContextual("await") && this.canAwait)
1293
+ u = this.parseAwait(s), t = !0;
1294
+ else if (this.type.prefix) {
1295
+ var o = this.startNode(), h = this.type === a.incDec;
1296
+ o.operator = this.value, o.prefix = !0, this.next(), o.argument = this.parseMaybeUnary(null, !0, h, s), this.checkExpressionErrors(e, !0), h ? this.checkLValSimple(o.argument) : this.strict && o.operator === "delete" && We(o.argument) ? this.raiseRecoverable(o.start, "Deleting local variable in strict mode") : o.operator === "delete" && ve(o.argument) ? this.raiseRecoverable(o.start, "Private fields can not be deleted") : t = !0, u = this.finishNode(o, h ? "UpdateExpression" : "UnaryExpression");
1297
+ } else if (!t && this.type === a.privateId)
1298
+ (s || this.privateNameStack.length === 0) && this.options.checkPrivateFields && this.unexpected(), u = this.parsePrivateIdent(), this.type !== a._in && this.unexpected();
1299
+ else {
1300
+ if (u = this.parseExprSubscripts(e, s), this.checkExpressionErrors(e))
1301
+ return u;
1302
+ for (; this.type.postfix && !this.canInsertSemicolon(); ) {
1303
+ var p = this.startNodeAt(r, n);
1304
+ p.operator = this.value, p.prefix = !1, p.argument = u, this.checkLValSimple(u), this.next(), u = this.finishNode(p, "UpdateExpression");
1305
+ }
1306
+ }
1307
+ if (!i && this.eat(a.starstar))
1308
+ if (t)
1309
+ this.unexpected(this.lastTokStart);
1310
+ else
1311
+ return this.buildBinary(r, n, u, this.parseMaybeUnary(null, !1, !1, s), "**", !1);
1312
+ else
1313
+ return u;
1314
+ };
1315
+ function We(e) {
1316
+ return e.type === "Identifier" || e.type === "ParenthesizedExpression" && We(e.expression);
1317
+ }
1318
+ function ve(e) {
1319
+ return e.type === "MemberExpression" && e.property.type === "PrivateIdentifier" || e.type === "ChainExpression" && ve(e.expression) || e.type === "ParenthesizedExpression" && ve(e.expression);
1320
+ }
1321
+ f.parseExprSubscripts = function(e, t) {
1322
+ var i = this.start, s = this.startLoc, r = this.parseExprAtom(e, t);
1323
+ if (r.type === "ArrowFunctionExpression" && this.input.slice(this.lastTokStart, this.lastTokEnd) !== ")")
1324
+ return r;
1325
+ var n = this.parseSubscripts(r, i, s, !1, t);
1326
+ return e && n.type === "MemberExpression" && (e.parenthesizedAssign >= n.start && (e.parenthesizedAssign = -1), e.parenthesizedBind >= n.start && (e.parenthesizedBind = -1), e.trailingComma >= n.start && (e.trailingComma = -1)), n;
1327
+ };
1328
+ f.parseSubscripts = function(e, t, i, s, r) {
1329
+ for (var n = this.options.ecmaVersion >= 8 && e.type === "Identifier" && e.name === "async" && this.lastTokEnd === e.end && !this.canInsertSemicolon() && e.end - e.start === 5 && this.potentialArrowAt === e.start, u = !1; ; ) {
1330
+ var o = this.parseSubscript(e, t, i, s, n, u, r);
1331
+ if (o.optional && (u = !0), o === e || o.type === "ArrowFunctionExpression") {
1332
+ if (u) {
1333
+ var h = this.startNodeAt(t, i);
1334
+ h.expression = o, o = this.finishNode(h, "ChainExpression");
1335
+ }
1336
+ return o;
1337
+ }
1338
+ e = o;
1339
+ }
1340
+ };
1341
+ f.shouldParseAsyncArrow = function() {
1342
+ return !this.canInsertSemicolon() && this.eat(a.arrow);
1343
+ };
1344
+ f.parseSubscriptAsyncArrow = function(e, t, i, s) {
1345
+ return this.parseArrowExpression(this.startNodeAt(e, t), i, !0, s);
1346
+ };
1347
+ f.parseSubscript = function(e, t, i, s, r, n, u) {
1348
+ var o = this.options.ecmaVersion >= 11, h = o && this.eat(a.questionDot);
1349
+ s && h && this.raise(this.lastTokStart, "Optional chaining cannot appear in the callee of new expressions");
1350
+ var p = this.eat(a.bracketL);
1351
+ if (p || h && this.type !== a.parenL && this.type !== a.backQuote || this.eat(a.dot)) {
1352
+ var d = this.startNodeAt(t, i);
1353
+ d.object = e, p ? (d.property = this.parseExpression(), this.expect(a.bracketR)) : this.type === a.privateId && e.type !== "Super" ? d.property = this.parsePrivateIdent() : d.property = this.parseIdent(this.options.allowReserved !== "never"), d.computed = !!p, o && (d.optional = h), e = this.finishNode(d, "MemberExpression");
1354
+ } else if (!s && this.eat(a.parenL)) {
1355
+ var g = new oe(), _ = this.yieldPos, Y = this.awaitPos, G = this.awaitIdentPos;
1356
+ this.yieldPos = 0, this.awaitPos = 0, this.awaitIdentPos = 0;
1357
+ var ee = this.parseExprList(a.parenR, this.options.ecmaVersion >= 8, !1, g);
1358
+ if (r && !h && this.shouldParseAsyncArrow())
1359
+ return this.checkPatternErrors(g, !1), this.checkYieldAwaitInDefaultParams(), this.awaitIdentPos > 0 && this.raise(this.awaitIdentPos, "Cannot use 'await' as identifier inside an async function"), this.yieldPos = _, this.awaitPos = Y, this.awaitIdentPos = G, this.parseSubscriptAsyncArrow(t, i, ee, u);
1360
+ this.checkExpressionErrors(g, !0), this.yieldPos = _ || this.yieldPos, this.awaitPos = Y || this.awaitPos, this.awaitIdentPos = G || this.awaitIdentPos;
1361
+ var H = this.startNodeAt(t, i);
1362
+ H.callee = e, H.arguments = ee, o && (H.optional = h), e = this.finishNode(H, "CallExpression");
1363
+ } else if (this.type === a.backQuote) {
1364
+ (h || n) && this.raise(this.start, "Optional chaining cannot appear in the tag of tagged template expressions");
1365
+ var W = this.startNodeAt(t, i);
1366
+ W.tag = e, W.quasi = this.parseTemplate({ isTagged: !0 }), e = this.finishNode(W, "TaggedTemplateExpression");
1367
+ }
1368
+ return e;
1369
+ };
1370
+ f.parseExprAtom = function(e, t, i) {
1371
+ this.type === a.slash && this.readRegexp();
1372
+ var s, r = this.potentialArrowAt === this.start;
1373
+ switch (this.type) {
1374
+ case a._super:
1375
+ return this.allowSuper || this.raise(this.start, "'super' keyword outside a method"), s = this.startNode(), this.next(), this.type === a.parenL && !this.allowDirectSuper && this.raise(s.start, "super() call outside constructor of a subclass"), this.type !== a.dot && this.type !== a.bracketL && this.type !== a.parenL && this.unexpected(), this.finishNode(s, "Super");
1376
+ case a._this:
1377
+ return s = this.startNode(), this.next(), this.finishNode(s, "ThisExpression");
1378
+ case a.name:
1379
+ var n = this.start, u = this.startLoc, o = this.containsEsc, h = this.parseIdent(!1);
1380
+ if (this.options.ecmaVersion >= 8 && !o && h.name === "async" && !this.canInsertSemicolon() && this.eat(a._function))
1381
+ return this.overrideContext(b.f_expr), this.parseFunction(this.startNodeAt(n, u), 0, !1, !0, t);
1382
+ if (r && !this.canInsertSemicolon()) {
1383
+ if (this.eat(a.arrow))
1384
+ return this.parseArrowExpression(this.startNodeAt(n, u), [h], !1, t);
1385
+ if (this.options.ecmaVersion >= 8 && h.name === "async" && this.type === a.name && !o && (!this.potentialArrowInForAwait || this.value !== "of" || this.containsEsc))
1386
+ return h = this.parseIdent(!1), (this.canInsertSemicolon() || !this.eat(a.arrow)) && this.unexpected(), this.parseArrowExpression(this.startNodeAt(n, u), [h], !0, t);
1387
+ }
1388
+ return h;
1389
+ case a.regexp:
1390
+ var p = this.value;
1391
+ return s = this.parseLiteral(p.value), s.regex = { pattern: p.pattern, flags: p.flags }, s;
1392
+ case a.num:
1393
+ case a.string:
1394
+ return this.parseLiteral(this.value);
1395
+ case a._null:
1396
+ case a._true:
1397
+ case a._false:
1398
+ return s = this.startNode(), s.value = this.type === a._null ? null : this.type === a._true, s.raw = this.type.keyword, this.next(), this.finishNode(s, "Literal");
1399
+ case a.parenL:
1400
+ var d = this.start, g = this.parseParenAndDistinguishExpression(r, t);
1401
+ return e && (e.parenthesizedAssign < 0 && !this.isSimpleAssignTarget(g) && (e.parenthesizedAssign = d), e.parenthesizedBind < 0 && (e.parenthesizedBind = d)), g;
1402
+ case a.bracketL:
1403
+ return s = this.startNode(), this.next(), s.elements = this.parseExprList(a.bracketR, !0, !0, e), this.finishNode(s, "ArrayExpression");
1404
+ case a.braceL:
1405
+ return this.overrideContext(b.b_expr), this.parseObj(!1, e);
1406
+ case a._function:
1407
+ return s = this.startNode(), this.next(), this.parseFunction(s, 0);
1408
+ case a._class:
1409
+ return this.parseClass(this.startNode(), !1);
1410
+ case a._new:
1411
+ return this.parseNew();
1412
+ case a.backQuote:
1413
+ return this.parseTemplate();
1414
+ case a._import:
1415
+ return this.options.ecmaVersion >= 11 ? this.parseExprImport(i) : this.unexpected();
1416
+ default:
1417
+ return this.parseExprAtomDefault();
1418
+ }
1419
+ };
1420
+ f.parseExprAtomDefault = function() {
1421
+ this.unexpected();
1422
+ };
1423
+ f.parseExprImport = function(e) {
1424
+ var t = this.startNode();
1425
+ if (this.containsEsc && this.raiseRecoverable(this.start, "Escape sequence in keyword import"), this.next(), this.type === a.parenL && !e)
1426
+ return this.parseDynamicImport(t);
1427
+ if (this.type === a.dot) {
1428
+ var i = this.startNodeAt(t.start, t.loc && t.loc.start);
1429
+ return i.name = "import", t.meta = this.finishNode(i, "Identifier"), this.parseImportMeta(t);
1430
+ } else
1431
+ this.unexpected();
1432
+ };
1433
+ f.parseDynamicImport = function(e) {
1434
+ if (this.next(), e.source = this.parseMaybeAssign(), this.options.ecmaVersion >= 16)
1435
+ this.eat(a.parenR) ? e.options = null : (this.expect(a.comma), this.afterTrailingComma(a.parenR) ? e.options = null : (e.options = this.parseMaybeAssign(), this.eat(a.parenR) || (this.expect(a.comma), this.afterTrailingComma(a.parenR) || this.unexpected())));
1436
+ else if (!this.eat(a.parenR)) {
1437
+ var t = this.start;
1438
+ this.eat(a.comma) && this.eat(a.parenR) ? this.raiseRecoverable(t, "Trailing comma is not allowed in import()") : this.unexpected(t);
1439
+ }
1440
+ return this.finishNode(e, "ImportExpression");
1441
+ };
1442
+ f.parseImportMeta = function(e) {
1443
+ this.next();
1444
+ var t = this.containsEsc;
1445
+ return e.property = this.parseIdent(!0), e.property.name !== "meta" && this.raiseRecoverable(e.property.start, "The only valid meta property for import is 'import.meta'"), t && this.raiseRecoverable(e.start, "'import.meta' must not contain escaped characters"), this.options.sourceType !== "module" && !this.options.allowImportExportEverywhere && this.raiseRecoverable(e.start, "Cannot use 'import.meta' outside a module"), this.finishNode(e, "MetaProperty");
1446
+ };
1447
+ f.parseLiteral = function(e) {
1448
+ var t = this.startNode();
1449
+ return t.value = e, t.raw = this.input.slice(this.start, this.end), t.raw.charCodeAt(t.raw.length - 1) === 110 && (t.bigint = t.value != null ? t.value.toString() : t.raw.slice(0, -1).replace(/_/g, "")), this.next(), this.finishNode(t, "Literal");
1450
+ };
1451
+ f.parseParenExpression = function() {
1452
+ this.expect(a.parenL);
1453
+ var e = this.parseExpression();
1454
+ return this.expect(a.parenR), e;
1455
+ };
1456
+ f.shouldParseArrow = function(e) {
1457
+ return !this.canInsertSemicolon();
1458
+ };
1459
+ f.parseParenAndDistinguishExpression = function(e, t) {
1460
+ var i = this.start, s = this.startLoc, r, n = this.options.ecmaVersion >= 8;
1461
+ if (this.options.ecmaVersion >= 6) {
1462
+ this.next();
1463
+ var u = this.start, o = this.startLoc, h = [], p = !0, d = !1, g = new oe(), _ = this.yieldPos, Y = this.awaitPos, G;
1464
+ for (this.yieldPos = 0, this.awaitPos = 0; this.type !== a.parenR; )
1465
+ if (p ? p = !1 : this.expect(a.comma), n && this.afterTrailingComma(a.parenR, !0)) {
1466
+ d = !0;
1467
+ break;
1468
+ } else if (this.type === a.ellipsis) {
1469
+ G = this.start, h.push(this.parseParenItem(this.parseRestBinding())), this.type === a.comma && this.raiseRecoverable(
1470
+ this.start,
1471
+ "Comma is not permitted after the rest element"
1472
+ );
1473
+ break;
1474
+ } else
1475
+ h.push(this.parseMaybeAssign(!1, g, this.parseParenItem));
1476
+ var ee = this.lastTokEnd, H = this.lastTokEndLoc;
1477
+ if (this.expect(a.parenR), e && this.shouldParseArrow(h) && this.eat(a.arrow))
1478
+ return this.checkPatternErrors(g, !1), this.checkYieldAwaitInDefaultParams(), this.yieldPos = _, this.awaitPos = Y, this.parseParenArrowList(i, s, h, t);
1479
+ (!h.length || d) && this.unexpected(this.lastTokStart), G && this.unexpected(G), this.checkExpressionErrors(g, !0), this.yieldPos = _ || this.yieldPos, this.awaitPos = Y || this.awaitPos, h.length > 1 ? (r = this.startNodeAt(u, o), r.expressions = h, this.finishNodeAt(r, "SequenceExpression", ee, H)) : r = h[0];
1480
+ } else
1481
+ r = this.parseParenExpression();
1482
+ if (this.options.preserveParens) {
1483
+ var W = this.startNodeAt(i, s);
1484
+ return W.expression = r, this.finishNode(W, "ParenthesizedExpression");
1485
+ } else
1486
+ return r;
1487
+ };
1488
+ f.parseParenItem = function(e) {
1489
+ return e;
1490
+ };
1491
+ f.parseParenArrowList = function(e, t, i, s) {
1492
+ return this.parseArrowExpression(this.startNodeAt(e, t), i, !1, s);
1493
+ };
1494
+ var It = [];
1495
+ f.parseNew = function() {
1496
+ this.containsEsc && this.raiseRecoverable(this.start, "Escape sequence in keyword new");
1497
+ var e = this.startNode();
1498
+ if (this.next(), this.options.ecmaVersion >= 6 && this.type === a.dot) {
1499
+ var t = this.startNodeAt(e.start, e.loc && e.loc.start);
1500
+ t.name = "new", e.meta = this.finishNode(t, "Identifier"), this.next();
1501
+ var i = this.containsEsc;
1502
+ return e.property = this.parseIdent(!0), e.property.name !== "target" && this.raiseRecoverable(e.property.start, "The only valid meta property for new is 'new.target'"), i && this.raiseRecoverable(e.start, "'new.target' must not contain escaped characters"), this.allowNewDotTarget || this.raiseRecoverable(e.start, "'new.target' can only be used in functions and class static block"), this.finishNode(e, "MetaProperty");
1503
+ }
1504
+ var s = this.start, r = this.startLoc;
1505
+ return e.callee = this.parseSubscripts(this.parseExprAtom(null, !1, !0), s, r, !0, !1), this.eat(a.parenL) ? e.arguments = this.parseExprList(a.parenR, this.options.ecmaVersion >= 8, !1) : e.arguments = It, this.finishNode(e, "NewExpression");
1506
+ };
1507
+ f.parseTemplateElement = function(e) {
1508
+ var t = e.isTagged, i = this.startNode();
1509
+ return this.type === a.invalidTemplate ? (t || this.raiseRecoverable(this.start, "Bad escape sequence in untagged template literal"), i.value = {
1510
+ raw: this.value.replace(/\r\n?/g, `
1511
+ `),
1512
+ cooked: null
1513
+ }) : i.value = {
1514
+ raw: this.input.slice(this.start, this.end).replace(/\r\n?/g, `
1515
+ `),
1516
+ cooked: this.value
1517
+ }, this.next(), i.tail = this.type === a.backQuote, this.finishNode(i, "TemplateElement");
1518
+ };
1519
+ f.parseTemplate = function(e) {
1520
+ e === void 0 && (e = {});
1521
+ var t = e.isTagged;
1522
+ t === void 0 && (t = !1);
1523
+ var i = this.startNode();
1524
+ this.next(), i.expressions = [];
1525
+ var s = this.parseTemplateElement({ isTagged: t });
1526
+ for (i.quasis = [s]; !s.tail; )
1527
+ this.type === a.eof && this.raise(this.pos, "Unterminated template literal"), this.expect(a.dollarBraceL), i.expressions.push(this.parseExpression()), this.expect(a.braceR), i.quasis.push(s = this.parseTemplateElement({ isTagged: t }));
1528
+ return this.next(), this.finishNode(i, "TemplateLiteral");
1529
+ };
1530
+ f.isAsyncProp = function(e) {
1531
+ return !e.computed && e.key.type === "Identifier" && e.key.name === "async" && (this.type === a.name || this.type === a.num || this.type === a.string || this.type === a.bracketL || this.type.keyword || this.options.ecmaVersion >= 9 && this.type === a.star) && !w.test(this.input.slice(this.lastTokEnd, this.start));
1532
+ };
1533
+ f.parseObj = function(e, t) {
1534
+ var i = this.startNode(), s = !0, r = {};
1535
+ for (i.properties = [], this.next(); !this.eat(a.braceR); ) {
1536
+ if (s)
1537
+ s = !1;
1538
+ else if (this.expect(a.comma), this.options.ecmaVersion >= 5 && this.afterTrailingComma(a.braceR))
1539
+ break;
1540
+ var n = this.parseProperty(e, t);
1541
+ e || this.checkPropClash(n, r, t), i.properties.push(n);
1542
+ }
1543
+ return this.finishNode(i, e ? "ObjectPattern" : "ObjectExpression");
1544
+ };
1545
+ f.parseProperty = function(e, t) {
1546
+ var i = this.startNode(), s, r, n, u;
1547
+ if (this.options.ecmaVersion >= 9 && this.eat(a.ellipsis))
1548
+ return e ? (i.argument = this.parseIdent(!1), this.type === a.comma && this.raiseRecoverable(this.start, "Comma is not permitted after the rest element"), this.finishNode(i, "RestElement")) : (i.argument = this.parseMaybeAssign(!1, t), this.type === a.comma && t && t.trailingComma < 0 && (t.trailingComma = this.start), this.finishNode(i, "SpreadElement"));
1549
+ this.options.ecmaVersion >= 6 && (i.method = !1, i.shorthand = !1, (e || t) && (n = this.start, u = this.startLoc), e || (s = this.eat(a.star)));
1550
+ var o = this.containsEsc;
1551
+ return this.parsePropertyName(i), !e && !o && this.options.ecmaVersion >= 8 && !s && this.isAsyncProp(i) ? (r = !0, s = this.options.ecmaVersion >= 9 && this.eat(a.star), this.parsePropertyName(i)) : r = !1, this.parsePropertyValue(i, e, s, r, n, u, t, o), this.finishNode(i, "Property");
1552
+ };
1553
+ f.parseGetterSetter = function(e) {
1554
+ var t = e.key.name;
1555
+ this.parsePropertyName(e), e.value = this.parseMethod(!1), e.kind = t;
1556
+ var i = e.kind === "get" ? 0 : 1;
1557
+ if (e.value.params.length !== i) {
1558
+ var s = e.value.start;
1559
+ e.kind === "get" ? this.raiseRecoverable(s, "getter should have no params") : this.raiseRecoverable(s, "setter should have exactly one param");
1560
+ } else
1561
+ e.kind === "set" && e.value.params[0].type === "RestElement" && this.raiseRecoverable(e.value.params[0].start, "Setter cannot use rest params");
1562
+ };
1563
+ f.parsePropertyValue = function(e, t, i, s, r, n, u, o) {
1564
+ (i || s) && this.type === a.colon && this.unexpected(), this.eat(a.colon) ? (e.value = t ? this.parseMaybeDefault(this.start, this.startLoc) : this.parseMaybeAssign(!1, u), e.kind = "init") : this.options.ecmaVersion >= 6 && this.type === a.parenL ? (t && this.unexpected(), e.method = !0, e.value = this.parseMethod(i, s), e.kind = "init") : !t && !o && this.options.ecmaVersion >= 5 && !e.computed && e.key.type === "Identifier" && (e.key.name === "get" || e.key.name === "set") && this.type !== a.comma && this.type !== a.braceR && this.type !== a.eq ? ((i || s) && this.unexpected(), this.parseGetterSetter(e)) : this.options.ecmaVersion >= 6 && !e.computed && e.key.type === "Identifier" ? ((i || s) && this.unexpected(), this.checkUnreserved(e.key), e.key.name === "await" && !this.awaitIdentPos && (this.awaitIdentPos = r), t ? e.value = this.parseMaybeDefault(r, n, this.copyNode(e.key)) : this.type === a.eq && u ? (u.shorthandAssign < 0 && (u.shorthandAssign = this.start), e.value = this.parseMaybeDefault(r, n, this.copyNode(e.key))) : e.value = this.copyNode(e.key), e.kind = "init", e.shorthand = !0) : this.unexpected();
1565
+ };
1566
+ f.parsePropertyName = function(e) {
1567
+ if (this.options.ecmaVersion >= 6) {
1568
+ if (this.eat(a.bracketL))
1569
+ return e.computed = !0, e.key = this.parseMaybeAssign(), this.expect(a.bracketR), e.key;
1570
+ e.computed = !1;
1571
+ }
1572
+ return e.key = this.type === a.num || this.type === a.string ? this.parseExprAtom() : this.parseIdent(this.options.allowReserved !== "never");
1573
+ };
1574
+ f.initFunction = function(e) {
1575
+ e.id = null, this.options.ecmaVersion >= 6 && (e.generator = e.expression = !1), this.options.ecmaVersion >= 8 && (e.async = !1);
1576
+ };
1577
+ f.parseMethod = function(e, t, i) {
1578
+ var s = this.startNode(), r = this.yieldPos, n = this.awaitPos, u = this.awaitIdentPos;
1579
+ return this.initFunction(s), this.options.ecmaVersion >= 6 && (s.generator = e), this.options.ecmaVersion >= 8 && (s.async = !!t), this.yieldPos = 0, this.awaitPos = 0, this.awaitIdentPos = 0, this.enterScope(_e(t, s.generator) | ne | (i ? Me : 0)), this.expect(a.parenL), s.params = this.parseBindingList(a.parenR, !1, this.options.ecmaVersion >= 8), this.checkYieldAwaitInDefaultParams(), this.parseFunctionBody(s, !1, !0, !1), this.yieldPos = r, this.awaitPos = n, this.awaitIdentPos = u, this.finishNode(s, "FunctionExpression");
1580
+ };
1581
+ f.parseArrowExpression = function(e, t, i, s) {
1582
+ var r = this.yieldPos, n = this.awaitPos, u = this.awaitIdentPos;
1583
+ return this.enterScope(_e(i, !1) | ye), this.initFunction(e), this.options.ecmaVersion >= 8 && (e.async = !!i), this.yieldPos = 0, this.awaitPos = 0, this.awaitIdentPos = 0, e.params = this.toAssignableList(t, !0), this.parseFunctionBody(e, !0, !1, s), this.yieldPos = r, this.awaitPos = n, this.awaitIdentPos = u, this.finishNode(e, "ArrowFunctionExpression");
1584
+ };
1585
+ f.parseFunctionBody = function(e, t, i, s) {
1586
+ var r = t && this.type !== a.braceL, n = this.strict, u = !1;
1587
+ if (r)
1588
+ e.body = this.parseMaybeAssign(s), e.expression = !0, this.checkParams(e, !1);
1589
+ else {
1590
+ var o = this.options.ecmaVersion >= 7 && !this.isSimpleParamList(e.params);
1591
+ (!n || o) && (u = this.strictDirective(this.end), u && o && this.raiseRecoverable(e.start, "Illegal 'use strict' directive in function with non-simple parameter list"));
1592
+ var h = this.labels;
1593
+ this.labels = [], u && (this.strict = !0), this.checkParams(e, !n && !u && !t && !i && this.isSimpleParamList(e.params)), this.strict && e.id && this.checkLValSimple(e.id, Ge), e.body = this.parseBlock(!1, void 0, u && !n), e.expression = !1, this.adaptDirectivePrologue(e.body.body), this.labels = h;
1594
+ }
1595
+ this.exitScope();
1596
+ };
1597
+ f.isSimpleParamList = function(e) {
1598
+ for (var t = 0, i = e; t < i.length; t += 1) {
1599
+ var s = i[t];
1600
+ if (s.type !== "Identifier")
1601
+ return !1;
1602
+ }
1603
+ return !0;
1604
+ };
1605
+ f.checkParams = function(e, t) {
1606
+ for (var i = /* @__PURE__ */ Object.create(null), s = 0, r = e.params; s < r.length; s += 1) {
1607
+ var n = r[s];
1608
+ this.checkLValInnerPattern(n, Ce, t ? null : i);
1609
+ }
1610
+ };
1611
+ f.parseExprList = function(e, t, i, s) {
1612
+ for (var r = [], n = !0; !this.eat(e); ) {
1613
+ if (n)
1614
+ n = !1;
1615
+ else if (this.expect(a.comma), t && this.afterTrailingComma(e))
1616
+ break;
1617
+ var u = void 0;
1618
+ i && this.type === a.comma ? u = null : this.type === a.ellipsis ? (u = this.parseSpread(s), s && this.type === a.comma && s.trailingComma < 0 && (s.trailingComma = this.start)) : u = this.parseMaybeAssign(!1, s), r.push(u);
1619
+ }
1620
+ return r;
1621
+ };
1622
+ f.checkUnreserved = function(e) {
1623
+ var t = e.start, i = e.end, s = e.name;
1624
+ if (this.inGenerator && s === "yield" && this.raiseRecoverable(t, "Cannot use 'yield' as identifier inside a generator"), this.inAsync && s === "await" && this.raiseRecoverable(t, "Cannot use 'await' as identifier inside an async function"), !(this.currentThisScope().flags & ue) && s === "arguments" && this.raiseRecoverable(t, "Cannot use 'arguments' in class field initializer"), this.inClassStaticBlock && (s === "arguments" || s === "await") && this.raise(t, "Cannot use " + s + " in class static initialization block"), this.keywords.test(s) && this.raise(t, "Unexpected keyword '" + s + "'"), !(this.options.ecmaVersion < 6 && this.input.slice(t, i).indexOf("\\") !== -1)) {
1625
+ var r = this.strict ? this.reservedWordsStrict : this.reservedWords;
1626
+ r.test(s) && (!this.inAsync && s === "await" && this.raiseRecoverable(t, "Cannot use keyword 'await' outside an async function"), this.raiseRecoverable(t, "The keyword '" + s + "' is reserved"));
1627
+ }
1628
+ };
1629
+ f.parseIdent = function(e) {
1630
+ var t = this.parseIdentNode();
1631
+ return this.next(!!e), this.finishNode(t, "Identifier"), e || (this.checkUnreserved(t), t.name === "await" && !this.awaitIdentPos && (this.awaitIdentPos = t.start)), t;
1632
+ };
1633
+ f.parseIdentNode = function() {
1634
+ var e = this.startNode();
1635
+ return this.type === a.name ? e.name = this.value : this.type.keyword ? (e.name = this.type.keyword, (e.name === "class" || e.name === "function") && (this.lastTokEnd !== this.lastTokStart + 1 || this.input.charCodeAt(this.lastTokStart) !== 46) && this.context.pop(), this.type = a.name) : this.unexpected(), e;
1636
+ };
1637
+ f.parsePrivateIdent = function() {
1638
+ var e = this.startNode();
1639
+ return this.type === a.privateId ? e.name = this.value : this.unexpected(), this.next(), this.finishNode(e, "PrivateIdentifier"), this.options.checkPrivateFields && (this.privateNameStack.length === 0 ? this.raise(e.start, "Private field '#" + e.name + "' must be declared in an enclosing class") : this.privateNameStack[this.privateNameStack.length - 1].used.push(e)), e;
1640
+ };
1641
+ f.parseYield = function(e) {
1642
+ this.yieldPos || (this.yieldPos = this.start);
1643
+ var t = this.startNode();
1644
+ return this.next(), this.type === a.semi || this.canInsertSemicolon() || this.type !== a.star && !this.type.startsExpr ? (t.delegate = !1, t.argument = null) : (t.delegate = this.eat(a.star), t.argument = this.parseMaybeAssign(e)), this.finishNode(t, "YieldExpression");
1645
+ };
1646
+ f.parseAwait = function(e) {
1647
+ this.awaitPos || (this.awaitPos = this.start);
1648
+ var t = this.startNode();
1649
+ return this.next(), t.argument = this.parseMaybeUnary(null, !0, !1, e), this.finishNode(t, "AwaitExpression");
1650
+ };
1651
+ var se = y.prototype;
1652
+ se.raise = function(e, t) {
1653
+ var i = Be(this.input, e);
1654
+ t += " (" + i.line + ":" + i.column + ")", this.sourceFile && (t += " in " + this.sourceFile);
1655
+ var s = new SyntaxError(t);
1656
+ throw s.pos = e, s.loc = i, s.raisedAt = this.pos, s;
1657
+ };
1658
+ se.raiseRecoverable = se.raise;
1659
+ se.curPosition = function() {
1660
+ if (this.options.locations)
1661
+ return new Z(this.curLine, this.pos - this.lineStart);
1662
+ };
1663
+ var M = y.prototype, Pt = function(t) {
1664
+ this.flags = t, this.var = [], this.lexical = [], this.functions = [];
1665
+ };
1666
+ M.enterScope = function(e) {
1667
+ this.scopeStack.push(new Pt(e));
1668
+ };
1669
+ M.exitScope = function() {
1670
+ this.scopeStack.pop();
1671
+ };
1672
+ M.treatFunctionsAsVarInScope = function(e) {
1673
+ return e.flags & q || !this.inModule && e.flags & U;
1674
+ };
1675
+ M.declareName = function(e, t, i) {
1676
+ var s = !1;
1677
+ if (t === B) {
1678
+ var r = this.currentScope();
1679
+ s = r.lexical.indexOf(e) > -1 || r.functions.indexOf(e) > -1 || r.var.indexOf(e) > -1, r.lexical.push(e), this.inModule && r.flags & U && delete this.undefinedExports[e];
1680
+ } else if (t === je) {
1681
+ var n = this.currentScope();
1682
+ n.lexical.push(e);
1683
+ } else if (t === qe) {
1684
+ var u = this.currentScope();
1685
+ this.treatFunctionsAsVar ? s = u.lexical.indexOf(e) > -1 : s = u.lexical.indexOf(e) > -1 || u.var.indexOf(e) > -1, u.functions.push(e);
1686
+ } else
1687
+ for (var o = this.scopeStack.length - 1; o >= 0; --o) {
1688
+ var h = this.scopeStack[o];
1689
+ if (h.lexical.indexOf(e) > -1 && !(h.flags & Fe && h.lexical[0] === e) || !this.treatFunctionsAsVarInScope(h) && h.functions.indexOf(e) > -1) {
1690
+ s = !0;
1691
+ break;
1692
+ }
1693
+ if (h.var.push(e), this.inModule && h.flags & U && delete this.undefinedExports[e], h.flags & ue)
1694
+ break;
1695
+ }
1696
+ s && this.raiseRecoverable(i, "Identifier '" + e + "' has already been declared");
1697
+ };
1698
+ M.checkLocalExport = function(e) {
1699
+ this.scopeStack[0].lexical.indexOf(e.name) === -1 && this.scopeStack[0].var.indexOf(e.name) === -1 && (this.undefinedExports[e.name] = e);
1700
+ };
1701
+ M.currentScope = function() {
1702
+ return this.scopeStack[this.scopeStack.length - 1];
1703
+ };
1704
+ M.currentVarScope = function() {
1705
+ for (var e = this.scopeStack.length - 1; ; e--) {
1706
+ var t = this.scopeStack[e];
1707
+ if (t.flags & (ue | J | j))
1708
+ return t;
1709
+ }
1710
+ };
1711
+ M.currentThisScope = function() {
1712
+ for (var e = this.scopeStack.length - 1; ; e--) {
1713
+ var t = this.scopeStack[e];
1714
+ if (t.flags & (ue | J | j) && !(t.flags & ye))
1715
+ return t;
1716
+ }
1717
+ };
1718
+ var he = function(t, i, s) {
1719
+ this.type = "", this.start = i, this.end = 0, t.options.locations && (this.loc = new re(t, s)), t.options.directSourceFile && (this.sourceFile = t.options.directSourceFile), t.options.ranges && (this.range = [i, 0]);
1720
+ }, $ = y.prototype;
1721
+ $.startNode = function() {
1722
+ return new he(this, this.start, this.startLoc);
1723
+ };
1724
+ $.startNodeAt = function(e, t) {
1725
+ return new he(this, e, t);
1726
+ };
1727
+ function ze(e, t, i, s) {
1728
+ return e.type = t, e.end = i, this.options.locations && (e.loc.end = s), this.options.ranges && (e.range[1] = i), e;
1729
+ }
1730
+ $.finishNode = function(e, t) {
1731
+ return ze.call(this, e, t, this.lastTokEnd, this.lastTokEndLoc);
1732
+ };
1733
+ $.finishNodeAt = function(e, t, i, s) {
1734
+ return ze.call(this, e, t, i, s);
1735
+ };
1736
+ $.copyNode = function(e) {
1737
+ var t = new he(this, e.start, this.startLoc);
1738
+ for (var i in e)
1739
+ t[i] = e[i];
1740
+ return t;
1741
+ };
1742
+ var Nt = "Berf Beria_Erfe Gara Garay Gukh Gurung_Khema Hrkt Katakana_Or_Hiragana Kawi Kirat_Rai Krai Nag_Mundari Nagm Ol_Onal Onao Sidetic Sidt Sunu Sunuwar Tai_Yo Tayo Todhri Todr Tolong_Siki Tols Tulu_Tigalari Tutg Unknown Zzzz", Ke = "ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS", Qe = Ke + " Extended_Pictographic", Ye = Qe, Xe = Ye + " EBase EComp EMod EPres ExtPict", Ze = Xe, Vt = Ze, Tt = {
1743
+ 9: Ke,
1744
+ 10: Qe,
1745
+ 11: Ye,
1746
+ 12: Xe,
1747
+ 13: Ze,
1748
+ 14: Vt
1749
+ }, Lt = "Basic_Emoji Emoji_Keycap_Sequence RGI_Emoji_Modifier_Sequence RGI_Emoji_Flag_Sequence RGI_Emoji_Tag_Sequence RGI_Emoji_ZWJ_Sequence RGI_Emoji", Rt = {
1750
+ 9: "",
1751
+ 10: "",
1752
+ 11: "",
1753
+ 12: "",
1754
+ 13: "",
1755
+ 14: Lt
1756
+ }, Ie = "Cased_Letter LC Close_Punctuation Pe Connector_Punctuation Pc Control Cc cntrl Currency_Symbol Sc Dash_Punctuation Pd Decimal_Number Nd digit Enclosing_Mark Me Final_Punctuation Pf Format Cf Initial_Punctuation Pi Letter L Letter_Number Nl Line_Separator Zl Lowercase_Letter Ll Mark M Combining_Mark Math_Symbol Sm Modifier_Letter Lm Modifier_Symbol Sk Nonspacing_Mark Mn Number N Open_Punctuation Ps Other C Other_Letter Lo Other_Number No Other_Punctuation Po Other_Symbol So Paragraph_Separator Zp Private_Use Co Punctuation P punct Separator Z Space_Separator Zs Spacing_Mark Mc Surrogate Cs Symbol S Titlecase_Letter Lt Unassigned Cn Uppercase_Letter Lu", Je = "Adlam Adlm Ahom Anatolian_Hieroglyphs Hluw Arabic Arab Armenian Armn Avestan Avst Balinese Bali Bamum Bamu Bassa_Vah Bass Batak Batk Bengali Beng Bhaiksuki Bhks Bopomofo Bopo Brahmi Brah Braille Brai Buginese Bugi Buhid Buhd Canadian_Aboriginal Cans Carian Cari Caucasian_Albanian Aghb Chakma Cakm Cham Cham Cherokee Cher Common Zyyy Coptic Copt Qaac Cuneiform Xsux Cypriot Cprt Cyrillic Cyrl Deseret Dsrt Devanagari Deva Duployan Dupl Egyptian_Hieroglyphs Egyp Elbasan Elba Ethiopic Ethi Georgian Geor Glagolitic Glag Gothic Goth Grantha Gran Greek Grek Gujarati Gujr Gurmukhi Guru Han Hani Hangul Hang Hanunoo Hano Hatran Hatr Hebrew Hebr Hiragana Hira Imperial_Aramaic Armi Inherited Zinh Qaai Inscriptional_Pahlavi Phli Inscriptional_Parthian Prti Javanese Java Kaithi Kthi Kannada Knda Katakana Kana Kayah_Li Kali Kharoshthi Khar Khmer Khmr Khojki Khoj Khudawadi Sind Lao Laoo Latin Latn Lepcha Lepc Limbu Limb Linear_A Lina Linear_B Linb Lisu Lisu Lycian Lyci Lydian Lydi Mahajani Mahj Malayalam Mlym Mandaic Mand Manichaean Mani Marchen Marc Masaram_Gondi Gonm Meetei_Mayek Mtei Mende_Kikakui Mend Meroitic_Cursive Merc Meroitic_Hieroglyphs Mero Miao Plrd Modi Mongolian Mong Mro Mroo Multani Mult Myanmar Mymr Nabataean Nbat New_Tai_Lue Talu Newa Newa Nko Nkoo Nushu Nshu Ogham Ogam Ol_Chiki Olck Old_Hungarian Hung Old_Italic Ital Old_North_Arabian Narb Old_Permic Perm Old_Persian Xpeo Old_South_Arabian Sarb Old_Turkic Orkh Oriya Orya Osage Osge Osmanya Osma Pahawh_Hmong Hmng Palmyrene Palm Pau_Cin_Hau Pauc Phags_Pa Phag Phoenician Phnx Psalter_Pahlavi Phlp Rejang Rjng Runic Runr Samaritan Samr Saurashtra Saur Sharada Shrd Shavian Shaw Siddham Sidd SignWriting Sgnw Sinhala Sinh Sora_Sompeng Sora Soyombo Soyo Sundanese Sund Syloti_Nagri Sylo Syriac Syrc Tagalog Tglg Tagbanwa Tagb Tai_Le Tale Tai_Tham Lana Tai_Viet Tavt Takri Takr Tamil Taml Tangut Tang Telugu Telu Thaana Thaa Thai Thai Tibetan Tibt Tifinagh Tfng Tirhuta Tirh Ugaritic Ugar Vai Vaii Warang_Citi Wara Yi Yiii Zanabazar_Square Zanb", $e = Je + " Dogra Dogr Gunjala_Gondi Gong Hanifi_Rohingya Rohg Makasar Maka Medefaidrin Medf Old_Sogdian Sogo Sogdian Sogd", et = $e + " Elymaic Elym Nandinagari Nand Nyiakeng_Puachue_Hmong Hmnp Wancho Wcho", tt = et + " Chorasmian Chrs Diak Dives_Akuru Khitan_Small_Script Kits Yezi Yezidi", it = tt + " Cypro_Minoan Cpmn Old_Uyghur Ougr Tangsa Tnsa Toto Vithkuqi Vith", Ot = it + " " + Nt, Bt = {
1757
+ 9: Je,
1758
+ 10: $e,
1759
+ 11: et,
1760
+ 12: tt,
1761
+ 13: it,
1762
+ 14: Ot
1763
+ }, st = {};
1764
+ function Dt(e) {
1765
+ var t = st[e] = {
1766
+ binary: D(Tt[e] + " " + Ie),
1767
+ binaryOfStrings: D(Rt[e]),
1768
+ nonBinary: {
1769
+ General_Category: D(Ie),
1770
+ Script: D(Bt[e])
1771
+ }
1772
+ };
1773
+ t.nonBinary.Script_Extensions = t.nonBinary.Script, t.nonBinary.gc = t.nonBinary.General_Category, t.nonBinary.sc = t.nonBinary.Script, t.nonBinary.scx = t.nonBinary.Script_Extensions;
1774
+ }
1775
+ for (var fe = 0, Pe = [9, 10, 11, 12, 13, 14]; fe < Pe.length; fe += 1) {
1776
+ var Ft = Pe[fe];
1777
+ Dt(Ft);
1778
+ }
1779
+ var c = y.prototype, ae = function(t, i) {
1780
+ this.parent = t, this.base = i || this;
1781
+ };
1782
+ ae.prototype.separatedFrom = function(t) {
1783
+ for (var i = this; i; i = i.parent)
1784
+ for (var s = t; s; s = s.parent)
1785
+ if (i.base === s.base && i !== s)
1786
+ return !0;
1787
+ return !1;
1788
+ };
1789
+ ae.prototype.sibling = function() {
1790
+ return new ae(this.parent, this.base);
1791
+ };
1792
+ var L = function(t) {
1793
+ this.parser = t, this.validFlags = "gim" + (t.options.ecmaVersion >= 6 ? "uy" : "") + (t.options.ecmaVersion >= 9 ? "s" : "") + (t.options.ecmaVersion >= 13 ? "d" : "") + (t.options.ecmaVersion >= 15 ? "v" : ""), this.unicodeProperties = st[t.options.ecmaVersion >= 14 ? 14 : t.options.ecmaVersion], this.source = "", this.flags = "", this.start = 0, this.switchU = !1, this.switchV = !1, this.switchN = !1, this.pos = 0, this.lastIntValue = 0, this.lastStringValue = "", this.lastAssertionIsQuantifiable = !1, this.numCapturingParens = 0, this.maxBackReference = 0, this.groupNames = /* @__PURE__ */ Object.create(null), this.backReferenceNames = [], this.branchID = null;
1794
+ };
1795
+ L.prototype.reset = function(t, i, s) {
1796
+ var r = s.indexOf("v") !== -1, n = s.indexOf("u") !== -1;
1797
+ this.start = t | 0, this.source = i + "", this.flags = s, r && this.parser.options.ecmaVersion >= 15 ? (this.switchU = !0, this.switchV = !0, this.switchN = !0) : (this.switchU = n && this.parser.options.ecmaVersion >= 6, this.switchV = !1, this.switchN = n && this.parser.options.ecmaVersion >= 9);
1798
+ };
1799
+ L.prototype.raise = function(t) {
1800
+ this.parser.raiseRecoverable(this.start, "Invalid regular expression: /" + this.source + "/: " + t);
1801
+ };
1802
+ L.prototype.at = function(t, i) {
1803
+ i === void 0 && (i = !1);
1804
+ var s = this.source, r = s.length;
1805
+ if (t >= r)
1806
+ return -1;
1807
+ var n = s.charCodeAt(t);
1808
+ if (!(i || this.switchU) || n <= 55295 || n >= 57344 || t + 1 >= r)
1809
+ return n;
1810
+ var u = s.charCodeAt(t + 1);
1811
+ return u >= 56320 && u <= 57343 ? (n << 10) + u - 56613888 : n;
1812
+ };
1813
+ L.prototype.nextIndex = function(t, i) {
1814
+ i === void 0 && (i = !1);
1815
+ var s = this.source, r = s.length;
1816
+ if (t >= r)
1817
+ return r;
1818
+ var n = s.charCodeAt(t), u;
1819
+ return !(i || this.switchU) || n <= 55295 || n >= 57344 || t + 1 >= r || (u = s.charCodeAt(t + 1)) < 56320 || u > 57343 ? t + 1 : t + 2;
1820
+ };
1821
+ L.prototype.current = function(t) {
1822
+ return t === void 0 && (t = !1), this.at(this.pos, t);
1823
+ };
1824
+ L.prototype.lookahead = function(t) {
1825
+ return t === void 0 && (t = !1), this.at(this.nextIndex(this.pos, t), t);
1826
+ };
1827
+ L.prototype.advance = function(t) {
1828
+ t === void 0 && (t = !1), this.pos = this.nextIndex(this.pos, t);
1829
+ };
1830
+ L.prototype.eat = function(t, i) {
1831
+ return i === void 0 && (i = !1), this.current(i) === t ? (this.advance(i), !0) : !1;
1832
+ };
1833
+ L.prototype.eatChars = function(t, i) {
1834
+ i === void 0 && (i = !1);
1835
+ for (var s = this.pos, r = 0, n = t; r < n.length; r += 1) {
1836
+ var u = n[r], o = this.at(s, i);
1837
+ if (o === -1 || o !== u)
1838
+ return !1;
1839
+ s = this.nextIndex(s, i);
1840
+ }
1841
+ return this.pos = s, !0;
1842
+ };
1843
+ c.validateRegExpFlags = function(e) {
1844
+ for (var t = e.validFlags, i = e.flags, s = !1, r = !1, n = 0; n < i.length; n++) {
1845
+ var u = i.charAt(n);
1846
+ t.indexOf(u) === -1 && this.raise(e.start, "Invalid regular expression flag"), i.indexOf(u, n + 1) > -1 && this.raise(e.start, "Duplicate regular expression flag"), u === "u" && (s = !0), u === "v" && (r = !0);
1847
+ }
1848
+ this.options.ecmaVersion >= 15 && s && r && this.raise(e.start, "Invalid regular expression flag");
1849
+ };
1850
+ function Mt(e) {
1851
+ for (var t in e)
1852
+ return !0;
1853
+ return !1;
1854
+ }
1855
+ c.validateRegExpPattern = function(e) {
1856
+ this.regexp_pattern(e), !e.switchN && this.options.ecmaVersion >= 9 && Mt(e.groupNames) && (e.switchN = !0, this.regexp_pattern(e));
1857
+ };
1858
+ c.regexp_pattern = function(e) {
1859
+ e.pos = 0, e.lastIntValue = 0, e.lastStringValue = "", e.lastAssertionIsQuantifiable = !1, e.numCapturingParens = 0, e.maxBackReference = 0, e.groupNames = /* @__PURE__ */ Object.create(null), e.backReferenceNames.length = 0, e.branchID = null, this.regexp_disjunction(e), e.pos !== e.source.length && (e.eat(
1860
+ 41
1861
+ /* ) */
1862
+ ) && e.raise("Unmatched ')'"), (e.eat(
1863
+ 93
1864
+ /* ] */
1865
+ ) || e.eat(
1866
+ 125
1867
+ /* } */
1868
+ )) && e.raise("Lone quantifier brackets")), e.maxBackReference > e.numCapturingParens && e.raise("Invalid escape");
1869
+ for (var t = 0, i = e.backReferenceNames; t < i.length; t += 1) {
1870
+ var s = i[t];
1871
+ e.groupNames[s] || e.raise("Invalid named capture referenced");
1872
+ }
1873
+ };
1874
+ c.regexp_disjunction = function(e) {
1875
+ var t = this.options.ecmaVersion >= 16;
1876
+ for (t && (e.branchID = new ae(e.branchID, null)), this.regexp_alternative(e); e.eat(
1877
+ 124
1878
+ /* | */
1879
+ ); )
1880
+ t && (e.branchID = e.branchID.sibling()), this.regexp_alternative(e);
1881
+ t && (e.branchID = e.branchID.parent), this.regexp_eatQuantifier(e, !0) && e.raise("Nothing to repeat"), e.eat(
1882
+ 123
1883
+ /* { */
1884
+ ) && e.raise("Lone quantifier brackets");
1885
+ };
1886
+ c.regexp_alternative = function(e) {
1887
+ for (; e.pos < e.source.length && this.regexp_eatTerm(e); )
1888
+ ;
1889
+ };
1890
+ c.regexp_eatTerm = function(e) {
1891
+ return this.regexp_eatAssertion(e) ? (e.lastAssertionIsQuantifiable && this.regexp_eatQuantifier(e) && e.switchU && e.raise("Invalid quantifier"), !0) : (e.switchU ? this.regexp_eatAtom(e) : this.regexp_eatExtendedAtom(e)) ? (this.regexp_eatQuantifier(e), !0) : !1;
1892
+ };
1893
+ c.regexp_eatAssertion = function(e) {
1894
+ var t = e.pos;
1895
+ if (e.lastAssertionIsQuantifiable = !1, e.eat(
1896
+ 94
1897
+ /* ^ */
1898
+ ) || e.eat(
1899
+ 36
1900
+ /* $ */
1901
+ ))
1902
+ return !0;
1903
+ if (e.eat(
1904
+ 92
1905
+ /* \ */
1906
+ )) {
1907
+ if (e.eat(
1908
+ 66
1909
+ /* B */
1910
+ ) || e.eat(
1911
+ 98
1912
+ /* b */
1913
+ ))
1914
+ return !0;
1915
+ e.pos = t;
1916
+ }
1917
+ if (e.eat(
1918
+ 40
1919
+ /* ( */
1920
+ ) && e.eat(
1921
+ 63
1922
+ /* ? */
1923
+ )) {
1924
+ var i = !1;
1925
+ if (this.options.ecmaVersion >= 9 && (i = e.eat(
1926
+ 60
1927
+ /* < */
1928
+ )), e.eat(
1929
+ 61
1930
+ /* = */
1931
+ ) || e.eat(
1932
+ 33
1933
+ /* ! */
1934
+ ))
1935
+ return this.regexp_disjunction(e), e.eat(
1936
+ 41
1937
+ /* ) */
1938
+ ) || e.raise("Unterminated group"), e.lastAssertionIsQuantifiable = !i, !0;
1939
+ }
1940
+ return e.pos = t, !1;
1941
+ };
1942
+ c.regexp_eatQuantifier = function(e, t) {
1943
+ return t === void 0 && (t = !1), this.regexp_eatQuantifierPrefix(e, t) ? (e.eat(
1944
+ 63
1945
+ /* ? */
1946
+ ), !0) : !1;
1947
+ };
1948
+ c.regexp_eatQuantifierPrefix = function(e, t) {
1949
+ return e.eat(
1950
+ 42
1951
+ /* * */
1952
+ ) || e.eat(
1953
+ 43
1954
+ /* + */
1955
+ ) || e.eat(
1956
+ 63
1957
+ /* ? */
1958
+ ) || this.regexp_eatBracedQuantifier(e, t);
1959
+ };
1960
+ c.regexp_eatBracedQuantifier = function(e, t) {
1961
+ var i = e.pos;
1962
+ if (e.eat(
1963
+ 123
1964
+ /* { */
1965
+ )) {
1966
+ var s = 0, r = -1;
1967
+ if (this.regexp_eatDecimalDigits(e) && (s = e.lastIntValue, e.eat(
1968
+ 44
1969
+ /* , */
1970
+ ) && this.regexp_eatDecimalDigits(e) && (r = e.lastIntValue), e.eat(
1971
+ 125
1972
+ /* } */
1973
+ )))
1974
+ return r !== -1 && r < s && !t && e.raise("numbers out of order in {} quantifier"), !0;
1975
+ e.switchU && !t && e.raise("Incomplete quantifier"), e.pos = i;
1976
+ }
1977
+ return !1;
1978
+ };
1979
+ c.regexp_eatAtom = function(e) {
1980
+ return this.regexp_eatPatternCharacters(e) || e.eat(
1981
+ 46
1982
+ /* . */
1983
+ ) || this.regexp_eatReverseSolidusAtomEscape(e) || this.regexp_eatCharacterClass(e) || this.regexp_eatUncapturingGroup(e) || this.regexp_eatCapturingGroup(e);
1984
+ };
1985
+ c.regexp_eatReverseSolidusAtomEscape = function(e) {
1986
+ var t = e.pos;
1987
+ if (e.eat(
1988
+ 92
1989
+ /* \ */
1990
+ )) {
1991
+ if (this.regexp_eatAtomEscape(e))
1992
+ return !0;
1993
+ e.pos = t;
1994
+ }
1995
+ return !1;
1996
+ };
1997
+ c.regexp_eatUncapturingGroup = function(e) {
1998
+ var t = e.pos;
1999
+ if (e.eat(
2000
+ 40
2001
+ /* ( */
2002
+ )) {
2003
+ if (e.eat(
2004
+ 63
2005
+ /* ? */
2006
+ )) {
2007
+ if (this.options.ecmaVersion >= 16) {
2008
+ var i = this.regexp_eatModifiers(e), s = e.eat(
2009
+ 45
2010
+ /* - */
2011
+ );
2012
+ if (i || s) {
2013
+ for (var r = 0; r < i.length; r++) {
2014
+ var n = i.charAt(r);
2015
+ i.indexOf(n, r + 1) > -1 && e.raise("Duplicate regular expression modifiers");
2016
+ }
2017
+ if (s) {
2018
+ var u = this.regexp_eatModifiers(e);
2019
+ !i && !u && e.current() === 58 && e.raise("Invalid regular expression modifiers");
2020
+ for (var o = 0; o < u.length; o++) {
2021
+ var h = u.charAt(o);
2022
+ (u.indexOf(h, o + 1) > -1 || i.indexOf(h) > -1) && e.raise("Duplicate regular expression modifiers");
2023
+ }
2024
+ }
2025
+ }
2026
+ }
2027
+ if (e.eat(
2028
+ 58
2029
+ /* : */
2030
+ )) {
2031
+ if (this.regexp_disjunction(e), e.eat(
2032
+ 41
2033
+ /* ) */
2034
+ ))
2035
+ return !0;
2036
+ e.raise("Unterminated group");
2037
+ }
2038
+ }
2039
+ e.pos = t;
2040
+ }
2041
+ return !1;
2042
+ };
2043
+ c.regexp_eatCapturingGroup = function(e) {
2044
+ if (e.eat(
2045
+ 40
2046
+ /* ( */
2047
+ )) {
2048
+ if (this.options.ecmaVersion >= 9 ? this.regexp_groupSpecifier(e) : e.current() === 63 && e.raise("Invalid group"), this.regexp_disjunction(e), e.eat(
2049
+ 41
2050
+ /* ) */
2051
+ ))
2052
+ return e.numCapturingParens += 1, !0;
2053
+ e.raise("Unterminated group");
2054
+ }
2055
+ return !1;
2056
+ };
2057
+ c.regexp_eatModifiers = function(e) {
2058
+ for (var t = "", i = 0; (i = e.current()) !== -1 && Ut(i); )
2059
+ t += R(i), e.advance();
2060
+ return t;
2061
+ };
2062
+ function Ut(e) {
2063
+ return e === 105 || e === 109 || e === 115;
2064
+ }
2065
+ c.regexp_eatExtendedAtom = function(e) {
2066
+ return e.eat(
2067
+ 46
2068
+ /* . */
2069
+ ) || this.regexp_eatReverseSolidusAtomEscape(e) || this.regexp_eatCharacterClass(e) || this.regexp_eatUncapturingGroup(e) || this.regexp_eatCapturingGroup(e) || this.regexp_eatInvalidBracedQuantifier(e) || this.regexp_eatExtendedPatternCharacter(e);
2070
+ };
2071
+ c.regexp_eatInvalidBracedQuantifier = function(e) {
2072
+ return this.regexp_eatBracedQuantifier(e, !0) && e.raise("Nothing to repeat"), !1;
2073
+ };
2074
+ c.regexp_eatSyntaxCharacter = function(e) {
2075
+ var t = e.current();
2076
+ return at(t) ? (e.lastIntValue = t, e.advance(), !0) : !1;
2077
+ };
2078
+ function at(e) {
2079
+ return e === 36 || e >= 40 && e <= 43 || e === 46 || e === 63 || e >= 91 && e <= 94 || e >= 123 && e <= 125;
2080
+ }
2081
+ c.regexp_eatPatternCharacters = function(e) {
2082
+ for (var t = e.pos, i = 0; (i = e.current()) !== -1 && !at(i); )
2083
+ e.advance();
2084
+ return e.pos !== t;
2085
+ };
2086
+ c.regexp_eatExtendedPatternCharacter = function(e) {
2087
+ var t = e.current();
2088
+ return t !== -1 && t !== 36 && !(t >= 40 && t <= 43) && t !== 46 && t !== 63 && t !== 91 && t !== 94 && t !== 124 ? (e.advance(), !0) : !1;
2089
+ };
2090
+ c.regexp_groupSpecifier = function(e) {
2091
+ if (e.eat(
2092
+ 63
2093
+ /* ? */
2094
+ )) {
2095
+ this.regexp_eatGroupName(e) || e.raise("Invalid group");
2096
+ var t = this.options.ecmaVersion >= 16, i = e.groupNames[e.lastStringValue];
2097
+ if (i)
2098
+ if (t)
2099
+ for (var s = 0, r = i; s < r.length; s += 1) {
2100
+ var n = r[s];
2101
+ n.separatedFrom(e.branchID) || e.raise("Duplicate capture group name");
2102
+ }
2103
+ else
2104
+ e.raise("Duplicate capture group name");
2105
+ t ? (i || (e.groupNames[e.lastStringValue] = [])).push(e.branchID) : e.groupNames[e.lastStringValue] = !0;
2106
+ }
2107
+ };
2108
+ c.regexp_eatGroupName = function(e) {
2109
+ if (e.lastStringValue = "", e.eat(
2110
+ 60
2111
+ /* < */
2112
+ )) {
2113
+ if (this.regexp_eatRegExpIdentifierName(e) && e.eat(
2114
+ 62
2115
+ /* > */
2116
+ ))
2117
+ return !0;
2118
+ e.raise("Invalid capture group name");
2119
+ }
2120
+ return !1;
2121
+ };
2122
+ c.regexp_eatRegExpIdentifierName = function(e) {
2123
+ if (e.lastStringValue = "", this.regexp_eatRegExpIdentifierStart(e)) {
2124
+ for (e.lastStringValue += R(e.lastIntValue); this.regexp_eatRegExpIdentifierPart(e); )
2125
+ e.lastStringValue += R(e.lastIntValue);
2126
+ return !0;
2127
+ }
2128
+ return !1;
2129
+ };
2130
+ c.regexp_eatRegExpIdentifierStart = function(e) {
2131
+ var t = e.pos, i = this.options.ecmaVersion >= 11, s = e.current(i);
2132
+ return e.advance(i), s === 92 && this.regexp_eatRegExpUnicodeEscapeSequence(e, i) && (s = e.lastIntValue), qt(s) ? (e.lastIntValue = s, !0) : (e.pos = t, !1);
2133
+ };
2134
+ function qt(e) {
2135
+ return T(e, !0) || e === 36 || e === 95;
2136
+ }
2137
+ c.regexp_eatRegExpIdentifierPart = function(e) {
2138
+ var t = e.pos, i = this.options.ecmaVersion >= 11, s = e.current(i);
2139
+ return e.advance(i), s === 92 && this.regexp_eatRegExpUnicodeEscapeSequence(e, i) && (s = e.lastIntValue), jt(s) ? (e.lastIntValue = s, !0) : (e.pos = t, !1);
2140
+ };
2141
+ function jt(e) {
2142
+ return F(e, !0) || e === 36 || e === 95 || e === 8204 || e === 8205;
2143
+ }
2144
+ c.regexp_eatAtomEscape = function(e) {
2145
+ return this.regexp_eatBackReference(e) || this.regexp_eatCharacterClassEscape(e) || this.regexp_eatCharacterEscape(e) || e.switchN && this.regexp_eatKGroupName(e) ? !0 : (e.switchU && (e.current() === 99 && e.raise("Invalid unicode escape"), e.raise("Invalid escape")), !1);
2146
+ };
2147
+ c.regexp_eatBackReference = function(e) {
2148
+ var t = e.pos;
2149
+ if (this.regexp_eatDecimalEscape(e)) {
2150
+ var i = e.lastIntValue;
2151
+ if (e.switchU)
2152
+ return i > e.maxBackReference && (e.maxBackReference = i), !0;
2153
+ if (i <= e.numCapturingParens)
2154
+ return !0;
2155
+ e.pos = t;
2156
+ }
2157
+ return !1;
2158
+ };
2159
+ c.regexp_eatKGroupName = function(e) {
2160
+ if (e.eat(
2161
+ 107
2162
+ /* k */
2163
+ )) {
2164
+ if (this.regexp_eatGroupName(e))
2165
+ return e.backReferenceNames.push(e.lastStringValue), !0;
2166
+ e.raise("Invalid named reference");
2167
+ }
2168
+ return !1;
2169
+ };
2170
+ c.regexp_eatCharacterEscape = function(e) {
2171
+ return this.regexp_eatControlEscape(e) || this.regexp_eatCControlLetter(e) || this.regexp_eatZero(e) || this.regexp_eatHexEscapeSequence(e) || this.regexp_eatRegExpUnicodeEscapeSequence(e, !1) || !e.switchU && this.regexp_eatLegacyOctalEscapeSequence(e) || this.regexp_eatIdentityEscape(e);
2172
+ };
2173
+ c.regexp_eatCControlLetter = function(e) {
2174
+ var t = e.pos;
2175
+ if (e.eat(
2176
+ 99
2177
+ /* c */
2178
+ )) {
2179
+ if (this.regexp_eatControlLetter(e))
2180
+ return !0;
2181
+ e.pos = t;
2182
+ }
2183
+ return !1;
2184
+ };
2185
+ c.regexp_eatZero = function(e) {
2186
+ return e.current() === 48 && !ce(e.lookahead()) ? (e.lastIntValue = 0, e.advance(), !0) : !1;
2187
+ };
2188
+ c.regexp_eatControlEscape = function(e) {
2189
+ var t = e.current();
2190
+ return t === 116 ? (e.lastIntValue = 9, e.advance(), !0) : t === 110 ? (e.lastIntValue = 10, e.advance(), !0) : t === 118 ? (e.lastIntValue = 11, e.advance(), !0) : t === 102 ? (e.lastIntValue = 12, e.advance(), !0) : t === 114 ? (e.lastIntValue = 13, e.advance(), !0) : !1;
2191
+ };
2192
+ c.regexp_eatControlLetter = function(e) {
2193
+ var t = e.current();
2194
+ return rt(t) ? (e.lastIntValue = t % 32, e.advance(), !0) : !1;
2195
+ };
2196
+ function rt(e) {
2197
+ return e >= 65 && e <= 90 || e >= 97 && e <= 122;
2198
+ }
2199
+ c.regexp_eatRegExpUnicodeEscapeSequence = function(e, t) {
2200
+ t === void 0 && (t = !1);
2201
+ var i = e.pos, s = t || e.switchU;
2202
+ if (e.eat(
2203
+ 117
2204
+ /* u */
2205
+ )) {
2206
+ if (this.regexp_eatFixedHexDigits(e, 4)) {
2207
+ var r = e.lastIntValue;
2208
+ if (s && r >= 55296 && r <= 56319) {
2209
+ var n = e.pos;
2210
+ if (e.eat(
2211
+ 92
2212
+ /* \ */
2213
+ ) && e.eat(
2214
+ 117
2215
+ /* u */
2216
+ ) && this.regexp_eatFixedHexDigits(e, 4)) {
2217
+ var u = e.lastIntValue;
2218
+ if (u >= 56320 && u <= 57343)
2219
+ return e.lastIntValue = (r - 55296) * 1024 + (u - 56320) + 65536, !0;
2220
+ }
2221
+ e.pos = n, e.lastIntValue = r;
2222
+ }
2223
+ return !0;
2224
+ }
2225
+ if (s && e.eat(
2226
+ 123
2227
+ /* { */
2228
+ ) && this.regexp_eatHexDigits(e) && e.eat(
2229
+ 125
2230
+ /* } */
2231
+ ) && Gt(e.lastIntValue))
2232
+ return !0;
2233
+ s && e.raise("Invalid unicode escape"), e.pos = i;
2234
+ }
2235
+ return !1;
2236
+ };
2237
+ function Gt(e) {
2238
+ return e >= 0 && e <= 1114111;
2239
+ }
2240
+ c.regexp_eatIdentityEscape = function(e) {
2241
+ if (e.switchU)
2242
+ return this.regexp_eatSyntaxCharacter(e) ? !0 : e.eat(
2243
+ 47
2244
+ /* / */
2245
+ ) ? (e.lastIntValue = 47, !0) : !1;
2246
+ var t = e.current();
2247
+ return t !== 99 && (!e.switchN || t !== 107) ? (e.lastIntValue = t, e.advance(), !0) : !1;
2248
+ };
2249
+ c.regexp_eatDecimalEscape = function(e) {
2250
+ e.lastIntValue = 0;
2251
+ var t = e.current();
2252
+ if (t >= 49 && t <= 57) {
2253
+ do
2254
+ e.lastIntValue = 10 * e.lastIntValue + (t - 48), e.advance();
2255
+ while ((t = e.current()) >= 48 && t <= 57);
2256
+ return !0;
2257
+ }
2258
+ return !1;
2259
+ };
2260
+ var nt = 0, O = 1, I = 2;
2261
+ c.regexp_eatCharacterClassEscape = function(e) {
2262
+ var t = e.current();
2263
+ if (Ht(t))
2264
+ return e.lastIntValue = -1, e.advance(), O;
2265
+ var i = !1;
2266
+ if (e.switchU && this.options.ecmaVersion >= 9 && ((i = t === 80) || t === 112)) {
2267
+ e.lastIntValue = -1, e.advance();
2268
+ var s;
2269
+ if (e.eat(
2270
+ 123
2271
+ /* { */
2272
+ ) && (s = this.regexp_eatUnicodePropertyValueExpression(e)) && e.eat(
2273
+ 125
2274
+ /* } */
2275
+ ))
2276
+ return i && s === I && e.raise("Invalid property name"), s;
2277
+ e.raise("Invalid property name");
2278
+ }
2279
+ return nt;
2280
+ };
2281
+ function Ht(e) {
2282
+ return e === 100 || e === 68 || e === 115 || e === 83 || e === 119 || e === 87;
2283
+ }
2284
+ c.regexp_eatUnicodePropertyValueExpression = function(e) {
2285
+ var t = e.pos;
2286
+ if (this.regexp_eatUnicodePropertyName(e) && e.eat(
2287
+ 61
2288
+ /* = */
2289
+ )) {
2290
+ var i = e.lastStringValue;
2291
+ if (this.regexp_eatUnicodePropertyValue(e)) {
2292
+ var s = e.lastStringValue;
2293
+ return this.regexp_validateUnicodePropertyNameAndValue(e, i, s), O;
2294
+ }
2295
+ }
2296
+ if (e.pos = t, this.regexp_eatLoneUnicodePropertyNameOrValue(e)) {
2297
+ var r = e.lastStringValue;
2298
+ return this.regexp_validateUnicodePropertyNameOrValue(e, r);
2299
+ }
2300
+ return nt;
2301
+ };
2302
+ c.regexp_validateUnicodePropertyNameAndValue = function(e, t, i) {
2303
+ K(e.unicodeProperties.nonBinary, t) || e.raise("Invalid property name"), e.unicodeProperties.nonBinary[t].test(i) || e.raise("Invalid property value");
2304
+ };
2305
+ c.regexp_validateUnicodePropertyNameOrValue = function(e, t) {
2306
+ if (e.unicodeProperties.binary.test(t))
2307
+ return O;
2308
+ if (e.switchV && e.unicodeProperties.binaryOfStrings.test(t))
2309
+ return I;
2310
+ e.raise("Invalid property name");
2311
+ };
2312
+ c.regexp_eatUnicodePropertyName = function(e) {
2313
+ var t = 0;
2314
+ for (e.lastStringValue = ""; ut(t = e.current()); )
2315
+ e.lastStringValue += R(t), e.advance();
2316
+ return e.lastStringValue !== "";
2317
+ };
2318
+ function ut(e) {
2319
+ return rt(e) || e === 95;
2320
+ }
2321
+ c.regexp_eatUnicodePropertyValue = function(e) {
2322
+ var t = 0;
2323
+ for (e.lastStringValue = ""; Wt(t = e.current()); )
2324
+ e.lastStringValue += R(t), e.advance();
2325
+ return e.lastStringValue !== "";
2326
+ };
2327
+ function Wt(e) {
2328
+ return ut(e) || ce(e);
2329
+ }
2330
+ c.regexp_eatLoneUnicodePropertyNameOrValue = function(e) {
2331
+ return this.regexp_eatUnicodePropertyValue(e);
2332
+ };
2333
+ c.regexp_eatCharacterClass = function(e) {
2334
+ if (e.eat(
2335
+ 91
2336
+ /* [ */
2337
+ )) {
2338
+ var t = e.eat(
2339
+ 94
2340
+ /* ^ */
2341
+ ), i = this.regexp_classContents(e);
2342
+ return e.eat(
2343
+ 93
2344
+ /* ] */
2345
+ ) || e.raise("Unterminated character class"), t && i === I && e.raise("Negated character class may contain strings"), !0;
2346
+ }
2347
+ return !1;
2348
+ };
2349
+ c.regexp_classContents = function(e) {
2350
+ return e.current() === 93 ? O : e.switchV ? this.regexp_classSetExpression(e) : (this.regexp_nonEmptyClassRanges(e), O);
2351
+ };
2352
+ c.regexp_nonEmptyClassRanges = function(e) {
2353
+ for (; this.regexp_eatClassAtom(e); ) {
2354
+ var t = e.lastIntValue;
2355
+ if (e.eat(
2356
+ 45
2357
+ /* - */
2358
+ ) && this.regexp_eatClassAtom(e)) {
2359
+ var i = e.lastIntValue;
2360
+ e.switchU && (t === -1 || i === -1) && e.raise("Invalid character class"), t !== -1 && i !== -1 && t > i && e.raise("Range out of order in character class");
2361
+ }
2362
+ }
2363
+ };
2364
+ c.regexp_eatClassAtom = function(e) {
2365
+ var t = e.pos;
2366
+ if (e.eat(
2367
+ 92
2368
+ /* \ */
2369
+ )) {
2370
+ if (this.regexp_eatClassEscape(e))
2371
+ return !0;
2372
+ if (e.switchU) {
2373
+ var i = e.current();
2374
+ (i === 99 || ct(i)) && e.raise("Invalid class escape"), e.raise("Invalid escape");
2375
+ }
2376
+ e.pos = t;
2377
+ }
2378
+ var s = e.current();
2379
+ return s !== 93 ? (e.lastIntValue = s, e.advance(), !0) : !1;
2380
+ };
2381
+ c.regexp_eatClassEscape = function(e) {
2382
+ var t = e.pos;
2383
+ if (e.eat(
2384
+ 98
2385
+ /* b */
2386
+ ))
2387
+ return e.lastIntValue = 8, !0;
2388
+ if (e.switchU && e.eat(
2389
+ 45
2390
+ /* - */
2391
+ ))
2392
+ return e.lastIntValue = 45, !0;
2393
+ if (!e.switchU && e.eat(
2394
+ 99
2395
+ /* c */
2396
+ )) {
2397
+ if (this.regexp_eatClassControlLetter(e))
2398
+ return !0;
2399
+ e.pos = t;
2400
+ }
2401
+ return this.regexp_eatCharacterClassEscape(e) || this.regexp_eatCharacterEscape(e);
2402
+ };
2403
+ c.regexp_classSetExpression = function(e) {
2404
+ var t = O, i;
2405
+ if (!this.regexp_eatClassSetRange(e)) if (i = this.regexp_eatClassSetOperand(e)) {
2406
+ i === I && (t = I);
2407
+ for (var s = e.pos; e.eatChars(
2408
+ [38, 38]
2409
+ /* && */
2410
+ ); ) {
2411
+ if (e.current() !== 38 && (i = this.regexp_eatClassSetOperand(e))) {
2412
+ i !== I && (t = O);
2413
+ continue;
2414
+ }
2415
+ e.raise("Invalid character in character class");
2416
+ }
2417
+ if (s !== e.pos)
2418
+ return t;
2419
+ for (; e.eatChars(
2420
+ [45, 45]
2421
+ /* -- */
2422
+ ); )
2423
+ this.regexp_eatClassSetOperand(e) || e.raise("Invalid character in character class");
2424
+ if (s !== e.pos)
2425
+ return t;
2426
+ } else
2427
+ e.raise("Invalid character in character class");
2428
+ for (; ; )
2429
+ if (!this.regexp_eatClassSetRange(e)) {
2430
+ if (i = this.regexp_eatClassSetOperand(e), !i)
2431
+ return t;
2432
+ i === I && (t = I);
2433
+ }
2434
+ };
2435
+ c.regexp_eatClassSetRange = function(e) {
2436
+ var t = e.pos;
2437
+ if (this.regexp_eatClassSetCharacter(e)) {
2438
+ var i = e.lastIntValue;
2439
+ if (e.eat(
2440
+ 45
2441
+ /* - */
2442
+ ) && this.regexp_eatClassSetCharacter(e)) {
2443
+ var s = e.lastIntValue;
2444
+ return i !== -1 && s !== -1 && i > s && e.raise("Range out of order in character class"), !0;
2445
+ }
2446
+ e.pos = t;
2447
+ }
2448
+ return !1;
2449
+ };
2450
+ c.regexp_eatClassSetOperand = function(e) {
2451
+ return this.regexp_eatClassSetCharacter(e) ? O : this.regexp_eatClassStringDisjunction(e) || this.regexp_eatNestedClass(e);
2452
+ };
2453
+ c.regexp_eatNestedClass = function(e) {
2454
+ var t = e.pos;
2455
+ if (e.eat(
2456
+ 91
2457
+ /* [ */
2458
+ )) {
2459
+ var i = e.eat(
2460
+ 94
2461
+ /* ^ */
2462
+ ), s = this.regexp_classContents(e);
2463
+ if (e.eat(
2464
+ 93
2465
+ /* ] */
2466
+ ))
2467
+ return i && s === I && e.raise("Negated character class may contain strings"), s;
2468
+ e.pos = t;
2469
+ }
2470
+ if (e.eat(
2471
+ 92
2472
+ /* \ */
2473
+ )) {
2474
+ var r = this.regexp_eatCharacterClassEscape(e);
2475
+ if (r)
2476
+ return r;
2477
+ e.pos = t;
2478
+ }
2479
+ return null;
2480
+ };
2481
+ c.regexp_eatClassStringDisjunction = function(e) {
2482
+ var t = e.pos;
2483
+ if (e.eatChars(
2484
+ [92, 113]
2485
+ /* \q */
2486
+ )) {
2487
+ if (e.eat(
2488
+ 123
2489
+ /* { */
2490
+ )) {
2491
+ var i = this.regexp_classStringDisjunctionContents(e);
2492
+ if (e.eat(
2493
+ 125
2494
+ /* } */
2495
+ ))
2496
+ return i;
2497
+ } else
2498
+ e.raise("Invalid escape");
2499
+ e.pos = t;
2500
+ }
2501
+ return null;
2502
+ };
2503
+ c.regexp_classStringDisjunctionContents = function(e) {
2504
+ for (var t = this.regexp_classString(e); e.eat(
2505
+ 124
2506
+ /* | */
2507
+ ); )
2508
+ this.regexp_classString(e) === I && (t = I);
2509
+ return t;
2510
+ };
2511
+ c.regexp_classString = function(e) {
2512
+ for (var t = 0; this.regexp_eatClassSetCharacter(e); )
2513
+ t++;
2514
+ return t === 1 ? O : I;
2515
+ };
2516
+ c.regexp_eatClassSetCharacter = function(e) {
2517
+ var t = e.pos;
2518
+ if (e.eat(
2519
+ 92
2520
+ /* \ */
2521
+ ))
2522
+ return this.regexp_eatCharacterEscape(e) || this.regexp_eatClassSetReservedPunctuator(e) ? !0 : e.eat(
2523
+ 98
2524
+ /* b */
2525
+ ) ? (e.lastIntValue = 8, !0) : (e.pos = t, !1);
2526
+ var i = e.current();
2527
+ return i < 0 || i === e.lookahead() && zt(i) || Kt(i) ? !1 : (e.advance(), e.lastIntValue = i, !0);
2528
+ };
2529
+ function zt(e) {
2530
+ return e === 33 || e >= 35 && e <= 38 || e >= 42 && e <= 44 || e === 46 || e >= 58 && e <= 64 || e === 94 || e === 96 || e === 126;
2531
+ }
2532
+ function Kt(e) {
2533
+ return e === 40 || e === 41 || e === 45 || e === 47 || e >= 91 && e <= 93 || e >= 123 && e <= 125;
2534
+ }
2535
+ c.regexp_eatClassSetReservedPunctuator = function(e) {
2536
+ var t = e.current();
2537
+ return Qt(t) ? (e.lastIntValue = t, e.advance(), !0) : !1;
2538
+ };
2539
+ function Qt(e) {
2540
+ return e === 33 || e === 35 || e === 37 || e === 38 || e === 44 || e === 45 || e >= 58 && e <= 62 || e === 64 || e === 96 || e === 126;
2541
+ }
2542
+ c.regexp_eatClassControlLetter = function(e) {
2543
+ var t = e.current();
2544
+ return ce(t) || t === 95 ? (e.lastIntValue = t % 32, e.advance(), !0) : !1;
2545
+ };
2546
+ c.regexp_eatHexEscapeSequence = function(e) {
2547
+ var t = e.pos;
2548
+ if (e.eat(
2549
+ 120
2550
+ /* x */
2551
+ )) {
2552
+ if (this.regexp_eatFixedHexDigits(e, 2))
2553
+ return !0;
2554
+ e.switchU && e.raise("Invalid escape"), e.pos = t;
2555
+ }
2556
+ return !1;
2557
+ };
2558
+ c.regexp_eatDecimalDigits = function(e) {
2559
+ var t = e.pos, i = 0;
2560
+ for (e.lastIntValue = 0; ce(i = e.current()); )
2561
+ e.lastIntValue = 10 * e.lastIntValue + (i - 48), e.advance();
2562
+ return e.pos !== t;
2563
+ };
2564
+ function ce(e) {
2565
+ return e >= 48 && e <= 57;
2566
+ }
2567
+ c.regexp_eatHexDigits = function(e) {
2568
+ var t = e.pos, i = 0;
2569
+ for (e.lastIntValue = 0; ot(i = e.current()); )
2570
+ e.lastIntValue = 16 * e.lastIntValue + ht(i), e.advance();
2571
+ return e.pos !== t;
2572
+ };
2573
+ function ot(e) {
2574
+ return e >= 48 && e <= 57 || e >= 65 && e <= 70 || e >= 97 && e <= 102;
2575
+ }
2576
+ function ht(e) {
2577
+ return e >= 65 && e <= 70 ? 10 + (e - 65) : e >= 97 && e <= 102 ? 10 + (e - 97) : e - 48;
2578
+ }
2579
+ c.regexp_eatLegacyOctalEscapeSequence = function(e) {
2580
+ if (this.regexp_eatOctalDigit(e)) {
2581
+ var t = e.lastIntValue;
2582
+ if (this.regexp_eatOctalDigit(e)) {
2583
+ var i = e.lastIntValue;
2584
+ t <= 3 && this.regexp_eatOctalDigit(e) ? e.lastIntValue = t * 64 + i * 8 + e.lastIntValue : e.lastIntValue = t * 8 + i;
2585
+ } else
2586
+ e.lastIntValue = t;
2587
+ return !0;
2588
+ }
2589
+ return !1;
2590
+ };
2591
+ c.regexp_eatOctalDigit = function(e) {
2592
+ var t = e.current();
2593
+ return ct(t) ? (e.lastIntValue = t - 48, e.advance(), !0) : (e.lastIntValue = 0, !1);
2594
+ };
2595
+ function ct(e) {
2596
+ return e >= 48 && e <= 55;
2597
+ }
2598
+ c.regexp_eatFixedHexDigits = function(e, t) {
2599
+ var i = e.pos;
2600
+ e.lastIntValue = 0;
2601
+ for (var s = 0; s < t; ++s) {
2602
+ var r = e.current();
2603
+ if (!ot(r))
2604
+ return e.pos = i, !1;
2605
+ e.lastIntValue = 16 * e.lastIntValue + ht(r), e.advance();
2606
+ }
2607
+ return !0;
2608
+ };
2609
+ var ke = function(t) {
2610
+ this.type = t.type, this.value = t.value, this.start = t.start, this.end = t.end, t.options.locations && (this.loc = new re(t, t.startLoc, t.endLoc)), t.options.ranges && (this.range = [t.start, t.end]);
2611
+ }, x = y.prototype;
2612
+ x.next = function(e) {
2613
+ !e && this.type.keyword && this.containsEsc && this.raiseRecoverable(this.start, "Escape sequence in keyword " + this.type.keyword), this.options.onToken && this.options.onToken(new ke(this)), this.lastTokEnd = this.end, this.lastTokStart = this.start, this.lastTokEndLoc = this.endLoc, this.lastTokStartLoc = this.startLoc, this.nextToken();
2614
+ };
2615
+ x.getToken = function() {
2616
+ return this.next(), new ke(this);
2617
+ };
2618
+ typeof Symbol < "u" && (x[Symbol.iterator] = function() {
2619
+ var e = this;
2620
+ return {
2621
+ next: function() {
2622
+ var t = e.getToken();
2623
+ return {
2624
+ done: t.type === a.eof,
2625
+ value: t
2626
+ };
2627
+ }
2628
+ };
2629
+ });
2630
+ x.nextToken = function() {
2631
+ var e = this.curContext();
2632
+ if ((!e || !e.preserveSpace) && this.skipSpace(), this.start = this.pos, this.options.locations && (this.startLoc = this.curPosition()), this.pos >= this.input.length)
2633
+ return this.finishToken(a.eof);
2634
+ if (e.override)
2635
+ return e.override(this);
2636
+ this.readToken(this.fullCharCodeAtPos());
2637
+ };
2638
+ x.readToken = function(e) {
2639
+ return T(e, this.options.ecmaVersion >= 6) || e === 92 ? this.readWord() : this.getTokenFromCode(e);
2640
+ };
2641
+ x.fullCharCodeAt = function(e) {
2642
+ var t = this.input.charCodeAt(e);
2643
+ if (t <= 55295 || t >= 56320)
2644
+ return t;
2645
+ var i = this.input.charCodeAt(e + 1);
2646
+ return i <= 56319 || i >= 57344 ? t : (t << 10) + i - 56613888;
2647
+ };
2648
+ x.fullCharCodeAtPos = function() {
2649
+ return this.fullCharCodeAt(this.pos);
2650
+ };
2651
+ x.skipBlockComment = function() {
2652
+ var e = this.options.onComment && this.curPosition(), t = this.pos, i = this.input.indexOf("*/", this.pos += 2);
2653
+ if (i === -1 && this.raise(this.pos - 2, "Unterminated comment"), this.pos = i + 2, this.options.locations)
2654
+ for (var s = void 0, r = t; (s = Le(this.input, r, this.pos)) > -1; )
2655
+ ++this.curLine, r = this.lineStart = s;
2656
+ this.options.onComment && this.options.onComment(
2657
+ !0,
2658
+ this.input.slice(t + 2, i),
2659
+ t,
2660
+ this.pos,
2661
+ e,
2662
+ this.curPosition()
2663
+ );
2664
+ };
2665
+ x.skipLineComment = function(e) {
2666
+ for (var t = this.pos, i = this.options.onComment && this.curPosition(), s = this.input.charCodeAt(this.pos += e); this.pos < this.input.length && !z(s); )
2667
+ s = this.input.charCodeAt(++this.pos);
2668
+ this.options.onComment && this.options.onComment(
2669
+ !1,
2670
+ this.input.slice(t + e, this.pos),
2671
+ t,
2672
+ this.pos,
2673
+ i,
2674
+ this.curPosition()
2675
+ );
2676
+ };
2677
+ x.skipSpace = function() {
2678
+ e: for (; this.pos < this.input.length; ) {
2679
+ var e = this.input.charCodeAt(this.pos);
2680
+ switch (e) {
2681
+ case 32:
2682
+ case 160:
2683
+ ++this.pos;
2684
+ break;
2685
+ case 13:
2686
+ this.input.charCodeAt(this.pos + 1) === 10 && ++this.pos;
2687
+ case 10:
2688
+ case 8232:
2689
+ case 8233:
2690
+ ++this.pos, this.options.locations && (++this.curLine, this.lineStart = this.pos);
2691
+ break;
2692
+ case 47:
2693
+ switch (this.input.charCodeAt(this.pos + 1)) {
2694
+ case 42:
2695
+ this.skipBlockComment();
2696
+ break;
2697
+ case 47:
2698
+ this.skipLineComment(2);
2699
+ break;
2700
+ default:
2701
+ break e;
2702
+ }
2703
+ break;
2704
+ default:
2705
+ if (e > 8 && e < 14 || e >= 5760 && Re.test(String.fromCharCode(e)))
2706
+ ++this.pos;
2707
+ else
2708
+ break e;
2709
+ }
2710
+ }
2711
+ };
2712
+ x.finishToken = function(e, t) {
2713
+ this.end = this.pos, this.options.locations && (this.endLoc = this.curPosition());
2714
+ var i = this.type;
2715
+ this.type = e, this.value = t, this.updateContext(i);
2716
+ };
2717
+ x.readToken_dot = function() {
2718
+ var e = this.input.charCodeAt(this.pos + 1);
2719
+ if (e >= 48 && e <= 57)
2720
+ return this.readNumber(!0);
2721
+ var t = this.input.charCodeAt(this.pos + 2);
2722
+ return this.options.ecmaVersion >= 6 && e === 46 && t === 46 ? (this.pos += 3, this.finishToken(a.ellipsis)) : (++this.pos, this.finishToken(a.dot));
2723
+ };
2724
+ x.readToken_slash = function() {
2725
+ var e = this.input.charCodeAt(this.pos + 1);
2726
+ return this.exprAllowed ? (++this.pos, this.readRegexp()) : e === 61 ? this.finishOp(a.assign, 2) : this.finishOp(a.slash, 1);
2727
+ };
2728
+ x.readToken_mult_modulo_exp = function(e) {
2729
+ var t = this.input.charCodeAt(this.pos + 1), i = 1, s = e === 42 ? a.star : a.modulo;
2730
+ return this.options.ecmaVersion >= 7 && e === 42 && t === 42 && (++i, s = a.starstar, t = this.input.charCodeAt(this.pos + 2)), t === 61 ? this.finishOp(a.assign, i + 1) : this.finishOp(s, i);
2731
+ };
2732
+ x.readToken_pipe_amp = function(e) {
2733
+ var t = this.input.charCodeAt(this.pos + 1);
2734
+ if (t === e) {
2735
+ if (this.options.ecmaVersion >= 12) {
2736
+ var i = this.input.charCodeAt(this.pos + 2);
2737
+ if (i === 61)
2738
+ return this.finishOp(a.assign, 3);
2739
+ }
2740
+ return this.finishOp(e === 124 ? a.logicalOR : a.logicalAND, 2);
2741
+ }
2742
+ return t === 61 ? this.finishOp(a.assign, 2) : this.finishOp(e === 124 ? a.bitwiseOR : a.bitwiseAND, 1);
2743
+ };
2744
+ x.readToken_caret = function() {
2745
+ var e = this.input.charCodeAt(this.pos + 1);
2746
+ return e === 61 ? this.finishOp(a.assign, 2) : this.finishOp(a.bitwiseXOR, 1);
2747
+ };
2748
+ x.readToken_plus_min = function(e) {
2749
+ var t = this.input.charCodeAt(this.pos + 1);
2750
+ return t === e ? t === 45 && !this.inModule && this.input.charCodeAt(this.pos + 2) === 62 && (this.lastTokEnd === 0 || w.test(this.input.slice(this.lastTokEnd, this.pos))) ? (this.skipLineComment(3), this.skipSpace(), this.nextToken()) : this.finishOp(a.incDec, 2) : t === 61 ? this.finishOp(a.assign, 2) : this.finishOp(a.plusMin, 1);
2751
+ };
2752
+ x.readToken_lt_gt = function(e) {
2753
+ var t = this.input.charCodeAt(this.pos + 1), i = 1;
2754
+ return t === e ? (i = e === 62 && this.input.charCodeAt(this.pos + 2) === 62 ? 3 : 2, this.input.charCodeAt(this.pos + i) === 61 ? this.finishOp(a.assign, i + 1) : this.finishOp(a.bitShift, i)) : t === 33 && e === 60 && !this.inModule && this.input.charCodeAt(this.pos + 2) === 45 && this.input.charCodeAt(this.pos + 3) === 45 ? (this.skipLineComment(4), this.skipSpace(), this.nextToken()) : (t === 61 && (i = 2), this.finishOp(a.relational, i));
2755
+ };
2756
+ x.readToken_eq_excl = function(e) {
2757
+ var t = this.input.charCodeAt(this.pos + 1);
2758
+ return t === 61 ? this.finishOp(a.equality, this.input.charCodeAt(this.pos + 2) === 61 ? 3 : 2) : e === 61 && t === 62 && this.options.ecmaVersion >= 6 ? (this.pos += 2, this.finishToken(a.arrow)) : this.finishOp(e === 61 ? a.eq : a.prefix, 1);
2759
+ };
2760
+ x.readToken_question = function() {
2761
+ var e = this.options.ecmaVersion;
2762
+ if (e >= 11) {
2763
+ var t = this.input.charCodeAt(this.pos + 1);
2764
+ if (t === 46) {
2765
+ var i = this.input.charCodeAt(this.pos + 2);
2766
+ if (i < 48 || i > 57)
2767
+ return this.finishOp(a.questionDot, 2);
2768
+ }
2769
+ if (t === 63) {
2770
+ if (e >= 12) {
2771
+ var s = this.input.charCodeAt(this.pos + 2);
2772
+ if (s === 61)
2773
+ return this.finishOp(a.assign, 3);
2774
+ }
2775
+ return this.finishOp(a.coalesce, 2);
2776
+ }
2777
+ }
2778
+ return this.finishOp(a.question, 1);
2779
+ };
2780
+ x.readToken_numberSign = function() {
2781
+ var e = this.options.ecmaVersion, t = 35;
2782
+ if (e >= 13 && (++this.pos, t = this.fullCharCodeAtPos(), T(t, !0) || t === 92))
2783
+ return this.finishToken(a.privateId, this.readWord1());
2784
+ this.raise(this.pos, "Unexpected character '" + R(t) + "'");
2785
+ };
2786
+ x.getTokenFromCode = function(e) {
2787
+ switch (e) {
2788
+ // The interpretation of a dot depends on whether it is followed
2789
+ // by a digit or another two dots.
2790
+ case 46:
2791
+ return this.readToken_dot();
2792
+ // Punctuation tokens.
2793
+ case 40:
2794
+ return ++this.pos, this.finishToken(a.parenL);
2795
+ case 41:
2796
+ return ++this.pos, this.finishToken(a.parenR);
2797
+ case 59:
2798
+ return ++this.pos, this.finishToken(a.semi);
2799
+ case 44:
2800
+ return ++this.pos, this.finishToken(a.comma);
2801
+ case 91:
2802
+ return ++this.pos, this.finishToken(a.bracketL);
2803
+ case 93:
2804
+ return ++this.pos, this.finishToken(a.bracketR);
2805
+ case 123:
2806
+ return ++this.pos, this.finishToken(a.braceL);
2807
+ case 125:
2808
+ return ++this.pos, this.finishToken(a.braceR);
2809
+ case 58:
2810
+ return ++this.pos, this.finishToken(a.colon);
2811
+ case 96:
2812
+ if (this.options.ecmaVersion < 6)
2813
+ break;
2814
+ return ++this.pos, this.finishToken(a.backQuote);
2815
+ case 48:
2816
+ var t = this.input.charCodeAt(this.pos + 1);
2817
+ if (t === 120 || t === 88)
2818
+ return this.readRadixNumber(16);
2819
+ if (this.options.ecmaVersion >= 6) {
2820
+ if (t === 111 || t === 79)
2821
+ return this.readRadixNumber(8);
2822
+ if (t === 98 || t === 66)
2823
+ return this.readRadixNumber(2);
2824
+ }
2825
+ // Anything else beginning with a digit is an integer, octal
2826
+ // number, or float.
2827
+ case 49:
2828
+ case 50:
2829
+ case 51:
2830
+ case 52:
2831
+ case 53:
2832
+ case 54:
2833
+ case 55:
2834
+ case 56:
2835
+ case 57:
2836
+ return this.readNumber(!1);
2837
+ // Quotes produce strings.
2838
+ case 34:
2839
+ case 39:
2840
+ return this.readString(e);
2841
+ // Operators are parsed inline in tiny state machines. '=' (61) is
2842
+ // often referred to. `finishOp` simply skips the amount of
2843
+ // characters it is given as second argument, and returns a token
2844
+ // of the type given by its first argument.
2845
+ case 47:
2846
+ return this.readToken_slash();
2847
+ case 37:
2848
+ case 42:
2849
+ return this.readToken_mult_modulo_exp(e);
2850
+ case 124:
2851
+ case 38:
2852
+ return this.readToken_pipe_amp(e);
2853
+ case 94:
2854
+ return this.readToken_caret();
2855
+ case 43:
2856
+ case 45:
2857
+ return this.readToken_plus_min(e);
2858
+ case 60:
2859
+ case 62:
2860
+ return this.readToken_lt_gt(e);
2861
+ case 61:
2862
+ case 33:
2863
+ return this.readToken_eq_excl(e);
2864
+ case 63:
2865
+ return this.readToken_question();
2866
+ case 126:
2867
+ return this.finishOp(a.prefix, 1);
2868
+ case 35:
2869
+ return this.readToken_numberSign();
2870
+ }
2871
+ this.raise(this.pos, "Unexpected character '" + R(e) + "'");
2872
+ };
2873
+ x.finishOp = function(e, t) {
2874
+ var i = this.input.slice(this.pos, this.pos + t);
2875
+ return this.pos += t, this.finishToken(e, i);
2876
+ };
2877
+ x.readRegexp = function() {
2878
+ for (var e, t, i = this.pos; ; ) {
2879
+ this.pos >= this.input.length && this.raise(i, "Unterminated regular expression");
2880
+ var s = this.input.charAt(this.pos);
2881
+ if (w.test(s) && this.raise(i, "Unterminated regular expression"), e)
2882
+ e = !1;
2883
+ else {
2884
+ if (s === "[")
2885
+ t = !0;
2886
+ else if (s === "]" && t)
2887
+ t = !1;
2888
+ else if (s === "/" && !t)
2889
+ break;
2890
+ e = s === "\\";
2891
+ }
2892
+ ++this.pos;
2893
+ }
2894
+ var r = this.input.slice(i, this.pos);
2895
+ ++this.pos;
2896
+ var n = this.pos, u = this.readWord1();
2897
+ this.containsEsc && this.unexpected(n);
2898
+ var o = this.regexpState || (this.regexpState = new L(this));
2899
+ o.reset(i, r, u), this.validateRegExpFlags(o), this.validateRegExpPattern(o);
2900
+ var h = null;
2901
+ try {
2902
+ h = new RegExp(r, u);
2903
+ } catch {
2904
+ }
2905
+ return this.finishToken(a.regexp, { pattern: r, flags: u, value: h });
2906
+ };
2907
+ x.readInt = function(e, t, i) {
2908
+ for (var s = this.options.ecmaVersion >= 12 && t === void 0, r = i && this.input.charCodeAt(this.pos) === 48, n = this.pos, u = 0, o = 0, h = 0, p = t ?? 1 / 0; h < p; ++h, ++this.pos) {
2909
+ var d = this.input.charCodeAt(this.pos), g = void 0;
2910
+ if (s && d === 95) {
2911
+ r && this.raiseRecoverable(this.pos, "Numeric separator is not allowed in legacy octal numeric literals"), o === 95 && this.raiseRecoverable(this.pos, "Numeric separator must be exactly one underscore"), h === 0 && this.raiseRecoverable(this.pos, "Numeric separator is not allowed at the first of digits"), o = d;
2912
+ continue;
2913
+ }
2914
+ if (d >= 97 ? g = d - 97 + 10 : d >= 65 ? g = d - 65 + 10 : d >= 48 && d <= 57 ? g = d - 48 : g = 1 / 0, g >= e)
2915
+ break;
2916
+ o = d, u = u * e + g;
2917
+ }
2918
+ return s && o === 95 && this.raiseRecoverable(this.pos - 1, "Numeric separator is not allowed at the last of digits"), this.pos === n || t != null && this.pos - n !== t ? null : u;
2919
+ };
2920
+ function Yt(e, t) {
2921
+ return t ? parseInt(e, 8) : parseFloat(e.replace(/_/g, ""));
2922
+ }
2923
+ function lt(e) {
2924
+ return typeof BigInt != "function" ? null : BigInt(e.replace(/_/g, ""));
2925
+ }
2926
+ x.readRadixNumber = function(e) {
2927
+ var t = this.pos;
2928
+ this.pos += 2;
2929
+ var i = this.readInt(e);
2930
+ return i == null && this.raise(this.start + 2, "Expected number in radix " + e), this.options.ecmaVersion >= 11 && this.input.charCodeAt(this.pos) === 110 ? (i = lt(this.input.slice(t, this.pos)), ++this.pos) : T(this.fullCharCodeAtPos()) && this.raise(this.pos, "Identifier directly after number"), this.finishToken(a.num, i);
2931
+ };
2932
+ x.readNumber = function(e) {
2933
+ var t = this.pos;
2934
+ !e && this.readInt(10, void 0, !0) === null && this.raise(t, "Invalid number");
2935
+ var i = this.pos - t >= 2 && this.input.charCodeAt(t) === 48;
2936
+ i && this.strict && this.raise(t, "Invalid number");
2937
+ var s = this.input.charCodeAt(this.pos);
2938
+ if (!i && !e && this.options.ecmaVersion >= 11 && s === 110) {
2939
+ var r = lt(this.input.slice(t, this.pos));
2940
+ return ++this.pos, T(this.fullCharCodeAtPos()) && this.raise(this.pos, "Identifier directly after number"), this.finishToken(a.num, r);
2941
+ }
2942
+ i && /[89]/.test(this.input.slice(t, this.pos)) && (i = !1), s === 46 && !i && (++this.pos, this.readInt(10), s = this.input.charCodeAt(this.pos)), (s === 69 || s === 101) && !i && (s = this.input.charCodeAt(++this.pos), (s === 43 || s === 45) && ++this.pos, this.readInt(10) === null && this.raise(t, "Invalid number")), T(this.fullCharCodeAtPos()) && this.raise(this.pos, "Identifier directly after number");
2943
+ var n = Yt(this.input.slice(t, this.pos), i);
2944
+ return this.finishToken(a.num, n);
2945
+ };
2946
+ x.readCodePoint = function() {
2947
+ var e = this.input.charCodeAt(this.pos), t;
2948
+ if (e === 123) {
2949
+ this.options.ecmaVersion < 6 && this.unexpected();
2950
+ var i = ++this.pos;
2951
+ t = this.readHexChar(this.input.indexOf("}", this.pos) - this.pos), ++this.pos, t > 1114111 && this.invalidStringToken(i, "Code point out of bounds");
2952
+ } else
2953
+ t = this.readHexChar(4);
2954
+ return t;
2955
+ };
2956
+ x.readString = function(e) {
2957
+ for (var t = "", i = ++this.pos; ; ) {
2958
+ this.pos >= this.input.length && this.raise(this.start, "Unterminated string constant");
2959
+ var s = this.input.charCodeAt(this.pos);
2960
+ if (s === e)
2961
+ break;
2962
+ s === 92 ? (t += this.input.slice(i, this.pos), t += this.readEscapedChar(!1), i = this.pos) : s === 8232 || s === 8233 ? (this.options.ecmaVersion < 10 && this.raise(this.start, "Unterminated string constant"), ++this.pos, this.options.locations && (this.curLine++, this.lineStart = this.pos)) : (z(s) && this.raise(this.start, "Unterminated string constant"), ++this.pos);
2963
+ }
2964
+ return t += this.input.slice(i, this.pos++), this.finishToken(a.string, t);
2965
+ };
2966
+ var pt = {};
2967
+ x.tryReadTemplateToken = function() {
2968
+ this.inTemplateElement = !0;
2969
+ try {
2970
+ this.readTmplToken();
2971
+ } catch (e) {
2972
+ if (e === pt)
2973
+ this.readInvalidTemplateToken();
2974
+ else
2975
+ throw e;
2976
+ }
2977
+ this.inTemplateElement = !1;
2978
+ };
2979
+ x.invalidStringToken = function(e, t) {
2980
+ if (this.inTemplateElement && this.options.ecmaVersion >= 9)
2981
+ throw pt;
2982
+ this.raise(e, t);
2983
+ };
2984
+ x.readTmplToken = function() {
2985
+ for (var e = "", t = this.pos; ; ) {
2986
+ this.pos >= this.input.length && this.raise(this.start, "Unterminated template");
2987
+ var i = this.input.charCodeAt(this.pos);
2988
+ if (i === 96 || i === 36 && this.input.charCodeAt(this.pos + 1) === 123)
2989
+ return this.pos === this.start && (this.type === a.template || this.type === a.invalidTemplate) ? i === 36 ? (this.pos += 2, this.finishToken(a.dollarBraceL)) : (++this.pos, this.finishToken(a.backQuote)) : (e += this.input.slice(t, this.pos), this.finishToken(a.template, e));
2990
+ if (i === 92)
2991
+ e += this.input.slice(t, this.pos), e += this.readEscapedChar(!0), t = this.pos;
2992
+ else if (z(i)) {
2993
+ switch (e += this.input.slice(t, this.pos), ++this.pos, i) {
2994
+ case 13:
2995
+ this.input.charCodeAt(this.pos) === 10 && ++this.pos;
2996
+ case 10:
2997
+ e += `
2998
+ `;
2999
+ break;
3000
+ default:
3001
+ e += String.fromCharCode(i);
3002
+ break;
3003
+ }
3004
+ this.options.locations && (++this.curLine, this.lineStart = this.pos), t = this.pos;
3005
+ } else
3006
+ ++this.pos;
3007
+ }
3008
+ };
3009
+ x.readInvalidTemplateToken = function() {
3010
+ for (; this.pos < this.input.length; this.pos++)
3011
+ switch (this.input[this.pos]) {
3012
+ case "\\":
3013
+ ++this.pos;
3014
+ break;
3015
+ case "$":
3016
+ if (this.input[this.pos + 1] !== "{")
3017
+ break;
3018
+ // fall through
3019
+ case "`":
3020
+ return this.finishToken(a.invalidTemplate, this.input.slice(this.start, this.pos));
3021
+ case "\r":
3022
+ this.input[this.pos + 1] === `
3023
+ ` && ++this.pos;
3024
+ // fall through
3025
+ case `
3026
+ `:
3027
+ case "\u2028":
3028
+ case "\u2029":
3029
+ ++this.curLine, this.lineStart = this.pos + 1;
3030
+ break;
3031
+ }
3032
+ this.raise(this.start, "Unterminated template");
3033
+ };
3034
+ x.readEscapedChar = function(e) {
3035
+ var t = this.input.charCodeAt(++this.pos);
3036
+ switch (++this.pos, t) {
3037
+ case 110:
3038
+ return `
3039
+ `;
3040
+ // 'n' -> '\n'
3041
+ case 114:
3042
+ return "\r";
3043
+ // 'r' -> '\r'
3044
+ case 120:
3045
+ return String.fromCharCode(this.readHexChar(2));
3046
+ // 'x'
3047
+ case 117:
3048
+ return R(this.readCodePoint());
3049
+ // 'u'
3050
+ case 116:
3051
+ return " ";
3052
+ // 't' -> '\t'
3053
+ case 98:
3054
+ return "\b";
3055
+ // 'b' -> '\b'
3056
+ case 118:
3057
+ return "\v";
3058
+ // 'v' -> '\u000b'
3059
+ case 102:
3060
+ return "\f";
3061
+ // 'f' -> '\f'
3062
+ case 13:
3063
+ this.input.charCodeAt(this.pos) === 10 && ++this.pos;
3064
+ // '\r\n'
3065
+ case 10:
3066
+ return this.options.locations && (this.lineStart = this.pos, ++this.curLine), "";
3067
+ case 56:
3068
+ case 57:
3069
+ if (this.strict && this.invalidStringToken(
3070
+ this.pos - 1,
3071
+ "Invalid escape sequence"
3072
+ ), e) {
3073
+ var i = this.pos - 1;
3074
+ this.invalidStringToken(
3075
+ i,
3076
+ "Invalid escape sequence in template string"
3077
+ );
3078
+ }
3079
+ default:
3080
+ if (t >= 48 && t <= 55) {
3081
+ var s = this.input.substr(this.pos - 1, 3).match(/^[0-7]+/)[0], r = parseInt(s, 8);
3082
+ return r > 255 && (s = s.slice(0, -1), r = parseInt(s, 8)), this.pos += s.length - 1, t = this.input.charCodeAt(this.pos), (s !== "0" || t === 56 || t === 57) && (this.strict || e) && this.invalidStringToken(
3083
+ this.pos - 1 - s.length,
3084
+ e ? "Octal literal in template string" : "Octal literal in strict mode"
3085
+ ), String.fromCharCode(r);
3086
+ }
3087
+ return z(t) ? (this.options.locations && (this.lineStart = this.pos, ++this.curLine), "") : String.fromCharCode(t);
3088
+ }
3089
+ };
3090
+ x.readHexChar = function(e) {
3091
+ var t = this.pos, i = this.readInt(16, e);
3092
+ return i === null && this.invalidStringToken(t, "Bad character escape sequence"), i;
3093
+ };
3094
+ x.readWord1 = function() {
3095
+ this.containsEsc = !1;
3096
+ for (var e = "", t = !0, i = this.pos, s = this.options.ecmaVersion >= 6; this.pos < this.input.length; ) {
3097
+ var r = this.fullCharCodeAtPos();
3098
+ if (F(r, s))
3099
+ this.pos += r <= 65535 ? 1 : 2;
3100
+ else if (r === 92) {
3101
+ this.containsEsc = !0, e += this.input.slice(i, this.pos);
3102
+ var n = this.pos;
3103
+ this.input.charCodeAt(++this.pos) !== 117 && this.invalidStringToken(this.pos, "Expecting Unicode escape sequence \\uXXXX"), ++this.pos;
3104
+ var u = this.readCodePoint();
3105
+ (t ? T : F)(u, s) || this.invalidStringToken(n, "Invalid Unicode escape"), e += R(u), i = this.pos;
3106
+ } else
3107
+ break;
3108
+ t = !1;
3109
+ }
3110
+ return e + this.input.slice(i, this.pos);
3111
+ };
3112
+ x.readWord = function() {
3113
+ var e = this.readWord1(), t = a.name;
3114
+ return this.keywords.test(e) && (t = ge[e]), this.finishToken(t, e);
3115
+ };
3116
+ var Xt = "8.16.0";
3117
+ y.acorn = {
3118
+ Parser: y,
3119
+ version: Xt,
3120
+ defaultOptions: xe,
3121
+ Position: Z,
3122
+ SourceLocation: re,
3123
+ getLineInfo: Be,
3124
+ Node: he,
3125
+ TokenType: v,
3126
+ tokTypes: a,
3127
+ keywordTypes: ge,
3128
+ TokContext: V,
3129
+ tokContexts: b,
3130
+ isIdentifierChar: F,
3131
+ isIdentifierStart: T,
3132
+ Token: ke,
3133
+ isNewLine: z,
3134
+ lineBreak: w,
3135
+ lineBreakG: gt,
3136
+ nonASCIIwhitespace: Re
3137
+ };
3138
+ function Zt(e, t, i) {
3139
+ return y.parseExpressionAt(e, t, i);
3140
+ }
3141
+ export {
3142
+ Zt as p
3143
+ };