@temperlang/std 0.0.6 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/regex.js CHANGED
@@ -1,46 +1,46 @@
1
1
  import {
2
- InterfaceType as InterfaceType_94, compiledRegexCompileFormatted as compiledRegexCompileFormatted_95, compiledRegexCompiledFound as compiledRegexCompiledFound_96, compiledRegexCompiledFind as compiledRegexCompiledFind_97, compiledRegexCompiledReplace as compiledRegexCompiledReplace_98, eqGeneric as eqGeneric_99, regexFormatterPushCodeTo as regexFormatterPushCodeTo_100, regexFormatterAdjustCodeSet as regexFormatterAdjustCodeSet_101, gtGeneric as gtGeneric_102, listify as listify_3, listJoin as listJoin_2, listBuilderAdd as listBuilderAdd_0, strCat as strCat_9, stringCodePoints as stringCodePoints_74, ltGeneric as ltGeneric_6, listGet as listGet_7, eqGeneric as eqGeneric_70, intToString as intToString_73, neGeneric as neGeneric_72, requireInstanceOf as requireInstanceOf__211, bubbleException as bubbleException__213, requireIsSafeInteger as requireIsSafeInteger__282
2
+ InterfaceType as InterfaceType_0, requireInstanceOf as requireInstanceOf__115, requireIsSafeInteger as requireIsSafeInteger__189, listify as listify_67, compiledRegexCompileFormatted as compiledRegexCompileFormatted_75, compiledRegexCompiledFound as compiledRegexCompiledFound_79, compiledRegexCompiledFind as compiledRegexCompiledFind_82, compiledRegexCompiledReplace as compiledRegexCompiledReplace_87, listJoin as listJoin_97, eqGeneric as eqGeneric_117, listBuilderAdd as listBuilderAdd_118, strCat as strCat_127, regexFormatterPushCodeTo as regexFormatterPushCodeTo_131, stringCodePoints as stringCodePoints_138, regexFormatterAdjustCodeSet as regexFormatterAdjustCodeSet_153, listGet as listGet_157, intToString as intToString_188
3
3
  } from "@temperlang/core";
4
- function methodCompiled103() {
4
+ function methodCompiled1() {
5
5
  return new CompiledRegex(this);
6
6
  }
7
- function methodFound104(text_105) {
8
- return this.compiled().found(text_105);
7
+ function methodFound2(text_3) {
8
+ return this.compiled().found(text_3);
9
9
  }
10
- function methodFind106(text_107) {
11
- return this.compiled().find(text_107);
10
+ function methodFind4(text_5) {
11
+ return this.compiled().find(text_5);
12
12
  }
13
- function methodReplace108(text_109, format_110) {
14
- return this.compiled().replace(text_109, format_110);
13
+ function methodReplace6(text_7, format_8) {
14
+ return this.compiled().replace(text_7, format_8);
15
15
  }
16
16
  /**
17
17
  * @typedef {{
18
- * compiled: () => CompiledRegex, found: (text_105: string) => boolean, find: (text_107: string) => Map<string, Group>, replace: (text_109: string, format_110: (arg0: Map<string, Group>) => string) => string
18
+ * compiled: () => CompiledRegex, found: (text_3: string) => boolean, find: (text_5: string) => Map<string, Group>, replace: (text_7: string, format_8: (arg0: Map<string, Group>) => string) => string
19
19
  * }}
20
20
  * Regex
21
21
  */
22
- export const Regex = new InterfaceType_94("Regex", [["m", "compiled", methodCompiled103], ["m", "found", methodFound104], ["m", "find", methodFind106], ["m", "replace", methodReplace108]], [], 1);
22
+ export const Regex = new InterfaceType_0("Regex", [["m", "compiled", methodCompiled1], ["m", "found", methodFound2], ["m", "find", methodFind4], ["m", "replace", methodReplace6]], [], 1);
23
23
  export class Capture {
24
24
  /** @type {string} */
25
- #name_111;
25
+ #name_9;
26
26
  /** @type {Regex} */
27
- #item_112;
27
+ #item_10;
28
28
  /**
29
- * @param {string} name_113
30
- * @param {Regex} item_114
29
+ * @param {string} name_11
30
+ * @param {Regex} item_12
31
31
  */
32
- constructor(name_113, item_114) {
33
- this.#name_111 = name_113;
34
- this.#item_112 = item_114;
32
+ constructor(name_11, item_12) {
33
+ this.#name_9 = name_11;
34
+ this.#item_10 = item_12;
35
35
  return;
36
36
  }
37
37
  /** @returns {string} */
38
38
  get name() {
39
- return this.#name_111;
39
+ return this.#name_9;
40
40
  }
41
41
  /** @returns {Regex} */
42
42
  get item() {
43
- return this.#item_112;
43
+ return this.#item_10;
44
44
  }
45
45
  };
46
46
  Regex.implementedBy(Capture);
@@ -48,18 +48,18 @@ Regex.implementedBy(Capture);
48
48
  * @typedef {{}}
49
49
  * CodePart
50
50
  */
51
- export const CodePart = new InterfaceType_94("CodePart", [], [Regex], 2);
51
+ export const CodePart = new InterfaceType_0("CodePart", [], [Regex], 2);
52
52
  export class CodePoints {
53
53
  /** @type {string} */
54
- #value_117;
55
- /** @param {string} value_118 */
56
- constructor(value_118) {
57
- this.#value_117 = value_118;
54
+ #value_15;
55
+ /** @param {string} value_16 */
56
+ constructor(value_16) {
57
+ this.#value_15 = value_16;
58
58
  return;
59
59
  }
60
60
  /** @returns {string} */
61
61
  get value() {
62
- return this.#value_117;
62
+ return this.#value_15;
63
63
  }
64
64
  };
65
65
  CodePart.implementedBy(CodePoints);
@@ -67,426 +67,426 @@ CodePart.implementedBy(CodePoints);
67
67
  * @typedef {{}}
68
68
  * Special
69
69
  */
70
- export const Special = new InterfaceType_94("Special", [], [Regex], 2);
70
+ export const Special = new InterfaceType_0("Special", [], [Regex], 2);
71
71
  /**
72
72
  * @typedef {{}}
73
73
  * SpecialSet
74
74
  */
75
- export const SpecialSet = new InterfaceType_94("SpecialSet", [], [CodePart, Special], 3);
75
+ export const SpecialSet = new InterfaceType_0("SpecialSet", [], [CodePart, Special], 3);
76
76
  export class CodeRange {
77
77
  /** @type {number} */
78
- #min_120;
78
+ #min_18;
79
79
  /** @type {number} */
80
- #max_121;
80
+ #max_19;
81
81
  /**
82
- * @param {number} min_122
83
- * @param {number} max_123
82
+ * @param {number} min_20
83
+ * @param {number} max_21
84
84
  */
85
- constructor(min_122, max_123) {
86
- this.#min_120 = min_122;
87
- this.#max_121 = max_123;
85
+ constructor(min_20, max_21) {
86
+ this.#min_18 = min_20;
87
+ this.#max_19 = max_21;
88
88
  return;
89
89
  }
90
90
  /** @returns {number} */
91
91
  get min() {
92
- return this.#min_120;
92
+ return this.#min_18;
93
93
  }
94
94
  /** @returns {number} */
95
95
  get max() {
96
- return this.#max_121;
96
+ return this.#max_19;
97
97
  }
98
98
  };
99
99
  CodePart.implementedBy(CodeRange);
100
100
  export class CodeSet {
101
101
  /** @type {Array<CodePart>} */
102
- #items_126;
102
+ #items_24;
103
103
  /** @type {boolean} */
104
- #negated_127;
104
+ #negated_25;
105
105
  /**
106
- * @param {Array<CodePart>} items_128
107
- * @param {boolean} negated_129
106
+ * @param {Array<CodePart>} items_26
107
+ * @param {boolean} negated_27
108
108
  */
109
- constructor(items_128, negated_129) {
110
- if (!(negated_129 !== void 0)) {
111
- negated_129 = false;
109
+ constructor(items_26, negated_27) {
110
+ if (!(negated_27 !== void 0)) {
111
+ negated_27 = false;
112
112
  }
113
- this.#items_126 = items_128;
114
- this.#negated_127 = negated_129;
113
+ this.#items_24 = items_26;
114
+ this.#negated_25 = negated_27;
115
115
  return;
116
116
  }
117
117
  /** @returns {Array<CodePart>} */
118
118
  get items() {
119
- return this.#items_126;
119
+ return this.#items_24;
120
120
  }
121
121
  /** @returns {boolean} */
122
122
  get negated() {
123
- return this.#negated_127;
123
+ return this.#negated_25;
124
124
  }
125
125
  };
126
126
  Regex.implementedBy(CodeSet);
127
127
  export class Or {
128
128
  /** @type {Array<Regex>} */
129
- #items_132;
130
- /** @param {Array<Regex>} items_133 */
131
- constructor(items_133) {
132
- this.#items_132 = items_133;
129
+ #items_30;
130
+ /** @param {Array<Regex>} items_31 */
131
+ constructor(items_31) {
132
+ this.#items_30 = items_31;
133
133
  return;
134
134
  }
135
135
  /** @returns {Array<Regex>} */
136
136
  get items() {
137
- return this.#items_132;
137
+ return this.#items_30;
138
138
  }
139
139
  };
140
140
  Regex.implementedBy(Or);
141
141
  export class Repeat {
142
142
  /** @type {Regex} */
143
- #item_135;
143
+ #item_33;
144
144
  /** @type {number} */
145
- #min_136;
145
+ #min_34;
146
146
  /** @type {number | null} */
147
- #max_137;
147
+ #max_35;
148
148
  /** @type {boolean} */
149
- #reluctant_138;
149
+ #reluctant_36;
150
150
  /**
151
- * @param {Regex} item_139
152
- * @param {number} min_140
153
- * @param {number | null} max_141
154
- * @param {boolean} reluctant_142
151
+ * @param {Regex} item_37
152
+ * @param {number} min_38
153
+ * @param {number | null} max_39
154
+ * @param {boolean} reluctant_40
155
155
  */
156
- constructor(item_139, min_140, max_141, reluctant_142) {
157
- if (!(reluctant_142 !== void 0)) {
158
- reluctant_142 = false;
156
+ constructor(item_37, min_38, max_39, reluctant_40) {
157
+ if (!(reluctant_40 !== void 0)) {
158
+ reluctant_40 = false;
159
159
  }
160
- this.#item_135 = item_139;
161
- this.#min_136 = min_140;
162
- this.#max_137 = max_141;
163
- this.#reluctant_138 = reluctant_142;
160
+ this.#item_33 = item_37;
161
+ this.#min_34 = min_38;
162
+ this.#max_35 = max_39;
163
+ this.#reluctant_36 = reluctant_40;
164
164
  return;
165
165
  }
166
166
  /** @returns {Regex} */
167
167
  get item() {
168
- return this.#item_135;
168
+ return this.#item_33;
169
169
  }
170
170
  /** @returns {number} */
171
171
  get min() {
172
- return this.#min_136;
172
+ return this.#min_34;
173
173
  }
174
174
  /** @returns {number | null} */
175
175
  get max() {
176
- return this.#max_137;
176
+ return this.#max_35;
177
177
  }
178
178
  /** @returns {boolean} */
179
179
  get reluctant() {
180
- return this.#reluctant_138;
180
+ return this.#reluctant_36;
181
181
  }
182
182
  };
183
183
  Regex.implementedBy(Repeat);
184
184
  export class Sequence {
185
185
  /** @type {Array<Regex>} */
186
- #items_147;
187
- /** @param {Array<Regex>} items_148 */
188
- constructor(items_148) {
189
- this.#items_147 = items_148;
186
+ #items_45;
187
+ /** @param {Array<Regex>} items_46 */
188
+ constructor(items_46) {
189
+ this.#items_45 = items_46;
190
190
  return;
191
191
  }
192
192
  /** @returns {Array<Regex>} */
193
193
  get items() {
194
- return this.#items_147;
194
+ return this.#items_45;
195
195
  }
196
196
  };
197
197
  Regex.implementedBy(Sequence);
198
198
  export class Group {
199
199
  /** @type {string} */
200
- #name_150;
200
+ #name_48;
201
201
  /** @type {string} */
202
- #value_151;
202
+ #value_49;
203
203
  /** @type {number} */
204
- #codePointsBegin_152;
204
+ #codePointsBegin_50;
205
205
  /**
206
- * @param {string} name_153
207
- * @param {string} value_154
208
- * @param {number} codePointsBegin_155
206
+ * @param {string} name_51
207
+ * @param {string} value_52
208
+ * @param {number} codePointsBegin_53
209
209
  */
210
- constructor(name_153, value_154, codePointsBegin_155) {
211
- this.#name_150 = name_153;
212
- this.#value_151 = value_154;
213
- this.#codePointsBegin_152 = codePointsBegin_155;
210
+ constructor(name_51, value_52, codePointsBegin_53) {
211
+ this.#name_48 = name_51;
212
+ this.#value_49 = value_52;
213
+ this.#codePointsBegin_50 = codePointsBegin_53;
214
214
  return;
215
215
  }
216
216
  /** @returns {string} */
217
217
  get name() {
218
- return this.#name_150;
218
+ return this.#name_48;
219
219
  }
220
220
  /** @returns {string} */
221
221
  get value() {
222
- return this.#value_151;
222
+ return this.#value_49;
223
223
  }
224
224
  /** @returns {number} */
225
225
  get codePointsBegin() {
226
- return this.#codePointsBegin_152;
226
+ return this.#codePointsBegin_50;
227
227
  }
228
228
  };
229
- class RegexRefs_159 {
229
+ class RegexRefs_57 {
230
230
  /** @type {CodePoints} */
231
- #codePoints_160;
231
+ #codePoints_58;
232
232
  /** @type {Group} */
233
- #group_161;
233
+ #group_59;
234
234
  /** @type {Or} */
235
- #orObject_162;
235
+ #orObject_60;
236
236
  /**
237
- * @param {CodePoints} codePoints_163
238
- * @param {Group} group_164
239
- * @param {Or} orObject_165
237
+ * @param {CodePoints} codePoints_61
238
+ * @param {Group} group_62
239
+ * @param {Or} orObject_63
240
240
  */
241
- constructor(codePoints_163, group_164, orObject_165) {
242
- let t_166;
243
- let t_167;
244
- let t_168;
245
- if (!(codePoints_163 !== void 0)) {
246
- t_166 = new CodePoints("");
247
- codePoints_163 = t_166;
241
+ constructor(codePoints_61, group_62, orObject_63) {
242
+ let t_64;
243
+ let t_65;
244
+ let t_66;
245
+ if (!(codePoints_61 !== void 0)) {
246
+ t_64 = new CodePoints("");
247
+ codePoints_61 = t_64;
248
248
  }
249
- if (!(group_164 !== void 0)) {
250
- t_167 = new Group("", "", 0);
251
- group_164 = t_167;
249
+ if (!(group_62 !== void 0)) {
250
+ t_65 = new Group("", "", 0);
251
+ group_62 = t_65;
252
252
  }
253
- if (!(orObject_165 !== void 0)) {
254
- t_168 = new Or(listify_3());
255
- orObject_165 = t_168;
253
+ if (!(orObject_63 !== void 0)) {
254
+ t_66 = new Or(listify_67());
255
+ orObject_63 = t_66;
256
256
  }
257
- this.#codePoints_160 = codePoints_163;
258
- this.#group_161 = group_164;
259
- this.#orObject_162 = orObject_165;
257
+ this.#codePoints_58 = codePoints_61;
258
+ this.#group_59 = group_62;
259
+ this.#orObject_60 = orObject_63;
260
260
  return;
261
261
  }
262
262
  /** @returns {CodePoints} */
263
263
  get codePoints() {
264
- return this.#codePoints_160;
264
+ return this.#codePoints_58;
265
265
  }
266
266
  /** @returns {Group} */
267
267
  get group() {
268
- return this.#group_161;
268
+ return this.#group_59;
269
269
  }
270
270
  /** @returns {Or} */
271
271
  get orObject() {
272
- return this.#orObject_162;
272
+ return this.#orObject_60;
273
273
  }
274
274
  }
275
275
  export class CompiledRegex {
276
276
  /** @type {Regex} */
277
- #data_172;
278
- /** @param {Regex} data_173 */
279
- constructor(data_173) {
280
- this.#data_172 = data_173;
281
- let t_174 = this.format();
282
- let t_175 = compiledRegexCompileFormatted_95(this, t_174);
283
- this.#compiled_176 = t_175;
277
+ #data_71;
278
+ /** @param {Regex} data_72 */
279
+ constructor(data_72) {
280
+ this.#data_71 = data_72;
281
+ let t_73 = this.format();
282
+ let t_74 = compiledRegexCompileFormatted_75(this, t_73);
283
+ this.#compiled_76 = t_74;
284
284
  return;
285
285
  }
286
286
  /**
287
- * @param {string} text_178
287
+ * @param {string} text_78
288
288
  * @returns {boolean}
289
289
  */
290
- found(text_178) {
291
- return compiledRegexCompiledFound_96(this, this.#compiled_176, text_178);
290
+ found(text_78) {
291
+ return compiledRegexCompiledFound_79(this, this.#compiled_76, text_78);
292
292
  }
293
293
  /**
294
- * @param {string} text_180
294
+ * @param {string} text_81
295
295
  * @returns {Map<string, Group>}
296
296
  */
297
- find(text_180) {
298
- return compiledRegexCompiledFind_97(this, this.#compiled_176, text_180, regexRefs_181);
297
+ find(text_81) {
298
+ return compiledRegexCompiledFind_82(this, this.#compiled_76, text_81, regexRefs_83);
299
299
  }
300
300
  /**
301
- * @param {string} text_183
302
- * @param {(arg0: Map<string, Group>) => string} format_184
301
+ * @param {string} text_85
302
+ * @param {(arg0: Map<string, Group>) => string} format_86
303
303
  * @returns {string}
304
304
  */
305
- replace(text_183, format_184) {
306
- return compiledRegexCompiledReplace_98(this, this.#compiled_176, text_183, format_184, regexRefs_181);
305
+ replace(text_85, format_86) {
306
+ return compiledRegexCompiledReplace_87(this, this.#compiled_76, text_85, format_86, regexRefs_83);
307
307
  }
308
308
  /** @type {unknown} */
309
- #compiled_176;
309
+ #compiled_76;
310
310
  /** @returns {string} */
311
311
  format() {
312
- return new RegexFormatter_186().format(this.#data_172);
312
+ return new RegexFormatter_89().format(this.#data_71);
313
313
  }
314
314
  /** @returns {Regex} */
315
315
  get data() {
316
- return this.#data_172;
316
+ return this.#data_71;
317
317
  }
318
318
  };
319
- class RegexFormatter_186 {
319
+ class RegexFormatter_89 {
320
320
  /** @type {Array<string>} */
321
- #out_188;
321
+ #out_91;
322
322
  /**
323
- * @param {Regex} regex_190
323
+ * @param {Regex} regex_93
324
324
  * @returns {string}
325
325
  */
326
- format(regex_190) {
327
- this.pushRegex(regex_190);
328
- let t_191 = this.#out_188;
329
- function fn_192(x_193) {
330
- return x_193;
326
+ format(regex_93) {
327
+ this.pushRegex(regex_93);
328
+ let t_94 = this.#out_91;
329
+ function fn_95(x_96) {
330
+ return x_96;
331
331
  }
332
- return listJoin_2(t_191, "", fn_192);
332
+ return listJoin_97(t_94, "", fn_95);
333
333
  }
334
- /** @param {Regex} regex_195 */
335
- pushRegex(regex_195) {
336
- let return_196;
337
- let t_197;
338
- let t_198;
339
- let t_199;
340
- let t_200;
341
- let t_201;
342
- let t_202;
343
- let t_203;
344
- let t_204;
345
- let t_205;
346
- let t_206;
347
- let t_207;
348
- let t_208;
349
- let t_209;
350
- let t_210;
334
+ /** @param {Regex} regex_99 */
335
+ pushRegex(regex_99) {
336
+ let return_100;
337
+ let t_101;
338
+ let t_102;
339
+ let t_103;
340
+ let t_104;
341
+ let t_105;
342
+ let t_106;
343
+ let t_107;
344
+ let t_108;
345
+ let t_109;
346
+ let t_110;
347
+ let t_111;
348
+ let t_112;
349
+ let t_113;
350
+ let t_114;
351
351
  try {
352
- requireInstanceOf__211(regex_195, Capture);
353
- t_197 = true;
352
+ requireInstanceOf__115(regex_99, Capture);
353
+ t_101 = true;
354
354
  } catch {
355
- t_197 = false;
355
+ t_101 = false;
356
356
  }
357
- s__1238_212: {
358
- if (t_197) {
357
+ s__1245_116: {
358
+ if (t_101) {
359
359
  try {
360
- t_198 = requireInstanceOf__211(regex_195, Capture);
360
+ t_102 = requireInstanceOf__115(regex_99, Capture);
361
361
  } catch {
362
- break s__1238_212;
362
+ break s__1245_116;
363
363
  }
364
- this.pushCapture(t_198);
364
+ this.pushCapture(t_102);
365
365
  } else {
366
366
  try {
367
- requireInstanceOf__211(regex_195, CodePoints);
368
- t_199 = true;
367
+ requireInstanceOf__115(regex_99, CodePoints);
368
+ t_103 = true;
369
369
  } catch {
370
- t_199 = false;
370
+ t_103 = false;
371
371
  }
372
- if (t_199) {
372
+ if (t_103) {
373
373
  try {
374
- t_200 = requireInstanceOf__211(regex_195, CodePoints);
374
+ t_104 = requireInstanceOf__115(regex_99, CodePoints);
375
375
  } catch {
376
- break s__1238_212;
376
+ break s__1245_116;
377
377
  }
378
- this.pushCodePoints(t_200, false);
378
+ this.pushCodePoints(t_104, false);
379
379
  } else {
380
380
  try {
381
- requireInstanceOf__211(regex_195, CodeRange);
382
- t_201 = true;
381
+ requireInstanceOf__115(regex_99, CodeRange);
382
+ t_105 = true;
383
383
  } catch {
384
- t_201 = false;
384
+ t_105 = false;
385
385
  }
386
- if (t_201) {
386
+ if (t_105) {
387
387
  try {
388
- t_202 = requireInstanceOf__211(regex_195, CodeRange);
388
+ t_106 = requireInstanceOf__115(regex_99, CodeRange);
389
389
  } catch {
390
- break s__1238_212;
390
+ break s__1245_116;
391
391
  }
392
- this.pushCodeRange(t_202);
392
+ this.pushCodeRange(t_106);
393
393
  } else {
394
394
  try {
395
- requireInstanceOf__211(regex_195, CodeSet);
396
- t_203 = true;
395
+ requireInstanceOf__115(regex_99, CodeSet);
396
+ t_107 = true;
397
397
  } catch {
398
- t_203 = false;
398
+ t_107 = false;
399
399
  }
400
- if (t_203) {
400
+ if (t_107) {
401
401
  try {
402
- t_204 = requireInstanceOf__211(regex_195, CodeSet);
402
+ t_108 = requireInstanceOf__115(regex_99, CodeSet);
403
403
  } catch {
404
- break s__1238_212;
404
+ break s__1245_116;
405
405
  }
406
- this.pushCodeSet(t_204);
406
+ this.pushCodeSet(t_108);
407
407
  } else {
408
408
  try {
409
- requireInstanceOf__211(regex_195, Or);
410
- t_205 = true;
409
+ requireInstanceOf__115(regex_99, Or);
410
+ t_109 = true;
411
411
  } catch {
412
- t_205 = false;
412
+ t_109 = false;
413
413
  }
414
- if (t_205) {
414
+ if (t_109) {
415
415
  try {
416
- t_206 = requireInstanceOf__211(regex_195, Or);
416
+ t_110 = requireInstanceOf__115(regex_99, Or);
417
417
  } catch {
418
- break s__1238_212;
418
+ break s__1245_116;
419
419
  }
420
- this.pushOr(t_206);
420
+ this.pushOr(t_110);
421
421
  } else {
422
422
  try {
423
- requireInstanceOf__211(regex_195, Repeat);
424
- t_207 = true;
423
+ requireInstanceOf__115(regex_99, Repeat);
424
+ t_111 = true;
425
425
  } catch {
426
- t_207 = false;
426
+ t_111 = false;
427
427
  }
428
- if (t_207) {
428
+ if (t_111) {
429
429
  try {
430
- t_208 = requireInstanceOf__211(regex_195, Repeat);
430
+ t_112 = requireInstanceOf__115(regex_99, Repeat);
431
431
  } catch {
432
- break s__1238_212;
432
+ break s__1245_116;
433
433
  }
434
- this.pushRepeat(t_208);
434
+ this.pushRepeat(t_112);
435
435
  } else {
436
436
  try {
437
- requireInstanceOf__211(regex_195, Sequence);
438
- t_209 = true;
437
+ requireInstanceOf__115(regex_99, Sequence);
438
+ t_113 = true;
439
439
  } catch {
440
- t_209 = false;
440
+ t_113 = false;
441
441
  }
442
- if (t_209) {
442
+ if (t_113) {
443
443
  try {
444
- t_210 = requireInstanceOf__211(regex_195, Sequence);
444
+ t_114 = requireInstanceOf__115(regex_99, Sequence);
445
445
  } catch {
446
- break s__1238_212;
446
+ break s__1245_116;
447
447
  }
448
- this.pushSequence(t_210);
449
- } else if (eqGeneric_99(regex_195, Begin)) {
448
+ this.pushSequence(t_114);
449
+ } else if (eqGeneric_117(regex_99, Begin)) {
450
450
  try {
451
- listBuilderAdd_0(this.#out_188, "^");
451
+ listBuilderAdd_118(this.#out_91, "^");
452
452
  } catch {
453
- break s__1238_212;
453
+ break s__1245_116;
454
454
  }
455
- } else if (eqGeneric_99(regex_195, Dot)) {
455
+ } else if (eqGeneric_117(regex_99, Dot)) {
456
456
  try {
457
- listBuilderAdd_0(this.#out_188, ".");
457
+ listBuilderAdd_118(this.#out_91, ".");
458
458
  } catch {
459
- break s__1238_212;
459
+ break s__1245_116;
460
460
  }
461
- } else if (eqGeneric_99(regex_195, End)) {
461
+ } else if (eqGeneric_117(regex_99, End)) {
462
462
  try {
463
- listBuilderAdd_0(this.#out_188, "\u0024");
463
+ listBuilderAdd_118(this.#out_91, "\u0024");
464
464
  } catch {
465
- break s__1238_212;
465
+ break s__1245_116;
466
466
  }
467
- } else if (eqGeneric_99(regex_195, WordBoundary)) {
467
+ } else if (eqGeneric_117(regex_99, WordBoundary)) {
468
468
  try {
469
- listBuilderAdd_0(this.#out_188, "\\b");
469
+ listBuilderAdd_118(this.#out_91, "\\b");
470
470
  } catch {
471
- break s__1238_212;
471
+ break s__1245_116;
472
472
  }
473
- } else if (eqGeneric_99(regex_195, Digit)) {
473
+ } else if (eqGeneric_117(regex_99, Digit)) {
474
474
  try {
475
- listBuilderAdd_0(this.#out_188, "\\d");
475
+ listBuilderAdd_118(this.#out_91, "\\d");
476
476
  } catch {
477
- break s__1238_212;
477
+ break s__1245_116;
478
478
  }
479
- } else if (eqGeneric_99(regex_195, Space)) {
479
+ } else if (eqGeneric_117(regex_99, Space)) {
480
480
  try {
481
- listBuilderAdd_0(this.#out_188, "\\s");
481
+ listBuilderAdd_118(this.#out_91, "\\s");
482
482
  } catch {
483
- break s__1238_212;
483
+ break s__1245_116;
484
484
  }
485
- } else if (eqGeneric_99(regex_195, Word)) {
485
+ } else if (eqGeneric_117(regex_99, Word)) {
486
486
  try {
487
- listBuilderAdd_0(this.#out_188, "\\w");
487
+ listBuilderAdd_118(this.#out_91, "\\w");
488
488
  } catch {
489
- break s__1238_212;
489
+ break s__1245_116;
490
490
  }
491
491
  } else {
492
492
  void 0;
@@ -497,330 +497,310 @@ class RegexFormatter_186 {
497
497
  }
498
498
  }
499
499
  }
500
- return_196 = void 0;
501
- return return_196;
500
+ return_100 = void 0;
501
+ return return_100;
502
502
  }
503
- throw bubbleException__213;
503
+ throw Error();
504
504
  }
505
- /** @param {Capture} capture_215 */
506
- pushCapture(capture_215) {
507
- let return_216;
508
- let t_217;
509
- let t_218;
510
- let t_219;
511
- {
512
- listBuilderAdd_0(this.#out_188, "(");
513
- t_219 = this.#out_188;
514
- t_217 = capture_215.name;
515
- this.pushCaptureName(t_219, t_217);
516
- t_218 = capture_215.item;
517
- this.pushRegex(t_218);
518
- listBuilderAdd_0(this.#out_188, ")");
519
- return_216 = void 0;
520
- }
521
- return return_216;
505
+ /** @param {Capture} capture_120 */
506
+ pushCapture(capture_120) {
507
+ listBuilderAdd_118(this.#out_91, "(");
508
+ let t_121 = this.#out_91;
509
+ let t_122 = capture_120.name;
510
+ this.pushCaptureName(t_121, t_122);
511
+ let t_123 = capture_120.item;
512
+ this.pushRegex(t_123);
513
+ listBuilderAdd_118(this.#out_91, ")");
514
+ return;
522
515
  }
523
516
  /**
524
- * @param {Array<string>} out_221
525
- * @param {string} name_222
517
+ * @param {Array<string>} out_125
518
+ * @param {string} name_126
526
519
  */
527
- pushCaptureName(out_221, name_222) {
528
- let return_223;
529
- {
530
- listBuilderAdd_0(out_221, strCat_9("?\u003c", name_222, "\u003e"));
531
- return_223 = void 0;
532
- }
533
- return return_223;
520
+ pushCaptureName(out_125, name_126) {
521
+ listBuilderAdd_118(out_125, strCat_127("?\u003c", name_126, "\u003e"));
522
+ return;
534
523
  }
535
524
  /**
536
- * @param {number} code_225
537
- * @param {boolean} insideCodeSet_226
525
+ * @param {number} code_129
526
+ * @param {boolean} insideCodeSet_130
538
527
  */
539
- pushCode(code_225, insideCodeSet_226) {
540
- regexFormatterPushCodeTo_100(this, this.#out_188, code_225, insideCodeSet_226);
528
+ pushCode(code_129, insideCodeSet_130) {
529
+ regexFormatterPushCodeTo_131(this, this.#out_91, code_129, insideCodeSet_130);
541
530
  return;
542
531
  }
543
532
  /**
544
- * @param {CodePoints} codePoints_228
545
- * @param {boolean} insideCodeSet_229
533
+ * @param {CodePoints} codePoints_133
534
+ * @param {boolean} insideCodeSet_134
546
535
  */
547
- pushCodePoints(codePoints_228, insideCodeSet_229) {
548
- let t_230;
549
- let t_231;
550
- let t_232 = stringCodePoints_74(codePoints_228.value);
551
- let slice_233 = t_232;
536
+ pushCodePoints(codePoints_133, insideCodeSet_134) {
537
+ let t_135;
538
+ let t_136;
539
+ let t_137 = stringCodePoints_138(codePoints_133.value);
540
+ let slice_139 = t_137;
552
541
  while (true) {
553
- if (! slice_233.isEmpty) {
554
- t_230 = slice_233.read();
555
- this.pushCode(t_230, insideCodeSet_229);
556
- t_231 = slice_233.advance(1);
557
- slice_233 = t_231;
542
+ if (! slice_139.isEmpty) {
543
+ t_135 = slice_139.read();
544
+ this.pushCode(t_135, insideCodeSet_134);
545
+ t_136 = slice_139.advance(1);
546
+ slice_139 = t_136;
558
547
  } else {
559
548
  break;
560
549
  }
561
550
  }
562
551
  return;
563
552
  }
564
- /** @param {CodeRange} codeRange_235 */
565
- pushCodeRange(codeRange_235) {
566
- let return_236;
567
- {
568
- listBuilderAdd_0(this.#out_188, "[");
569
- this.pushCodeRangeUnwrapped(codeRange_235);
570
- listBuilderAdd_0(this.#out_188, "]");
571
- return_236 = void 0;
572
- }
573
- return return_236;
553
+ /** @param {CodeRange} codeRange_141 */
554
+ pushCodeRange(codeRange_141) {
555
+ listBuilderAdd_118(this.#out_91, "[");
556
+ this.pushCodeRangeUnwrapped(codeRange_141);
557
+ listBuilderAdd_118(this.#out_91, "]");
558
+ return;
574
559
  }
575
- /** @param {CodeRange} codeRange_238 */
576
- pushCodeRangeUnwrapped(codeRange_238) {
577
- let return_239;
578
- let t_240;
579
- let t_241 = codeRange_238.min;
580
- this.pushCode(t_241, true);
581
- {
582
- listBuilderAdd_0(this.#out_188, "-");
583
- t_240 = codeRange_238.max;
584
- this.pushCode(t_240, true);
585
- return_239 = void 0;
586
- }
587
- return return_239;
560
+ /** @param {CodeRange} codeRange_143 */
561
+ pushCodeRangeUnwrapped(codeRange_143) {
562
+ let t_144 = codeRange_143.min;
563
+ this.pushCode(t_144, true);
564
+ listBuilderAdd_118(this.#out_91, "-");
565
+ let t_145 = codeRange_143.max;
566
+ this.pushCode(t_145, true);
567
+ return;
588
568
  }
589
- /** @param {CodeSet} codeSet_243 */
590
- pushCodeSet(codeSet_243) {
591
- let t_244;
592
- let t_245;
593
- let t_246;
594
- let t_247;
595
- const adjusted_248 = regexFormatterAdjustCodeSet_101(this, codeSet_243, regexRefs_181);
569
+ /** @param {CodeSet} codeSet_147 */
570
+ pushCodeSet(codeSet_147) {
571
+ let t_148;
572
+ let t_149;
573
+ let t_150;
574
+ let t_151;
575
+ const adjusted_152 = regexFormatterAdjustCodeSet_153(this, codeSet_147, regexRefs_83);
596
576
  try {
597
- requireInstanceOf__211(adjusted_248, CodeSet);
598
- t_245 = true;
577
+ requireInstanceOf__115(adjusted_152, CodeSet);
578
+ t_149 = true;
599
579
  } catch {
600
- t_245 = false;
580
+ t_149 = false;
601
581
  }
602
- s__1242_249: {
603
- if (t_245) {
604
- s__1243_250: {
582
+ s__1252_154: {
583
+ if (t_149) {
584
+ s__1253_155: {
605
585
  try {
606
- t_246 = requireInstanceOf__211(adjusted_248, CodeSet);
607
- listBuilderAdd_0(this.#out_188, "[");
586
+ t_150 = requireInstanceOf__115(adjusted_152, CodeSet);
587
+ listBuilderAdd_118(this.#out_91, "[");
608
588
  } catch {
609
- break s__1243_250;
589
+ break s__1253_155;
610
590
  }
611
- if (t_246.negated) {
591
+ if (t_150.negated) {
612
592
  try {
613
- listBuilderAdd_0(this.#out_188, "^");
593
+ listBuilderAdd_118(this.#out_91, "^");
614
594
  } catch {
615
- break s__1243_250;
595
+ break s__1253_155;
616
596
  }
617
597
  } else {
618
598
  void 0;
619
599
  }
620
- let i_251 = 0;
600
+ let i_156 = 0;
621
601
  while (true) {
622
- t_244 = t_246.items.length;
623
- if (ltGeneric_6(i_251, t_244)) {
602
+ t_148 = t_150.items.length;
603
+ if (i_156 < t_148) {
624
604
  try {
625
- t_247 = listGet_7(t_246.items, i_251);
605
+ t_151 = listGet_157(t_150.items, i_156);
626
606
  } catch {
627
- break s__1243_250;
607
+ break s__1253_155;
628
608
  }
629
- this.pushCodeSetItem(t_247);
630
- i_251 = i_251 + 1;
609
+ this.pushCodeSetItem(t_151);
610
+ i_156 = i_156 + 1;
631
611
  } else {
632
612
  break;
633
613
  }
634
614
  }
635
615
  try {
636
- listBuilderAdd_0(this.#out_188, "]");
637
- break s__1242_249;
616
+ listBuilderAdd_118(this.#out_91, "]");
617
+ break s__1252_154;
638
618
  } catch {
639
619
  }
640
620
  }
641
- throw bubbleException__213;
621
+ throw Error();
642
622
  }
643
- this.pushRegex(adjusted_248);
623
+ this.pushRegex(adjusted_152);
644
624
  }
645
625
  return;
646
626
  }
647
- /** @param {CodePart} codePart_253 */
648
- pushCodeSetItem(codePart_253) {
649
- let return_254;
650
- let t_255;
651
- let t_256;
652
- let t_257;
653
- let t_258;
654
- let t_259;
655
- let t_260;
627
+ /** @param {CodePart} codePart_159 */
628
+ pushCodeSetItem(codePart_159) {
629
+ let return_160;
630
+ let t_161;
631
+ let t_162;
632
+ let t_163;
633
+ let t_164;
634
+ let t_165;
635
+ let t_166;
656
636
  try {
657
- requireInstanceOf__211(codePart_253, CodePoints);
658
- t_255 = true;
637
+ requireInstanceOf__115(codePart_159, CodePoints);
638
+ t_161 = true;
659
639
  } catch {
660
- t_255 = false;
640
+ t_161 = false;
661
641
  }
662
- s__1247_261: {
663
- if (t_255) {
642
+ s__1259_167: {
643
+ if (t_161) {
664
644
  try {
665
- t_256 = requireInstanceOf__211(codePart_253, CodePoints);
645
+ t_162 = requireInstanceOf__115(codePart_159, CodePoints);
666
646
  } catch {
667
- break s__1247_261;
647
+ break s__1259_167;
668
648
  }
669
- this.pushCodePoints(t_256, true);
649
+ this.pushCodePoints(t_162, true);
670
650
  } else {
671
651
  try {
672
- requireInstanceOf__211(codePart_253, CodeRange);
673
- t_257 = true;
652
+ requireInstanceOf__115(codePart_159, CodeRange);
653
+ t_163 = true;
674
654
  } catch {
675
- t_257 = false;
655
+ t_163 = false;
676
656
  }
677
- if (t_257) {
657
+ if (t_163) {
678
658
  try {
679
- t_258 = requireInstanceOf__211(codePart_253, CodeRange);
659
+ t_164 = requireInstanceOf__115(codePart_159, CodeRange);
680
660
  } catch {
681
- break s__1247_261;
661
+ break s__1259_167;
682
662
  }
683
- this.pushCodeRangeUnwrapped(t_258);
663
+ this.pushCodeRangeUnwrapped(t_164);
684
664
  } else {
685
665
  try {
686
- requireInstanceOf__211(codePart_253, SpecialSet);
687
- t_259 = true;
666
+ requireInstanceOf__115(codePart_159, SpecialSet);
667
+ t_165 = true;
688
668
  } catch {
689
- t_259 = false;
669
+ t_165 = false;
690
670
  }
691
- if (t_259) {
671
+ if (t_165) {
692
672
  try {
693
- t_260 = requireInstanceOf__211(codePart_253, SpecialSet);
673
+ t_166 = requireInstanceOf__115(codePart_159, SpecialSet);
694
674
  } catch {
695
- break s__1247_261;
675
+ break s__1259_167;
696
676
  }
697
- this.pushRegex(t_260);
677
+ this.pushRegex(t_166);
698
678
  } else {
699
679
  void 0;
700
680
  }
701
681
  }
702
682
  }
703
- return_254 = void 0;
704
- return return_254;
683
+ return_160 = void 0;
684
+ return return_160;
705
685
  }
706
- throw bubbleException__213;
686
+ throw Error();
707
687
  }
708
- /** @param {Or} or_263 */
709
- pushOr(or_263) {
710
- let t_264;
711
- let t_265;
712
- let t_266;
713
- s__1249_267: if (! ! or_263.items.length) {
714
- s__1250_268: {
688
+ /** @param {Or} or_169 */
689
+ pushOr(or_169) {
690
+ let t_170;
691
+ let t_171;
692
+ let t_172;
693
+ s__1261_173: if (! ! or_169.items.length) {
694
+ s__1262_174: {
715
695
  try {
716
- listBuilderAdd_0(this.#out_188, "(?:");
717
- t_265 = listGet_7(or_263.items, 0);
696
+ listBuilderAdd_118(this.#out_91, "(?:");
697
+ t_171 = listGet_157(or_169.items, 0);
718
698
  } catch {
719
- break s__1250_268;
699
+ break s__1262_174;
720
700
  }
721
- this.pushRegex(t_265);
722
- let i_269 = 1;
701
+ this.pushRegex(t_171);
702
+ let i_175 = 1;
723
703
  while (true) {
724
- t_264 = or_263.items.length;
725
- if (ltGeneric_6(i_269, t_264)) {
704
+ t_170 = or_169.items.length;
705
+ if (i_175 < t_170) {
726
706
  try {
727
- listBuilderAdd_0(this.#out_188, "|");
728
- t_266 = listGet_7(or_263.items, i_269);
707
+ listBuilderAdd_118(this.#out_91, "|");
708
+ t_172 = listGet_157(or_169.items, i_175);
729
709
  } catch {
730
710
  break;
731
711
  }
732
- this.pushRegex(t_266);
733
- i_269 = i_269 + 1;
712
+ this.pushRegex(t_172);
713
+ i_175 = i_175 + 1;
734
714
  } else {
735
715
  try {
736
- listBuilderAdd_0(this.#out_188, ")");
716
+ listBuilderAdd_118(this.#out_91, ")");
737
717
  } catch {
738
- break s__1250_268;
718
+ break s__1262_174;
739
719
  }
740
- break s__1249_267;
720
+ break s__1261_173;
741
721
  }
742
722
  }
743
723
  }
744
- throw bubbleException__213;
724
+ throw Error();
745
725
  }
746
726
  return;
747
727
  }
748
- /** @param {Repeat} repeat_271 */
749
- pushRepeat(repeat_271) {
750
- let return_272;
751
- let t_273;
752
- let t_274;
753
- let t_275;
754
- let t_276;
755
- let t_277;
756
- let t_278;
757
- s__1253_279: {
758
- let min_280;
759
- let max_281;
728
+ /** @param {Repeat} repeat_177 */
729
+ pushRepeat(repeat_177) {
730
+ let return_178;
731
+ let t_179;
732
+ let t_180;
733
+ let t_181;
734
+ let t_182;
735
+ let t_183;
736
+ let t_184;
737
+ s__1266_185: {
738
+ let min_186;
739
+ let max_187;
760
740
  try {
761
- listBuilderAdd_0(this.#out_188, "(?:");
762
- t_273 = repeat_271.item;
763
- this.pushRegex(t_273);
764
- listBuilderAdd_0(this.#out_188, ")");
765
- min_280 = repeat_271.min;
766
- max_281 = repeat_271.max;
741
+ listBuilderAdd_118(this.#out_91, "(?:");
742
+ t_179 = repeat_177.item;
743
+ this.pushRegex(t_179);
744
+ listBuilderAdd_118(this.#out_91, ")");
745
+ min_186 = repeat_177.min;
746
+ max_187 = repeat_177.max;
767
747
  } catch {
768
- break s__1253_279;
748
+ break s__1266_185;
769
749
  }
770
- if (eqGeneric_70(min_280, 0)) {
771
- t_274 = eqGeneric_70(max_281, 1);
750
+ if (min_186 === 0) {
751
+ t_180 = max_187 === 1;
772
752
  } else {
773
- t_274 = false;
753
+ t_180 = false;
774
754
  }
775
- if (t_274) {
755
+ if (t_180) {
776
756
  try {
777
- listBuilderAdd_0(this.#out_188, "?");
757
+ listBuilderAdd_118(this.#out_91, "?");
778
758
  } catch {
779
- break s__1253_279;
759
+ break s__1266_185;
780
760
  }
781
761
  } else {
782
- if (eqGeneric_70(min_280, 0)) {
783
- t_275 = eqGeneric_70(max_281, null);
762
+ if (min_186 === 0) {
763
+ t_181 = max_187 === null;
784
764
  } else {
785
- t_275 = false;
765
+ t_181 = false;
786
766
  }
787
- if (t_275) {
767
+ if (t_181) {
788
768
  try {
789
- listBuilderAdd_0(this.#out_188, "*");
769
+ listBuilderAdd_118(this.#out_91, "*");
790
770
  } catch {
791
- break s__1253_279;
771
+ break s__1266_185;
792
772
  }
793
773
  } else {
794
- if (eqGeneric_70(min_280, 1)) {
795
- t_276 = eqGeneric_70(max_281, null);
774
+ if (min_186 === 1) {
775
+ t_182 = max_187 === null;
796
776
  } else {
797
- t_276 = false;
777
+ t_182 = false;
798
778
  }
799
- if (t_276) {
779
+ if (t_182) {
800
780
  try {
801
- listBuilderAdd_0(this.#out_188, "+");
781
+ listBuilderAdd_118(this.#out_91, "+");
802
782
  } catch {
803
- break s__1253_279;
783
+ break s__1266_185;
804
784
  }
805
785
  } else {
806
786
  try {
807
- listBuilderAdd_0(this.#out_188, strCat_9("{", intToString_73(min_280)));
787
+ listBuilderAdd_118(this.#out_91, strCat_127("{", intToString_188(min_186)));
808
788
  } catch {
809
- break s__1253_279;
789
+ break s__1266_185;
810
790
  }
811
- if (neGeneric_72(min_280, max_281)) {
791
+ if (min_186 !== max_187) {
812
792
  try {
813
- listBuilderAdd_0(this.#out_188, ",");
793
+ listBuilderAdd_118(this.#out_91, ",");
814
794
  } catch {
815
- break s__1253_279;
795
+ break s__1266_185;
816
796
  }
817
- if (neGeneric_72(max_281, null)) {
818
- t_278 = this.#out_188;
797
+ if (max_187 !== null) {
798
+ t_184 = this.#out_91;
819
799
  try {
820
- t_277 = requireIsSafeInteger__282(max_281);
821
- listBuilderAdd_0(t_278, intToString_73(t_277));
800
+ t_183 = requireIsSafeInteger__189(max_187);
801
+ listBuilderAdd_118(t_184, intToString_188(t_183));
822
802
  } catch {
823
- break s__1253_279;
803
+ break s__1266_185;
824
804
  }
825
805
  } else {
826
806
  void 0;
@@ -829,244 +809,244 @@ class RegexFormatter_186 {
829
809
  void 0;
830
810
  }
831
811
  try {
832
- listBuilderAdd_0(this.#out_188, "}");
812
+ listBuilderAdd_118(this.#out_91, "}");
833
813
  } catch {
834
- break s__1253_279;
814
+ break s__1266_185;
835
815
  }
836
816
  }
837
817
  }
838
818
  }
839
- if (repeat_271.reluctant) {
819
+ if (repeat_177.reluctant) {
840
820
  try {
841
- listBuilderAdd_0(this.#out_188, "?");
821
+ listBuilderAdd_118(this.#out_91, "?");
842
822
  } catch {
843
- break s__1253_279;
823
+ break s__1266_185;
844
824
  }
845
825
  } else {
846
826
  void 0;
847
827
  }
848
- return_272 = void 0;
849
- return return_272;
828
+ return_178 = void 0;
829
+ return return_178;
850
830
  }
851
- throw bubbleException__213;
831
+ throw Error();
852
832
  }
853
- /** @param {Sequence} sequence_284 */
854
- pushSequence(sequence_284) {
855
- let return_285;
856
- let t_286;
857
- let t_287;
858
- let i_288 = 0;
859
- s__1255_289: {
833
+ /** @param {Sequence} sequence_191 */
834
+ pushSequence(sequence_191) {
835
+ let return_192;
836
+ let t_193;
837
+ let t_194;
838
+ let i_195 = 0;
839
+ s__1269_196: {
860
840
  while (true) {
861
- t_286 = sequence_284.items.length;
862
- if (ltGeneric_6(i_288, t_286)) {
841
+ t_193 = sequence_191.items.length;
842
+ if (i_195 < t_193) {
863
843
  try {
864
- t_287 = listGet_7(sequence_284.items, i_288);
844
+ t_194 = listGet_157(sequence_191.items, i_195);
865
845
  } catch {
866
846
  break;
867
847
  }
868
- this.pushRegex(t_287);
869
- i_288 = i_288 + 1;
848
+ this.pushRegex(t_194);
849
+ i_195 = i_195 + 1;
870
850
  } else {
871
- return_285 = void 0;
872
- break s__1255_289;
851
+ return_192 = void 0;
852
+ break s__1269_196;
873
853
  }
874
854
  }
875
- throw bubbleException__213;
855
+ throw Error();
876
856
  }
877
- return return_285;
857
+ return return_192;
878
858
  }
879
859
  /**
880
- * @param {CodePart} codePart_291
860
+ * @param {CodePart} codePart_198
881
861
  * @returns {number | null}
882
862
  */
883
- maxCode(codePart_291) {
884
- let return_292;
885
- let t_293;
886
- let t_294;
887
- let t_295;
888
- let t_296;
889
- let t_297;
890
- let t_298;
891
- let t_299;
892
- let t_300;
893
- let t_301;
894
- let t_302;
863
+ maxCode(codePart_198) {
864
+ let return_199;
865
+ let t_200;
866
+ let t_201;
867
+ let t_202;
868
+ let t_203;
869
+ let t_204;
870
+ let t_205;
871
+ let t_206;
872
+ let t_207;
873
+ let t_208;
874
+ let t_209;
895
875
  try {
896
- requireInstanceOf__211(codePart_291, CodePoints);
897
- t_299 = true;
876
+ requireInstanceOf__115(codePart_198, CodePoints);
877
+ t_206 = true;
898
878
  } catch {
899
- t_299 = false;
879
+ t_206 = false;
900
880
  }
901
- s__1257_303: {
902
- if (t_299) {
881
+ s__1271_210: {
882
+ if (t_206) {
903
883
  try {
904
- t_300 = requireInstanceOf__211(codePart_291, CodePoints);
884
+ t_207 = requireInstanceOf__115(codePart_198, CodePoints);
905
885
  } catch {
906
- break s__1257_303;
886
+ break s__1271_210;
907
887
  }
908
- const value_304 = t_300.value;
909
- if (! value_304) {
910
- return_292 = null;
888
+ const value_211 = t_207.value;
889
+ if (! value_211) {
890
+ return_199 = null;
911
891
  } else {
912
- let max_305 = 0;
913
- t_293 = stringCodePoints_74(value_304);
914
- let slice_306 = t_293;
892
+ let max_212 = 0;
893
+ t_200 = stringCodePoints_138(value_211);
894
+ let slice_213 = t_200;
915
895
  while (true) {
916
- if (! slice_306.isEmpty) {
917
- const next_307 = slice_306.read();
918
- if (gtGeneric_102(next_307, max_305)) {
919
- max_305 = next_307;
896
+ if (! slice_213.isEmpty) {
897
+ const next_214 = slice_213.read();
898
+ if (next_214 > max_212) {
899
+ max_212 = next_214;
920
900
  } else {
921
901
  void 0;
922
902
  }
923
- t_294 = slice_306.advance(1);
924
- slice_306 = t_294;
903
+ t_201 = slice_213.advance(1);
904
+ slice_213 = t_201;
925
905
  } else {
926
906
  break;
927
907
  }
928
908
  }
929
- return_292 = max_305;
909
+ return_199 = max_212;
930
910
  }
931
911
  } else {
932
912
  try {
933
- requireInstanceOf__211(codePart_291, CodeRange);
934
- t_301 = true;
913
+ requireInstanceOf__115(codePart_198, CodeRange);
914
+ t_208 = true;
935
915
  } catch {
936
- t_301 = false;
916
+ t_208 = false;
937
917
  }
938
- if (t_301) {
918
+ if (t_208) {
939
919
  try {
940
- t_302 = requireInstanceOf__211(codePart_291, CodeRange);
941
- t_295 = t_302.max;
942
- return_292 = t_295;
920
+ t_209 = requireInstanceOf__115(codePart_198, CodeRange);
921
+ t_202 = t_209.max;
922
+ return_199 = t_202;
943
923
  } catch {
944
- break s__1257_303;
924
+ break s__1271_210;
945
925
  }
946
- } else if (eqGeneric_99(codePart_291, Digit)) {
947
- t_296 = stringCodePoints_74("9").read();
926
+ } else if (eqGeneric_117(codePart_198, Digit)) {
927
+ t_203 = stringCodePoints_138("9").read();
948
928
  try {
949
- return_292 = t_296;
929
+ return_199 = t_203;
950
930
  } catch {
951
- break s__1257_303;
931
+ break s__1271_210;
952
932
  }
953
- } else if (eqGeneric_99(codePart_291, Space)) {
954
- t_297 = stringCodePoints_74(" ").read();
933
+ } else if (eqGeneric_117(codePart_198, Space)) {
934
+ t_204 = stringCodePoints_138(" ").read();
955
935
  try {
956
- return_292 = t_297;
936
+ return_199 = t_204;
957
937
  } catch {
958
- break s__1257_303;
938
+ break s__1271_210;
959
939
  }
960
- } else if (eqGeneric_99(codePart_291, Word)) {
961
- t_298 = stringCodePoints_74("z").read();
940
+ } else if (eqGeneric_117(codePart_198, Word)) {
941
+ t_205 = stringCodePoints_138("z").read();
962
942
  try {
963
- return_292 = t_298;
943
+ return_199 = t_205;
964
944
  } catch {
965
- break s__1257_303;
945
+ break s__1271_210;
966
946
  }
967
947
  } else {
968
- return_292 = null;
948
+ return_199 = null;
969
949
  }
970
950
  }
971
- return return_292;
951
+ return return_199;
972
952
  }
973
- throw bubbleException__213;
953
+ throw Error();
974
954
  }
975
- /** @param {Array<string>} out_308 */
976
- constructor(out_308) {
977
- let t_309;
978
- if (!(out_308 !== void 0)) {
979
- t_309 = [];
980
- out_308 = t_309;
955
+ /** @param {Array<string>} out_215 */
956
+ constructor(out_215) {
957
+ let t_216;
958
+ if (!(out_215 !== void 0)) {
959
+ t_216 = [];
960
+ out_215 = t_216;
981
961
  }
982
- this.#out_188 = out_308;
962
+ this.#out_91 = out_215;
983
963
  return;
984
964
  }
985
965
  }
986
- class Begin_310 {
966
+ /** @type {RegexRefs_57} */
967
+ const regexRefs_83 = new RegexRefs_57();
968
+ class Begin_217 {
987
969
  constructor() {
988
970
  return;
989
971
  }
990
972
  }
991
- Special.implementedBy(Begin_310);
992
- /** @type {Begin_310} */
993
- export const Begin = new Begin_310();
994
- class Dot_311 {
973
+ Special.implementedBy(Begin_217);
974
+ /** @type {Special} */
975
+ export const Begin = new Begin_217();
976
+ class Dot_218 {
995
977
  constructor() {
996
978
  return;
997
979
  }
998
980
  }
999
- Special.implementedBy(Dot_311);
1000
- /** @type {Dot_311} */
1001
- export const Dot = new Dot_311();
1002
- class End_312 {
981
+ Special.implementedBy(Dot_218);
982
+ /** @type {Special} */
983
+ export const Dot = new Dot_218();
984
+ class End_219 {
1003
985
  constructor() {
1004
986
  return;
1005
987
  }
1006
988
  }
1007
- Special.implementedBy(End_312);
1008
- /** @type {End_312} */
1009
- export const End = new End_312();
1010
- class WordBoundary_313 {
989
+ Special.implementedBy(End_219);
990
+ /** @type {Special} */
991
+ export const End = new End_219();
992
+ class WordBoundary_220 {
1011
993
  constructor() {
1012
994
  return;
1013
995
  }
1014
996
  }
1015
- Special.implementedBy(WordBoundary_313);
1016
- /** @type {WordBoundary_313} */
1017
- export const WordBoundary = new WordBoundary_313();
1018
- class Digit_314 {
997
+ Special.implementedBy(WordBoundary_220);
998
+ /** @type {Special} */
999
+ export const WordBoundary = new WordBoundary_220();
1000
+ class Digit_221 {
1019
1001
  constructor() {
1020
1002
  return;
1021
1003
  }
1022
1004
  }
1023
- SpecialSet.implementedBy(Digit_314);
1024
- /** @type {Digit_314} */
1025
- export const Digit = new Digit_314();
1026
- class Space_315 {
1005
+ SpecialSet.implementedBy(Digit_221);
1006
+ /** @type {SpecialSet} */
1007
+ export const Digit = new Digit_221();
1008
+ class Space_222 {
1027
1009
  constructor() {
1028
1010
  return;
1029
1011
  }
1030
1012
  }
1031
- SpecialSet.implementedBy(Space_315);
1032
- /** @type {Space_315} */
1033
- export const Space = new Space_315();
1034
- class Word_316 {
1013
+ SpecialSet.implementedBy(Space_222);
1014
+ /** @type {SpecialSet} */
1015
+ export const Space = new Space_222();
1016
+ class Word_223 {
1035
1017
  constructor() {
1036
1018
  return;
1037
1019
  }
1038
1020
  }
1039
- SpecialSet.implementedBy(Word_316);
1040
- /** @type {Word_316} */
1041
- export const Word = new Word_316();
1021
+ SpecialSet.implementedBy(Word_223);
1022
+ /** @type {SpecialSet} */
1023
+ export const Word = new Word_223();
1042
1024
  /**
1043
- * @param {Regex} item_317
1025
+ * @param {Regex} item_224
1044
1026
  * @returns {Regex}
1045
1027
  */
1046
- export function entire(item_317) {
1047
- return new Sequence(listify_3(Begin, item_317, End));
1028
+ export function entire(item_224) {
1029
+ return new Sequence(listify_67(Begin, item_224, End));
1048
1030
  };
1049
1031
  /**
1050
- * @param {Regex} item_318
1051
- * @param {boolean} reluctant_319
1032
+ * @param {Regex} item_225
1033
+ * @param {boolean} reluctant_226
1052
1034
  * @returns {Repeat}
1053
1035
  */
1054
- export function oneOrMore(item_318, reluctant_319) {
1055
- if (!(reluctant_319 !== void 0)) {
1056
- reluctant_319 = false;
1036
+ export function oneOrMore(item_225, reluctant_226) {
1037
+ if (!(reluctant_226 !== void 0)) {
1038
+ reluctant_226 = false;
1057
1039
  }
1058
- return new Repeat(item_318, 1, null, reluctant_319);
1040
+ return new Repeat(item_225, 1, null, reluctant_226);
1059
1041
  };
1060
1042
  /**
1061
- * @param {Regex} item_320
1062
- * @param {boolean} reluctant_321
1043
+ * @param {Regex} item_227
1044
+ * @param {boolean} reluctant_228
1063
1045
  * @returns {Repeat}
1064
1046
  */
1065
- export function optional(item_320, reluctant_321) {
1066
- if (!(reluctant_321 !== void 0)) {
1067
- reluctant_321 = false;
1047
+ export function optional(item_227, reluctant_228) {
1048
+ if (!(reluctant_228 !== void 0)) {
1049
+ reluctant_228 = false;
1068
1050
  }
1069
- return new Repeat(item_320, 0, 1, reluctant_321);
1051
+ return new Repeat(item_227, 0, 1, reluctant_228);
1070
1052
  };
1071
- /** @type {RegexRefs_159} */
1072
- const regexRefs_181 = new RegexRefs_159();