purus 0.3.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README-ja.md +14 -0
- package/README.md +14 -0
- package/bin/purus.js +9 -5
- package/lib/build-wrapper.js +14 -17
- package/lib/check-wrapper.js +97 -0
- package/lib/create.js +4 -1
- package/lib/purus-compiler.js +1365 -932
- package/lib/run-wrapper.js +12 -15
- package/package.json +4 -4
package/lib/purus-compiler.js
CHANGED
|
@@ -155,89 +155,93 @@ const $64$username$47$core$46$TokenKind$Mul = { $tag: 13, $name: "Mul" };
|
|
|
155
155
|
const $64$username$47$core$46$TokenKind$Div = { $tag: 14, $name: "Div" };
|
|
156
156
|
const $64$username$47$core$46$TokenKind$Mod = { $tag: 15, $name: "Mod" };
|
|
157
157
|
const $64$username$47$core$46$TokenKind$Neg = { $tag: 16, $name: "Neg" };
|
|
158
|
-
const $64$username$47$core$46$TokenKind$
|
|
159
|
-
const $64$username$47$core$46$TokenKind$
|
|
160
|
-
const $64$username$47$core$46$TokenKind$
|
|
161
|
-
const $64$username$47$core$46$TokenKind$
|
|
162
|
-
const $64$username$47$core$46$TokenKind$
|
|
163
|
-
const $64$username$47$core$46$TokenKind$
|
|
164
|
-
const $64$username$47$core$46$TokenKind$
|
|
165
|
-
const $64$username$47$core$46$TokenKind$
|
|
166
|
-
const $64$username$47$core$46$TokenKind$
|
|
167
|
-
const $64$username$47$core$46$TokenKind$
|
|
168
|
-
const $64$username$47$core$46$TokenKind$
|
|
169
|
-
const $64$username$47$core$46$TokenKind$
|
|
170
|
-
const $64$username$47$core$46$TokenKind$
|
|
171
|
-
const $64$username$47$core$46$TokenKind$
|
|
172
|
-
const $64$username$47$core$46$TokenKind$
|
|
173
|
-
const $64$username$47$core$46$TokenKind$
|
|
174
|
-
const $64$username$47$core$46$TokenKind$
|
|
175
|
-
const $64$username$47$core$46$TokenKind$
|
|
176
|
-
const $64$username$47$core$46$TokenKind$
|
|
177
|
-
const $64$username$47$core$46$TokenKind$
|
|
178
|
-
const $64$username$47$core$46$TokenKind$
|
|
179
|
-
const $64$username$47$core$46$TokenKind$
|
|
180
|
-
const $64$username$47$core$46$TokenKind$
|
|
181
|
-
const $64$username$47$core$46$TokenKind$
|
|
182
|
-
const $64$username$47$core$46$TokenKind$
|
|
183
|
-
const $64$username$47$core$46$TokenKind$
|
|
184
|
-
const $64$username$47$core$46$TokenKind$
|
|
185
|
-
const $64$username$47$core$46$TokenKind$
|
|
186
|
-
const $64$username$47$core$46$TokenKind$
|
|
187
|
-
const $64$username$47$core$46$TokenKind$
|
|
188
|
-
const $64$username$47$core$46$TokenKind$
|
|
189
|
-
const $64$username$47$core$46$TokenKind$
|
|
190
|
-
const $64$username$47$core$46$TokenKind$
|
|
191
|
-
const $64$username$47$core$46$TokenKind$
|
|
192
|
-
const $64$username$47$core$46$TokenKind$
|
|
193
|
-
const $64$username$47$core$46$TokenKind$
|
|
194
|
-
const $64$username$47$core$46$TokenKind$
|
|
195
|
-
const $64$username$47$core$46$TokenKind$
|
|
196
|
-
const $64$username$47$core$46$TokenKind$
|
|
197
|
-
const $64$username$47$core$46$TokenKind$
|
|
198
|
-
const $64$username$47$core$46$TokenKind$
|
|
199
|
-
const $64$username$47$core$46$TokenKind$
|
|
200
|
-
const $64$username$47$core$46$TokenKind$
|
|
201
|
-
const $64$username$47$core$46$TokenKind$
|
|
202
|
-
const $64$username$47$core$46$TokenKind$
|
|
203
|
-
const $64$username$47$core$46$TokenKind$
|
|
204
|
-
const $64$username$47$core$46$TokenKind$
|
|
205
|
-
const $64$username$47$core$46$TokenKind$
|
|
206
|
-
const $64$username$47$core$46$TokenKind$
|
|
207
|
-
const $64$username$47$core$46$TokenKind$
|
|
208
|
-
const $64$username$47$core$46$TokenKind$
|
|
209
|
-
const $64$username$47$core$46$TokenKind$
|
|
210
|
-
const $64$username$47$core$46$TokenKind$
|
|
211
|
-
const $64$username$47$core$46$TokenKind$
|
|
212
|
-
const $64$username$47$core$46$TokenKind$
|
|
213
|
-
const $64$username$47$core$46$TokenKind$
|
|
214
|
-
const $64$username$47$core$46$TokenKind$
|
|
215
|
-
const $64$username$47$core$46$TokenKind$
|
|
216
|
-
const $64$username$47$core$46$TokenKind$
|
|
217
|
-
const $64$username$47$core$46$TokenKind$
|
|
218
|
-
const $64$username$47$core$46$TokenKind$
|
|
219
|
-
const $64$username$47$core$46$TokenKind$
|
|
158
|
+
const $64$username$47$core$46$TokenKind$Pow = { $tag: 17, $name: "Pow" };
|
|
159
|
+
const $64$username$47$core$46$TokenKind$Eq = { $tag: 18, $name: "Eq" };
|
|
160
|
+
const $64$username$47$core$46$TokenKind$Neq = { $tag: 19, $name: "Neq" };
|
|
161
|
+
const $64$username$47$core$46$TokenKind$Lt = { $tag: 20, $name: "Lt" };
|
|
162
|
+
const $64$username$47$core$46$TokenKind$Gt = { $tag: 21, $name: "Gt" };
|
|
163
|
+
const $64$username$47$core$46$TokenKind$Le = { $tag: 22, $name: "Le" };
|
|
164
|
+
const $64$username$47$core$46$TokenKind$Ge = { $tag: 23, $name: "Ge" };
|
|
165
|
+
const $64$username$47$core$46$TokenKind$And = { $tag: 24, $name: "And" };
|
|
166
|
+
const $64$username$47$core$46$TokenKind$Or = { $tag: 25, $name: "Or" };
|
|
167
|
+
const $64$username$47$core$46$TokenKind$Not = { $tag: 26, $name: "Not" };
|
|
168
|
+
const $64$username$47$core$46$TokenKind$Fn = { $tag: 27, $name: "Fn" };
|
|
169
|
+
const $64$username$47$core$46$TokenKind$Return_ = { $tag: 28, $name: "Return_" };
|
|
170
|
+
const $64$username$47$core$46$TokenKind$To = { $tag: 29, $name: "To" };
|
|
171
|
+
const $64$username$47$core$46$TokenKind$If_ = { $tag: 30, $name: "If_" };
|
|
172
|
+
const $64$username$47$core$46$TokenKind$Elif = { $tag: 31, $name: "Elif" };
|
|
173
|
+
const $64$username$47$core$46$TokenKind$Else_ = { $tag: 32, $name: "Else_" };
|
|
174
|
+
const $64$username$47$core$46$TokenKind$Unless = { $tag: 33, $name: "Unless" };
|
|
175
|
+
const $64$username$47$core$46$TokenKind$Then_ = { $tag: 34, $name: "Then_" };
|
|
176
|
+
const $64$username$47$core$46$TokenKind$While_ = { $tag: 35, $name: "While_" };
|
|
177
|
+
const $64$username$47$core$46$TokenKind$Until = { $tag: 36, $name: "Until" };
|
|
178
|
+
const $64$username$47$core$46$TokenKind$For_ = { $tag: 37, $name: "For_" };
|
|
179
|
+
const $64$username$47$core$46$TokenKind$In_ = { $tag: 38, $name: "In_" };
|
|
180
|
+
const $64$username$47$core$46$TokenKind$Range_ = { $tag: 39, $name: "Range_" };
|
|
181
|
+
const $64$username$47$core$46$TokenKind$Break_ = { $tag: 40, $name: "Break_" };
|
|
182
|
+
const $64$username$47$core$46$TokenKind$Continue_ = { $tag: 41, $name: "Continue_" };
|
|
183
|
+
const $64$username$47$core$46$TokenKind$Match_ = { $tag: 42, $name: "Match_" };
|
|
184
|
+
const $64$username$47$core$46$TokenKind$When_ = { $tag: 43, $name: "When_" };
|
|
185
|
+
const $64$username$47$core$46$TokenKind$Pipe_ = { $tag: 44, $name: "Pipe_" };
|
|
186
|
+
const $64$username$47$core$46$TokenKind$Is = { $tag: 45, $name: "Is" };
|
|
187
|
+
const $64$username$47$core$46$TokenKind$As = { $tag: 46, $name: "As" };
|
|
188
|
+
const $64$username$47$core$46$TokenKind$Of = { $tag: 47, $name: "Of" };
|
|
189
|
+
const $64$username$47$core$46$TokenKind$Gives = { $tag: 48, $name: "Gives" };
|
|
190
|
+
const $64$username$47$core$46$TokenKind$Typeof_ = { $tag: 49, $name: "Typeof_" };
|
|
191
|
+
const $64$username$47$core$46$TokenKind$Instanceof_ = { $tag: 50, $name: "Instanceof_" };
|
|
192
|
+
const $64$username$47$core$46$TokenKind$New_ = { $tag: 51, $name: "New_" };
|
|
193
|
+
const $64$username$47$core$46$TokenKind$Delete_ = { $tag: 52, $name: "Delete_" };
|
|
194
|
+
const $64$username$47$core$46$TokenKind$This_ = { $tag: 53, $name: "This_" };
|
|
195
|
+
const $64$username$47$core$46$TokenKind$Async_ = { $tag: 54, $name: "Async_" };
|
|
196
|
+
const $64$username$47$core$46$TokenKind$Await_ = { $tag: 55, $name: "Await_" };
|
|
197
|
+
const $64$username$47$core$46$TokenKind$Try_ = { $tag: 56, $name: "Try_" };
|
|
198
|
+
const $64$username$47$core$46$TokenKind$Catch_ = { $tag: 57, $name: "Catch_" };
|
|
199
|
+
const $64$username$47$core$46$TokenKind$Finally_ = { $tag: 58, $name: "Finally_" };
|
|
200
|
+
const $64$username$47$core$46$TokenKind$Throw_ = { $tag: 59, $name: "Throw_" };
|
|
201
|
+
const $64$username$47$core$46$TokenKind$Import_ = { $tag: 60, $name: "Import_" };
|
|
202
|
+
const $64$username$47$core$46$TokenKind$From_ = { $tag: 61, $name: "From_" };
|
|
203
|
+
const $64$username$47$core$46$TokenKind$Export_ = { $tag: 62, $name: "Export_" };
|
|
204
|
+
const $64$username$47$core$46$TokenKind$Default_ = { $tag: 63, $name: "Default_" };
|
|
205
|
+
const $64$username$47$core$46$TokenKind$Require_ = { $tag: 64, $name: "Require_" };
|
|
206
|
+
const $64$username$47$core$46$TokenKind$Use_ = { $tag: 65, $name: "Use_" };
|
|
207
|
+
const $64$username$47$core$46$TokenKind$Mod_ = { $tag: 66, $name: "Mod_" };
|
|
208
|
+
const $64$username$47$core$46$TokenKind$Pub_ = { $tag: 67, $name: "Pub_" };
|
|
209
|
+
const $64$username$47$core$46$TokenKind$All_ = { $tag: 68, $name: "All_" };
|
|
210
|
+
const $64$username$47$core$46$TokenKind$Type_ = { $tag: 69, $name: "Type_" };
|
|
211
|
+
const $64$username$47$core$46$TokenKind$Null_ = { $tag: 70, $name: "Null_" };
|
|
212
|
+
const $64$username$47$core$46$TokenKind$Nil_ = { $tag: 71, $name: "Nil_" };
|
|
213
|
+
const $64$username$47$core$46$TokenKind$Undefined_ = { $tag: 72, $name: "Undefined_" };
|
|
214
|
+
const $64$username$47$core$46$TokenKind$List_ = { $tag: 73, $name: "List_" };
|
|
215
|
+
const $64$username$47$core$46$TokenKind$Object_ = { $tag: 74, $name: "Object_" };
|
|
216
|
+
const $64$username$47$core$46$TokenKind$LBracket = { $tag: 75, $name: "LBracket" };
|
|
217
|
+
const $64$username$47$core$46$TokenKind$RBracket = { $tag: 76, $name: "RBracket" };
|
|
218
|
+
const $64$username$47$core$46$TokenKind$Comma = { $tag: 77, $name: "Comma" };
|
|
219
|
+
const $64$username$47$core$46$TokenKind$Semicolon = { $tag: 78, $name: "Semicolon" };
|
|
220
|
+
const $64$username$47$core$46$TokenKind$Dot = { $tag: 79, $name: "Dot" };
|
|
221
|
+
const $64$username$47$core$46$TokenKind$DotDot = { $tag: 80, $name: "DotDot" };
|
|
222
|
+
const $64$username$47$core$46$TokenKind$DotDotDot = { $tag: 81, $name: "DotDotDot" };
|
|
223
|
+
const $64$username$47$core$46$TokenKind$Newline = { $tag: 82, $name: "Newline" };
|
|
220
224
|
function $64$username$47$core$46$TokenKind$Indent(param0) {
|
|
221
225
|
this._0 = param0;
|
|
222
226
|
}
|
|
223
|
-
$64$username$47$core$46$TokenKind$Indent.prototype.$tag =
|
|
227
|
+
$64$username$47$core$46$TokenKind$Indent.prototype.$tag = 83;
|
|
224
228
|
$64$username$47$core$46$TokenKind$Indent.prototype.$name = "Indent";
|
|
225
229
|
function $64$username$47$core$46$TokenKind$Shebang(param0) {
|
|
226
230
|
this._0 = param0;
|
|
227
231
|
}
|
|
228
|
-
$64$username$47$core$46$TokenKind$Shebang.prototype.$tag =
|
|
232
|
+
$64$username$47$core$46$TokenKind$Shebang.prototype.$tag = 84;
|
|
229
233
|
$64$username$47$core$46$TokenKind$Shebang.prototype.$name = "Shebang";
|
|
230
234
|
function $64$username$47$core$46$TokenKind$Comment(param0) {
|
|
231
235
|
this._0 = param0;
|
|
232
236
|
}
|
|
233
|
-
$64$username$47$core$46$TokenKind$Comment.prototype.$tag =
|
|
237
|
+
$64$username$47$core$46$TokenKind$Comment.prototype.$tag = 85;
|
|
234
238
|
$64$username$47$core$46$TokenKind$Comment.prototype.$name = "Comment";
|
|
235
239
|
function $64$username$47$core$46$TokenKind$BlockComment(param0) {
|
|
236
240
|
this._0 = param0;
|
|
237
241
|
}
|
|
238
|
-
$64$username$47$core$46$TokenKind$BlockComment.prototype.$tag =
|
|
242
|
+
$64$username$47$core$46$TokenKind$BlockComment.prototype.$tag = 86;
|
|
239
243
|
$64$username$47$core$46$TokenKind$BlockComment.prototype.$name = "BlockComment";
|
|
240
|
-
const $64$username$47$core$46$TokenKind$Eof = { $tag:
|
|
244
|
+
const $64$username$47$core$46$TokenKind$Eof = { $tag: 87, $name: "Eof" };
|
|
241
245
|
function $64$username$47$core$46$Stmt$VarDecl(param0, param1, param2) {
|
|
242
246
|
this._0 = param0;
|
|
243
247
|
this._1 = param1;
|
|
@@ -245,16 +249,23 @@ function $64$username$47$core$46$Stmt$VarDecl(param0, param1, param2) {
|
|
|
245
249
|
}
|
|
246
250
|
$64$username$47$core$46$Stmt$VarDecl.prototype.$tag = 0;
|
|
247
251
|
$64$username$47$core$46$Stmt$VarDecl.prototype.$name = "VarDecl";
|
|
252
|
+
function $64$username$47$core$46$Stmt$DestructDecl(param0, param1, param2) {
|
|
253
|
+
this._0 = param0;
|
|
254
|
+
this._1 = param1;
|
|
255
|
+
this._2 = param2;
|
|
256
|
+
}
|
|
257
|
+
$64$username$47$core$46$Stmt$DestructDecl.prototype.$tag = 1;
|
|
258
|
+
$64$username$47$core$46$Stmt$DestructDecl.prototype.$name = "DestructDecl";
|
|
248
259
|
function $64$username$47$core$46$Stmt$Assign(param0, param1) {
|
|
249
260
|
this._0 = param0;
|
|
250
261
|
this._1 = param1;
|
|
251
262
|
}
|
|
252
|
-
$64$username$47$core$46$Stmt$Assign.prototype.$tag =
|
|
263
|
+
$64$username$47$core$46$Stmt$Assign.prototype.$tag = 2;
|
|
253
264
|
$64$username$47$core$46$Stmt$Assign.prototype.$name = "Assign";
|
|
254
265
|
function $64$username$47$core$46$Stmt$FnDecl(param0) {
|
|
255
266
|
this._0 = param0;
|
|
256
267
|
}
|
|
257
|
-
$64$username$47$core$46$Stmt$FnDecl.prototype.$tag =
|
|
268
|
+
$64$username$47$core$46$Stmt$FnDecl.prototype.$tag = 3;
|
|
258
269
|
$64$username$47$core$46$Stmt$FnDecl.prototype.$name = "FnDecl";
|
|
259
270
|
function $64$username$47$core$46$Stmt$If(param0, param1, param2, param3) {
|
|
260
271
|
this._0 = param0;
|
|
@@ -262,25 +273,25 @@ function $64$username$47$core$46$Stmt$If(param0, param1, param2, param3) {
|
|
|
262
273
|
this._2 = param2;
|
|
263
274
|
this._3 = param3;
|
|
264
275
|
}
|
|
265
|
-
$64$username$47$core$46$Stmt$If.prototype.$tag =
|
|
276
|
+
$64$username$47$core$46$Stmt$If.prototype.$tag = 4;
|
|
266
277
|
$64$username$47$core$46$Stmt$If.prototype.$name = "If";
|
|
267
278
|
function $64$username$47$core$46$Stmt$Unless(param0, param1) {
|
|
268
279
|
this._0 = param0;
|
|
269
280
|
this._1 = param1;
|
|
270
281
|
}
|
|
271
|
-
$64$username$47$core$46$Stmt$Unless.prototype.$tag =
|
|
282
|
+
$64$username$47$core$46$Stmt$Unless.prototype.$tag = 5;
|
|
272
283
|
$64$username$47$core$46$Stmt$Unless.prototype.$name = "Unless";
|
|
273
284
|
function $64$username$47$core$46$Stmt$While(param0, param1) {
|
|
274
285
|
this._0 = param0;
|
|
275
286
|
this._1 = param1;
|
|
276
287
|
}
|
|
277
|
-
$64$username$47$core$46$Stmt$While.prototype.$tag =
|
|
288
|
+
$64$username$47$core$46$Stmt$While.prototype.$tag = 6;
|
|
278
289
|
$64$username$47$core$46$Stmt$While.prototype.$name = "While";
|
|
279
290
|
function $64$username$47$core$46$Stmt$Until(param0, param1) {
|
|
280
291
|
this._0 = param0;
|
|
281
292
|
this._1 = param1;
|
|
282
293
|
}
|
|
283
|
-
$64$username$47$core$46$Stmt$Until.prototype.$tag =
|
|
294
|
+
$64$username$47$core$46$Stmt$Until.prototype.$tag = 7;
|
|
284
295
|
$64$username$47$core$46$Stmt$Until.prototype.$name = "Until";
|
|
285
296
|
function $64$username$47$core$46$Stmt$ForIn(param0, param1, param2, param3) {
|
|
286
297
|
this._0 = param0;
|
|
@@ -288,7 +299,7 @@ function $64$username$47$core$46$Stmt$ForIn(param0, param1, param2, param3) {
|
|
|
288
299
|
this._2 = param2;
|
|
289
300
|
this._3 = param3;
|
|
290
301
|
}
|
|
291
|
-
$64$username$47$core$46$Stmt$ForIn.prototype.$tag =
|
|
302
|
+
$64$username$47$core$46$Stmt$ForIn.prototype.$tag = 8;
|
|
292
303
|
$64$username$47$core$46$Stmt$ForIn.prototype.$name = "ForIn";
|
|
293
304
|
function $64$username$47$core$46$Stmt$ForRange(param0, param1, param2, param3) {
|
|
294
305
|
this._0 = param0;
|
|
@@ -296,32 +307,32 @@ function $64$username$47$core$46$Stmt$ForRange(param0, param1, param2, param3) {
|
|
|
296
307
|
this._2 = param2;
|
|
297
308
|
this._3 = param3;
|
|
298
309
|
}
|
|
299
|
-
$64$username$47$core$46$Stmt$ForRange.prototype.$tag =
|
|
310
|
+
$64$username$47$core$46$Stmt$ForRange.prototype.$tag = 9;
|
|
300
311
|
$64$username$47$core$46$Stmt$ForRange.prototype.$name = "ForRange";
|
|
301
312
|
function $64$username$47$core$46$Stmt$MatchStmt(param0, param1) {
|
|
302
313
|
this._0 = param0;
|
|
303
314
|
this._1 = param1;
|
|
304
315
|
}
|
|
305
|
-
$64$username$47$core$46$Stmt$MatchStmt.prototype.$tag =
|
|
316
|
+
$64$username$47$core$46$Stmt$MatchStmt.prototype.$tag = 10;
|
|
306
317
|
$64$username$47$core$46$Stmt$MatchStmt.prototype.$name = "MatchStmt";
|
|
307
318
|
function $64$username$47$core$46$Stmt$PostfixIf(param0, param1) {
|
|
308
319
|
this._0 = param0;
|
|
309
320
|
this._1 = param1;
|
|
310
321
|
}
|
|
311
|
-
$64$username$47$core$46$Stmt$PostfixIf.prototype.$tag =
|
|
322
|
+
$64$username$47$core$46$Stmt$PostfixIf.prototype.$tag = 11;
|
|
312
323
|
$64$username$47$core$46$Stmt$PostfixIf.prototype.$name = "PostfixIf";
|
|
313
324
|
function $64$username$47$core$46$Stmt$PostfixUnless(param0, param1) {
|
|
314
325
|
this._0 = param0;
|
|
315
326
|
this._1 = param1;
|
|
316
327
|
}
|
|
317
|
-
$64$username$47$core$46$Stmt$PostfixUnless.prototype.$tag =
|
|
328
|
+
$64$username$47$core$46$Stmt$PostfixUnless.prototype.$tag = 12;
|
|
318
329
|
$64$username$47$core$46$Stmt$PostfixUnless.prototype.$name = "PostfixUnless";
|
|
319
330
|
function $64$username$47$core$46$Stmt$PostfixFor(param0, param1, param2) {
|
|
320
331
|
this._0 = param0;
|
|
321
332
|
this._1 = param1;
|
|
322
333
|
this._2 = param2;
|
|
323
334
|
}
|
|
324
|
-
$64$username$47$core$46$Stmt$PostfixFor.prototype.$tag =
|
|
335
|
+
$64$username$47$core$46$Stmt$PostfixFor.prototype.$tag = 13;
|
|
325
336
|
$64$username$47$core$46$Stmt$PostfixFor.prototype.$name = "PostfixFor";
|
|
326
337
|
function $64$username$47$core$46$Stmt$TryCatch(param0, param1, param2, param3) {
|
|
327
338
|
this._0 = param0;
|
|
@@ -329,62 +340,62 @@ function $64$username$47$core$46$Stmt$TryCatch(param0, param1, param2, param3) {
|
|
|
329
340
|
this._2 = param2;
|
|
330
341
|
this._3 = param3;
|
|
331
342
|
}
|
|
332
|
-
$64$username$47$core$46$Stmt$TryCatch.prototype.$tag =
|
|
343
|
+
$64$username$47$core$46$Stmt$TryCatch.prototype.$tag = 14;
|
|
333
344
|
$64$username$47$core$46$Stmt$TryCatch.prototype.$name = "TryCatch";
|
|
334
345
|
function $64$username$47$core$46$Stmt$Throw(param0) {
|
|
335
346
|
this._0 = param0;
|
|
336
347
|
}
|
|
337
|
-
$64$username$47$core$46$Stmt$Throw.prototype.$tag =
|
|
348
|
+
$64$username$47$core$46$Stmt$Throw.prototype.$tag = 15;
|
|
338
349
|
$64$username$47$core$46$Stmt$Throw.prototype.$name = "Throw";
|
|
339
350
|
function $64$username$47$core$46$Stmt$Return(param0) {
|
|
340
351
|
this._0 = param0;
|
|
341
352
|
}
|
|
342
|
-
$64$username$47$core$46$Stmt$Return.prototype.$tag =
|
|
353
|
+
$64$username$47$core$46$Stmt$Return.prototype.$tag = 16;
|
|
343
354
|
$64$username$47$core$46$Stmt$Return.prototype.$name = "Return";
|
|
344
|
-
const $64$username$47$core$46$Stmt$Break = { $tag:
|
|
345
|
-
const $64$username$47$core$46$Stmt$Continue = { $tag:
|
|
355
|
+
const $64$username$47$core$46$Stmt$Break = { $tag: 17, $name: "Break" };
|
|
356
|
+
const $64$username$47$core$46$Stmt$Continue = { $tag: 18, $name: "Continue" };
|
|
346
357
|
function $64$username$47$core$46$Stmt$ExprStmt(param0) {
|
|
347
358
|
this._0 = param0;
|
|
348
359
|
}
|
|
349
|
-
$64$username$47$core$46$Stmt$ExprStmt.prototype.$tag =
|
|
360
|
+
$64$username$47$core$46$Stmt$ExprStmt.prototype.$tag = 19;
|
|
350
361
|
$64$username$47$core$46$Stmt$ExprStmt.prototype.$name = "ExprStmt";
|
|
351
362
|
function $64$username$47$core$46$Stmt$ImportDecl(param0) {
|
|
352
363
|
this._0 = param0;
|
|
353
364
|
}
|
|
354
|
-
$64$username$47$core$46$Stmt$ImportDecl.prototype.$tag =
|
|
365
|
+
$64$username$47$core$46$Stmt$ImportDecl.prototype.$tag = 20;
|
|
355
366
|
$64$username$47$core$46$Stmt$ImportDecl.prototype.$name = "ImportDecl";
|
|
356
367
|
function $64$username$47$core$46$Stmt$UseDecl(param0, param1) {
|
|
357
368
|
this._0 = param0;
|
|
358
369
|
this._1 = param1;
|
|
359
370
|
}
|
|
360
|
-
$64$username$47$core$46$Stmt$UseDecl.prototype.$tag =
|
|
371
|
+
$64$username$47$core$46$Stmt$UseDecl.prototype.$tag = 21;
|
|
361
372
|
$64$username$47$core$46$Stmt$UseDecl.prototype.$name = "UseDecl";
|
|
362
373
|
function $64$username$47$core$46$Stmt$ModDecl(param0, param1) {
|
|
363
374
|
this._0 = param0;
|
|
364
375
|
this._1 = param1;
|
|
365
376
|
}
|
|
366
|
-
$64$username$47$core$46$Stmt$ModDecl.prototype.$tag =
|
|
377
|
+
$64$username$47$core$46$Stmt$ModDecl.prototype.$tag = 22;
|
|
367
378
|
$64$username$47$core$46$Stmt$ModDecl.prototype.$name = "ModDecl";
|
|
368
379
|
function $64$username$47$core$46$Stmt$ExportDefault(param0) {
|
|
369
380
|
this._0 = param0;
|
|
370
381
|
}
|
|
371
|
-
$64$username$47$core$46$Stmt$ExportDefault.prototype.$tag =
|
|
382
|
+
$64$username$47$core$46$Stmt$ExportDefault.prototype.$tag = 23;
|
|
372
383
|
$64$username$47$core$46$Stmt$ExportDefault.prototype.$name = "ExportDefault";
|
|
373
384
|
function $64$username$47$core$46$Stmt$PubDecl(param0) {
|
|
374
385
|
this._0 = param0;
|
|
375
386
|
}
|
|
376
|
-
$64$username$47$core$46$Stmt$PubDecl.prototype.$tag =
|
|
387
|
+
$64$username$47$core$46$Stmt$PubDecl.prototype.$tag = 24;
|
|
377
388
|
$64$username$47$core$46$Stmt$PubDecl.prototype.$name = "PubDecl";
|
|
378
389
|
function $64$username$47$core$46$Stmt$TypeDecl(param0, param1) {
|
|
379
390
|
this._0 = param0;
|
|
380
391
|
this._1 = param1;
|
|
381
392
|
}
|
|
382
|
-
$64$username$47$core$46$Stmt$TypeDecl.prototype.$tag =
|
|
393
|
+
$64$username$47$core$46$Stmt$TypeDecl.prototype.$tag = 25;
|
|
383
394
|
$64$username$47$core$46$Stmt$TypeDecl.prototype.$name = "TypeDecl";
|
|
384
395
|
function $64$username$47$core$46$Stmt$DeleteStmt(param0) {
|
|
385
396
|
this._0 = param0;
|
|
386
397
|
}
|
|
387
|
-
$64$username$47$core$46$Stmt$DeleteStmt.prototype.$tag =
|
|
398
|
+
$64$username$47$core$46$Stmt$DeleteStmt.prototype.$tag = 26;
|
|
388
399
|
$64$username$47$core$46$Stmt$DeleteStmt.prototype.$name = "DeleteStmt";
|
|
389
400
|
const Option$None$4$ = { $tag: 0, $name: "None" };
|
|
390
401
|
function Option$Some$4$(param0) {
|
|
@@ -459,136 +470,151 @@ function $64$username$47$core$46$Expr$ArrayLit(param0) {
|
|
|
459
470
|
}
|
|
460
471
|
$64$username$47$core$46$Expr$ArrayLit.prototype.$tag = 8;
|
|
461
472
|
$64$username$47$core$46$Expr$ArrayLit.prototype.$name = "ArrayLit";
|
|
473
|
+
function $64$username$47$core$46$Expr$RangeArray(param0, param1, param2) {
|
|
474
|
+
this._0 = param0;
|
|
475
|
+
this._1 = param1;
|
|
476
|
+
this._2 = param2;
|
|
477
|
+
}
|
|
478
|
+
$64$username$47$core$46$Expr$RangeArray.prototype.$tag = 9;
|
|
479
|
+
$64$username$47$core$46$Expr$RangeArray.prototype.$name = "RangeArray";
|
|
480
|
+
function $64$username$47$core$46$Expr$Slice(param0, param1, param2, param3) {
|
|
481
|
+
this._0 = param0;
|
|
482
|
+
this._1 = param1;
|
|
483
|
+
this._2 = param2;
|
|
484
|
+
this._3 = param3;
|
|
485
|
+
}
|
|
486
|
+
$64$username$47$core$46$Expr$Slice.prototype.$tag = 10;
|
|
487
|
+
$64$username$47$core$46$Expr$Slice.prototype.$name = "Slice";
|
|
462
488
|
function $64$username$47$core$46$Expr$ObjectLit(param0) {
|
|
463
489
|
this._0 = param0;
|
|
464
490
|
}
|
|
465
|
-
$64$username$47$core$46$Expr$ObjectLit.prototype.$tag =
|
|
491
|
+
$64$username$47$core$46$Expr$ObjectLit.prototype.$tag = 11;
|
|
466
492
|
$64$username$47$core$46$Expr$ObjectLit.prototype.$name = "ObjectLit";
|
|
467
493
|
function $64$username$47$core$46$Expr$Ident(param0) {
|
|
468
494
|
this._0 = param0;
|
|
469
495
|
}
|
|
470
|
-
$64$username$47$core$46$Expr$Ident.prototype.$tag =
|
|
496
|
+
$64$username$47$core$46$Expr$Ident.prototype.$tag = 12;
|
|
471
497
|
$64$username$47$core$46$Expr$Ident.prototype.$name = "Ident";
|
|
472
498
|
function $64$username$47$core$46$Expr$DotAccess(param0, param1) {
|
|
473
499
|
this._0 = param0;
|
|
474
500
|
this._1 = param1;
|
|
475
501
|
}
|
|
476
|
-
$64$username$47$core$46$Expr$DotAccess.prototype.$tag =
|
|
502
|
+
$64$username$47$core$46$Expr$DotAccess.prototype.$tag = 13;
|
|
477
503
|
$64$username$47$core$46$Expr$DotAccess.prototype.$name = "DotAccess";
|
|
478
504
|
function $64$username$47$core$46$Expr$IndexAccess(param0, param1) {
|
|
479
505
|
this._0 = param0;
|
|
480
506
|
this._1 = param1;
|
|
481
507
|
}
|
|
482
|
-
$64$username$47$core$46$Expr$IndexAccess.prototype.$tag =
|
|
508
|
+
$64$username$47$core$46$Expr$IndexAccess.prototype.$tag = 14;
|
|
483
509
|
$64$username$47$core$46$Expr$IndexAccess.prototype.$name = "IndexAccess";
|
|
484
510
|
function $64$username$47$core$46$Expr$BinOp(param0, param1, param2) {
|
|
485
511
|
this._0 = param0;
|
|
486
512
|
this._1 = param1;
|
|
487
513
|
this._2 = param2;
|
|
488
514
|
}
|
|
489
|
-
$64$username$47$core$46$Expr$BinOp.prototype.$tag =
|
|
515
|
+
$64$username$47$core$46$Expr$BinOp.prototype.$tag = 15;
|
|
490
516
|
$64$username$47$core$46$Expr$BinOp.prototype.$name = "BinOp";
|
|
491
517
|
function $64$username$47$core$46$Expr$UnaryNeg(param0) {
|
|
492
518
|
this._0 = param0;
|
|
493
519
|
}
|
|
494
|
-
$64$username$47$core$46$Expr$UnaryNeg.prototype.$tag =
|
|
520
|
+
$64$username$47$core$46$Expr$UnaryNeg.prototype.$tag = 16;
|
|
495
521
|
$64$username$47$core$46$Expr$UnaryNeg.prototype.$name = "UnaryNeg";
|
|
496
522
|
function $64$username$47$core$46$Expr$UnaryNot(param0) {
|
|
497
523
|
this._0 = param0;
|
|
498
524
|
}
|
|
499
|
-
$64$username$47$core$46$Expr$UnaryNot.prototype.$tag =
|
|
525
|
+
$64$username$47$core$46$Expr$UnaryNot.prototype.$tag = 17;
|
|
500
526
|
$64$username$47$core$46$Expr$UnaryNot.prototype.$name = "UnaryNot";
|
|
501
527
|
function $64$username$47$core$46$Expr$UnaryTypeof(param0) {
|
|
502
528
|
this._0 = param0;
|
|
503
529
|
}
|
|
504
|
-
$64$username$47$core$46$Expr$UnaryTypeof.prototype.$tag =
|
|
530
|
+
$64$username$47$core$46$Expr$UnaryTypeof.prototype.$tag = 18;
|
|
505
531
|
$64$username$47$core$46$Expr$UnaryTypeof.prototype.$name = "UnaryTypeof";
|
|
506
532
|
function $64$username$47$core$46$Expr$IsCheck(param0, param1) {
|
|
507
533
|
this._0 = param0;
|
|
508
534
|
this._1 = param1;
|
|
509
535
|
}
|
|
510
|
-
$64$username$47$core$46$Expr$IsCheck.prototype.$tag =
|
|
536
|
+
$64$username$47$core$46$Expr$IsCheck.prototype.$tag = 19;
|
|
511
537
|
$64$username$47$core$46$Expr$IsCheck.prototype.$name = "IsCheck";
|
|
512
538
|
function $64$username$47$core$46$Expr$AsCast(param0, param1) {
|
|
513
539
|
this._0 = param0;
|
|
514
540
|
this._1 = param1;
|
|
515
541
|
}
|
|
516
|
-
$64$username$47$core$46$Expr$AsCast.prototype.$tag =
|
|
542
|
+
$64$username$47$core$46$Expr$AsCast.prototype.$tag = 20;
|
|
517
543
|
$64$username$47$core$46$Expr$AsCast.prototype.$name = "AsCast";
|
|
518
544
|
function $64$username$47$core$46$Expr$Instanceof(param0, param1) {
|
|
519
545
|
this._0 = param0;
|
|
520
546
|
this._1 = param1;
|
|
521
547
|
}
|
|
522
|
-
$64$username$47$core$46$Expr$Instanceof.prototype.$tag =
|
|
548
|
+
$64$username$47$core$46$Expr$Instanceof.prototype.$tag = 21;
|
|
523
549
|
$64$username$47$core$46$Expr$Instanceof.prototype.$name = "Instanceof";
|
|
524
550
|
function $64$username$47$core$46$Expr$FnExpr(param0, param1) {
|
|
525
551
|
this._0 = param0;
|
|
526
552
|
this._1 = param1;
|
|
527
553
|
}
|
|
528
|
-
$64$username$47$core$46$Expr$FnExpr.prototype.$tag =
|
|
554
|
+
$64$username$47$core$46$Expr$FnExpr.prototype.$tag = 22;
|
|
529
555
|
$64$username$47$core$46$Expr$FnExpr.prototype.$name = "FnExpr";
|
|
530
556
|
function $64$username$47$core$46$Expr$FnExprTo(param0, param1) {
|
|
531
557
|
this._0 = param0;
|
|
532
558
|
this._1 = param1;
|
|
533
559
|
}
|
|
534
|
-
$64$username$47$core$46$Expr$FnExprTo.prototype.$tag =
|
|
560
|
+
$64$username$47$core$46$Expr$FnExprTo.prototype.$tag = 23;
|
|
535
561
|
$64$username$47$core$46$Expr$FnExprTo.prototype.$name = "FnExprTo";
|
|
536
562
|
function $64$username$47$core$46$Expr$Call(param0, param1) {
|
|
537
563
|
this._0 = param0;
|
|
538
564
|
this._1 = param1;
|
|
539
565
|
}
|
|
540
|
-
$64$username$47$core$46$Expr$Call.prototype.$tag =
|
|
566
|
+
$64$username$47$core$46$Expr$Call.prototype.$tag = 24;
|
|
541
567
|
$64$username$47$core$46$Expr$Call.prototype.$name = "Call";
|
|
542
568
|
function $64$username$47$core$46$Expr$MethodCall(param0, param1, param2) {
|
|
543
569
|
this._0 = param0;
|
|
544
570
|
this._1 = param1;
|
|
545
571
|
this._2 = param2;
|
|
546
572
|
}
|
|
547
|
-
$64$username$47$core$46$Expr$MethodCall.prototype.$tag =
|
|
573
|
+
$64$username$47$core$46$Expr$MethodCall.prototype.$tag = 25;
|
|
548
574
|
$64$username$47$core$46$Expr$MethodCall.prototype.$name = "MethodCall";
|
|
549
575
|
function $64$username$47$core$46$Expr$NewExpr(param0, param1) {
|
|
550
576
|
this._0 = param0;
|
|
551
577
|
this._1 = param1;
|
|
552
578
|
}
|
|
553
|
-
$64$username$47$core$46$Expr$NewExpr.prototype.$tag =
|
|
579
|
+
$64$username$47$core$46$Expr$NewExpr.prototype.$tag = 26;
|
|
554
580
|
$64$username$47$core$46$Expr$NewExpr.prototype.$name = "NewExpr";
|
|
555
581
|
function $64$username$47$core$46$Expr$Pipe(param0, param1) {
|
|
556
582
|
this._0 = param0;
|
|
557
583
|
this._1 = param1;
|
|
558
584
|
}
|
|
559
|
-
$64$username$47$core$46$Expr$Pipe.prototype.$tag =
|
|
585
|
+
$64$username$47$core$46$Expr$Pipe.prototype.$tag = 27;
|
|
560
586
|
$64$username$47$core$46$Expr$Pipe.prototype.$name = "Pipe";
|
|
561
587
|
function $64$username$47$core$46$Expr$IfExpr(param0, param1, param2) {
|
|
562
588
|
this._0 = param0;
|
|
563
589
|
this._1 = param1;
|
|
564
590
|
this._2 = param2;
|
|
565
591
|
}
|
|
566
|
-
$64$username$47$core$46$Expr$IfExpr.prototype.$tag =
|
|
592
|
+
$64$username$47$core$46$Expr$IfExpr.prototype.$tag = 28;
|
|
567
593
|
$64$username$47$core$46$Expr$IfExpr.prototype.$name = "IfExpr";
|
|
568
594
|
function $64$username$47$core$46$Expr$TryExpr(param0, param1, param2) {
|
|
569
595
|
this._0 = param0;
|
|
570
596
|
this._1 = param1;
|
|
571
597
|
this._2 = param2;
|
|
572
598
|
}
|
|
573
|
-
$64$username$47$core$46$Expr$TryExpr.prototype.$tag =
|
|
599
|
+
$64$username$47$core$46$Expr$TryExpr.prototype.$tag = 29;
|
|
574
600
|
$64$username$47$core$46$Expr$TryExpr.prototype.$name = "TryExpr";
|
|
575
601
|
function $64$username$47$core$46$Expr$MatchExpr(param0, param1) {
|
|
576
602
|
this._0 = param0;
|
|
577
603
|
this._1 = param1;
|
|
578
604
|
}
|
|
579
|
-
$64$username$47$core$46$Expr$MatchExpr.prototype.$tag =
|
|
605
|
+
$64$username$47$core$46$Expr$MatchExpr.prototype.$tag = 30;
|
|
580
606
|
$64$username$47$core$46$Expr$MatchExpr.prototype.$name = "MatchExpr";
|
|
581
607
|
function $64$username$47$core$46$Expr$AwaitExpr(param0) {
|
|
582
608
|
this._0 = param0;
|
|
583
609
|
}
|
|
584
|
-
$64$username$47$core$46$Expr$AwaitExpr.prototype.$tag =
|
|
610
|
+
$64$username$47$core$46$Expr$AwaitExpr.prototype.$tag = 31;
|
|
585
611
|
$64$username$47$core$46$Expr$AwaitExpr.prototype.$name = "AwaitExpr";
|
|
586
612
|
function $64$username$47$core$46$Expr$DeleteExpr(param0) {
|
|
587
613
|
this._0 = param0;
|
|
588
614
|
}
|
|
589
|
-
$64$username$47$core$46$Expr$DeleteExpr.prototype.$tag =
|
|
615
|
+
$64$username$47$core$46$Expr$DeleteExpr.prototype.$tag = 32;
|
|
590
616
|
$64$username$47$core$46$Expr$DeleteExpr.prototype.$name = "DeleteExpr";
|
|
591
|
-
const $64$username$47$core$46$Expr$ThisExpr = { $tag:
|
|
617
|
+
const $64$username$47$core$46$Expr$ThisExpr = { $tag: 33, $name: "ThisExpr" };
|
|
592
618
|
function $64$username$47$core$46$FnBody$Block(param0) {
|
|
593
619
|
this._0 = param0;
|
|
594
620
|
}
|
|
@@ -1503,10 +1529,10 @@ function _M0MP311moonbitlang4core5array5Array4pushGRP28username4core4StmtE(self,
|
|
|
1503
1529
|
function _M0MP311moonbitlang4core5array5Array4pushGcE(self, value) {
|
|
1504
1530
|
_M0MP311moonbitlang4core7builtin7JSArray4push(self, value);
|
|
1505
1531
|
}
|
|
1506
|
-
function
|
|
1532
|
+
function _M0MP311moonbitlang4core5array5Array4pushGsE(self, value) {
|
|
1507
1533
|
_M0MP311moonbitlang4core7builtin7JSArray4push(self, value);
|
|
1508
1534
|
}
|
|
1509
|
-
function
|
|
1535
|
+
function _M0MP311moonbitlang4core5array5Array4pushGRP28username4core10ElIfBranchE(self, value) {
|
|
1510
1536
|
_M0MP311moonbitlang4core7builtin7JSArray4push(self, value);
|
|
1511
1537
|
}
|
|
1512
1538
|
function _M0MP311moonbitlang4core5array5Array4pushGyE(self, value) {
|
|
@@ -2060,685 +2086,706 @@ function _M0FP511moonbitlang1x3sys8internal3ffi14get__cli__args() {
|
|
|
2060
2086
|
function _M0FP311moonbitlang1x3sys14get__cli__args() {
|
|
2061
2087
|
return _M0FP511moonbitlang1x3sys8internal3ffi14get__cli__args();
|
|
2062
2088
|
}
|
|
2063
|
-
function _M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(
|
|
2064
|
-
let
|
|
2065
|
-
let
|
|
2089
|
+
function _M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_x_767, _x_768) {
|
|
2090
|
+
let _x0_787;
|
|
2091
|
+
let _y0_788;
|
|
2066
2092
|
_L: {
|
|
2067
|
-
let
|
|
2068
|
-
let
|
|
2093
|
+
let _x0_785;
|
|
2094
|
+
let _y0_786;
|
|
2069
2095
|
_L$2: {
|
|
2070
|
-
let
|
|
2071
|
-
let
|
|
2096
|
+
let _x0_783;
|
|
2097
|
+
let _y0_784;
|
|
2072
2098
|
_L$3: {
|
|
2073
|
-
let
|
|
2074
|
-
let
|
|
2099
|
+
let _x0_781;
|
|
2100
|
+
let _y0_782;
|
|
2075
2101
|
_L$4: {
|
|
2076
|
-
let
|
|
2077
|
-
let
|
|
2102
|
+
let _x0_779;
|
|
2103
|
+
let _y0_780;
|
|
2078
2104
|
_L$5: {
|
|
2079
|
-
let
|
|
2080
|
-
let
|
|
2081
|
-
let
|
|
2082
|
-
let
|
|
2105
|
+
let _x1_776;
|
|
2106
|
+
let _x0_775;
|
|
2107
|
+
let _y0_777;
|
|
2108
|
+
let _y1_778;
|
|
2083
2109
|
_L$6: {
|
|
2084
|
-
let
|
|
2085
|
-
let
|
|
2110
|
+
let _x0_773;
|
|
2111
|
+
let _y0_774;
|
|
2086
2112
|
_L$7: {
|
|
2087
|
-
let
|
|
2088
|
-
let
|
|
2113
|
+
let _x0_771;
|
|
2114
|
+
let _y0_772;
|
|
2089
2115
|
_L$8: {
|
|
2090
|
-
let
|
|
2091
|
-
let
|
|
2116
|
+
let _x0_769;
|
|
2117
|
+
let _y0_770;
|
|
2092
2118
|
_L$9: {
|
|
2093
|
-
switch (
|
|
2119
|
+
switch (_x_767.$tag) {
|
|
2094
2120
|
case 0: {
|
|
2095
|
-
const _Int =
|
|
2096
|
-
const _$42$
|
|
2097
|
-
if (
|
|
2098
|
-
const _Int$2 =
|
|
2099
|
-
const _$42$
|
|
2100
|
-
|
|
2101
|
-
|
|
2121
|
+
const _Int = _x_767;
|
|
2122
|
+
const _$42$x0_769 = _Int._0;
|
|
2123
|
+
if (_x_768.$tag === 0) {
|
|
2124
|
+
const _Int$2 = _x_768;
|
|
2125
|
+
const _$42$y0_770 = _Int$2._0;
|
|
2126
|
+
_x0_769 = _$42$x0_769;
|
|
2127
|
+
_y0_770 = _$42$y0_770;
|
|
2102
2128
|
break _L$9;
|
|
2103
2129
|
} else {
|
|
2104
2130
|
return false;
|
|
2105
2131
|
}
|
|
2106
2132
|
}
|
|
2107
2133
|
case 1: {
|
|
2108
|
-
const _Float =
|
|
2109
|
-
const _$42$
|
|
2110
|
-
if (
|
|
2111
|
-
const _Float$2 =
|
|
2112
|
-
const _$42$
|
|
2113
|
-
|
|
2114
|
-
|
|
2134
|
+
const _Float = _x_767;
|
|
2135
|
+
const _$42$x0_771 = _Float._0;
|
|
2136
|
+
if (_x_768.$tag === 1) {
|
|
2137
|
+
const _Float$2 = _x_768;
|
|
2138
|
+
const _$42$y0_772 = _Float$2._0;
|
|
2139
|
+
_x0_771 = _$42$x0_771;
|
|
2140
|
+
_y0_772 = _$42$y0_772;
|
|
2115
2141
|
break _L$8;
|
|
2116
2142
|
} else {
|
|
2117
2143
|
return false;
|
|
2118
2144
|
}
|
|
2119
2145
|
}
|
|
2120
2146
|
case 2: {
|
|
2121
|
-
const _Str =
|
|
2122
|
-
const _$42$
|
|
2123
|
-
if (
|
|
2124
|
-
const _Str$2 =
|
|
2125
|
-
const _$42$
|
|
2126
|
-
|
|
2127
|
-
|
|
2147
|
+
const _Str = _x_767;
|
|
2148
|
+
const _$42$x0_773 = _Str._0;
|
|
2149
|
+
if (_x_768.$tag === 2) {
|
|
2150
|
+
const _Str$2 = _x_768;
|
|
2151
|
+
const _$42$y0_774 = _Str$2._0;
|
|
2152
|
+
_x0_773 = _$42$x0_773;
|
|
2153
|
+
_y0_774 = _$42$y0_774;
|
|
2128
2154
|
break _L$7;
|
|
2129
2155
|
} else {
|
|
2130
2156
|
return false;
|
|
2131
2157
|
}
|
|
2132
2158
|
}
|
|
2133
2159
|
case 3: {
|
|
2134
|
-
const _Regex =
|
|
2135
|
-
const _$42$
|
|
2136
|
-
const _$42$
|
|
2137
|
-
if (
|
|
2138
|
-
const _Regex$2 =
|
|
2139
|
-
const _$42$
|
|
2140
|
-
const _$42$
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2160
|
+
const _Regex = _x_767;
|
|
2161
|
+
const _$42$x0_775 = _Regex._0;
|
|
2162
|
+
const _$42$x1_776 = _Regex._1;
|
|
2163
|
+
if (_x_768.$tag === 3) {
|
|
2164
|
+
const _Regex$2 = _x_768;
|
|
2165
|
+
const _$42$y0_777 = _Regex$2._0;
|
|
2166
|
+
const _$42$y1_778 = _Regex$2._1;
|
|
2167
|
+
_x1_776 = _$42$x1_776;
|
|
2168
|
+
_x0_775 = _$42$x0_775;
|
|
2169
|
+
_y0_777 = _$42$y0_777;
|
|
2170
|
+
_y1_778 = _$42$y1_778;
|
|
2145
2171
|
break _L$6;
|
|
2146
2172
|
} else {
|
|
2147
2173
|
return false;
|
|
2148
2174
|
}
|
|
2149
2175
|
}
|
|
2150
2176
|
case 4: {
|
|
2151
|
-
if (
|
|
2177
|
+
if (_x_768.$tag === 4) {
|
|
2152
2178
|
return true;
|
|
2153
2179
|
} else {
|
|
2154
2180
|
return false;
|
|
2155
2181
|
}
|
|
2156
2182
|
}
|
|
2157
2183
|
case 5: {
|
|
2158
|
-
if (
|
|
2184
|
+
if (_x_768.$tag === 5) {
|
|
2159
2185
|
return true;
|
|
2160
2186
|
} else {
|
|
2161
2187
|
return false;
|
|
2162
2188
|
}
|
|
2163
2189
|
}
|
|
2164
2190
|
case 6: {
|
|
2165
|
-
const _Ident =
|
|
2166
|
-
const _$42$
|
|
2167
|
-
if (
|
|
2168
|
-
const _Ident$2 =
|
|
2169
|
-
const _$42$
|
|
2170
|
-
|
|
2171
|
-
|
|
2191
|
+
const _Ident = _x_767;
|
|
2192
|
+
const _$42$x0_779 = _Ident._0;
|
|
2193
|
+
if (_x_768.$tag === 6) {
|
|
2194
|
+
const _Ident$2 = _x_768;
|
|
2195
|
+
const _$42$y0_780 = _Ident$2._0;
|
|
2196
|
+
_x0_779 = _$42$x0_779;
|
|
2197
|
+
_y0_780 = _$42$y0_780;
|
|
2172
2198
|
break _L$5;
|
|
2173
2199
|
} else {
|
|
2174
2200
|
return false;
|
|
2175
2201
|
}
|
|
2176
2202
|
}
|
|
2177
2203
|
case 7: {
|
|
2178
|
-
if (
|
|
2204
|
+
if (_x_768.$tag === 7) {
|
|
2179
2205
|
return true;
|
|
2180
2206
|
} else {
|
|
2181
2207
|
return false;
|
|
2182
2208
|
}
|
|
2183
2209
|
}
|
|
2184
2210
|
case 8: {
|
|
2185
|
-
if (
|
|
2211
|
+
if (_x_768.$tag === 8) {
|
|
2186
2212
|
return true;
|
|
2187
2213
|
} else {
|
|
2188
2214
|
return false;
|
|
2189
2215
|
}
|
|
2190
2216
|
}
|
|
2191
2217
|
case 9: {
|
|
2192
|
-
if (
|
|
2218
|
+
if (_x_768.$tag === 9) {
|
|
2193
2219
|
return true;
|
|
2194
2220
|
} else {
|
|
2195
2221
|
return false;
|
|
2196
2222
|
}
|
|
2197
2223
|
}
|
|
2198
2224
|
case 10: {
|
|
2199
|
-
if (
|
|
2225
|
+
if (_x_768.$tag === 10) {
|
|
2200
2226
|
return true;
|
|
2201
2227
|
} else {
|
|
2202
2228
|
return false;
|
|
2203
2229
|
}
|
|
2204
2230
|
}
|
|
2205
2231
|
case 11: {
|
|
2206
|
-
if (
|
|
2232
|
+
if (_x_768.$tag === 11) {
|
|
2207
2233
|
return true;
|
|
2208
2234
|
} else {
|
|
2209
2235
|
return false;
|
|
2210
2236
|
}
|
|
2211
2237
|
}
|
|
2212
2238
|
case 12: {
|
|
2213
|
-
if (
|
|
2239
|
+
if (_x_768.$tag === 12) {
|
|
2214
2240
|
return true;
|
|
2215
2241
|
} else {
|
|
2216
2242
|
return false;
|
|
2217
2243
|
}
|
|
2218
2244
|
}
|
|
2219
2245
|
case 13: {
|
|
2220
|
-
if (
|
|
2246
|
+
if (_x_768.$tag === 13) {
|
|
2221
2247
|
return true;
|
|
2222
2248
|
} else {
|
|
2223
2249
|
return false;
|
|
2224
2250
|
}
|
|
2225
2251
|
}
|
|
2226
2252
|
case 14: {
|
|
2227
|
-
if (
|
|
2253
|
+
if (_x_768.$tag === 14) {
|
|
2228
2254
|
return true;
|
|
2229
2255
|
} else {
|
|
2230
2256
|
return false;
|
|
2231
2257
|
}
|
|
2232
2258
|
}
|
|
2233
2259
|
case 15: {
|
|
2234
|
-
if (
|
|
2260
|
+
if (_x_768.$tag === 15) {
|
|
2235
2261
|
return true;
|
|
2236
2262
|
} else {
|
|
2237
2263
|
return false;
|
|
2238
2264
|
}
|
|
2239
2265
|
}
|
|
2240
2266
|
case 16: {
|
|
2241
|
-
if (
|
|
2267
|
+
if (_x_768.$tag === 16) {
|
|
2242
2268
|
return true;
|
|
2243
2269
|
} else {
|
|
2244
2270
|
return false;
|
|
2245
2271
|
}
|
|
2246
2272
|
}
|
|
2247
2273
|
case 17: {
|
|
2248
|
-
if (
|
|
2274
|
+
if (_x_768.$tag === 17) {
|
|
2249
2275
|
return true;
|
|
2250
2276
|
} else {
|
|
2251
2277
|
return false;
|
|
2252
2278
|
}
|
|
2253
2279
|
}
|
|
2254
2280
|
case 18: {
|
|
2255
|
-
if (
|
|
2281
|
+
if (_x_768.$tag === 18) {
|
|
2256
2282
|
return true;
|
|
2257
2283
|
} else {
|
|
2258
2284
|
return false;
|
|
2259
2285
|
}
|
|
2260
2286
|
}
|
|
2261
2287
|
case 19: {
|
|
2262
|
-
if (
|
|
2288
|
+
if (_x_768.$tag === 19) {
|
|
2263
2289
|
return true;
|
|
2264
2290
|
} else {
|
|
2265
2291
|
return false;
|
|
2266
2292
|
}
|
|
2267
2293
|
}
|
|
2268
2294
|
case 20: {
|
|
2269
|
-
if (
|
|
2295
|
+
if (_x_768.$tag === 20) {
|
|
2270
2296
|
return true;
|
|
2271
2297
|
} else {
|
|
2272
2298
|
return false;
|
|
2273
2299
|
}
|
|
2274
2300
|
}
|
|
2275
2301
|
case 21: {
|
|
2276
|
-
if (
|
|
2302
|
+
if (_x_768.$tag === 21) {
|
|
2277
2303
|
return true;
|
|
2278
2304
|
} else {
|
|
2279
2305
|
return false;
|
|
2280
2306
|
}
|
|
2281
2307
|
}
|
|
2282
2308
|
case 22: {
|
|
2283
|
-
if (
|
|
2309
|
+
if (_x_768.$tag === 22) {
|
|
2284
2310
|
return true;
|
|
2285
2311
|
} else {
|
|
2286
2312
|
return false;
|
|
2287
2313
|
}
|
|
2288
2314
|
}
|
|
2289
2315
|
case 23: {
|
|
2290
|
-
if (
|
|
2316
|
+
if (_x_768.$tag === 23) {
|
|
2291
2317
|
return true;
|
|
2292
2318
|
} else {
|
|
2293
2319
|
return false;
|
|
2294
2320
|
}
|
|
2295
2321
|
}
|
|
2296
2322
|
case 24: {
|
|
2297
|
-
if (
|
|
2323
|
+
if (_x_768.$tag === 24) {
|
|
2298
2324
|
return true;
|
|
2299
2325
|
} else {
|
|
2300
2326
|
return false;
|
|
2301
2327
|
}
|
|
2302
2328
|
}
|
|
2303
2329
|
case 25: {
|
|
2304
|
-
if (
|
|
2330
|
+
if (_x_768.$tag === 25) {
|
|
2305
2331
|
return true;
|
|
2306
2332
|
} else {
|
|
2307
2333
|
return false;
|
|
2308
2334
|
}
|
|
2309
2335
|
}
|
|
2310
2336
|
case 26: {
|
|
2311
|
-
if (
|
|
2337
|
+
if (_x_768.$tag === 26) {
|
|
2312
2338
|
return true;
|
|
2313
2339
|
} else {
|
|
2314
2340
|
return false;
|
|
2315
2341
|
}
|
|
2316
2342
|
}
|
|
2317
2343
|
case 27: {
|
|
2318
|
-
if (
|
|
2344
|
+
if (_x_768.$tag === 27) {
|
|
2319
2345
|
return true;
|
|
2320
2346
|
} else {
|
|
2321
2347
|
return false;
|
|
2322
2348
|
}
|
|
2323
2349
|
}
|
|
2324
2350
|
case 28: {
|
|
2325
|
-
if (
|
|
2351
|
+
if (_x_768.$tag === 28) {
|
|
2326
2352
|
return true;
|
|
2327
2353
|
} else {
|
|
2328
2354
|
return false;
|
|
2329
2355
|
}
|
|
2330
2356
|
}
|
|
2331
2357
|
case 29: {
|
|
2332
|
-
if (
|
|
2358
|
+
if (_x_768.$tag === 29) {
|
|
2333
2359
|
return true;
|
|
2334
2360
|
} else {
|
|
2335
2361
|
return false;
|
|
2336
2362
|
}
|
|
2337
2363
|
}
|
|
2338
2364
|
case 30: {
|
|
2339
|
-
if (
|
|
2365
|
+
if (_x_768.$tag === 30) {
|
|
2340
2366
|
return true;
|
|
2341
2367
|
} else {
|
|
2342
2368
|
return false;
|
|
2343
2369
|
}
|
|
2344
2370
|
}
|
|
2345
2371
|
case 31: {
|
|
2346
|
-
if (
|
|
2372
|
+
if (_x_768.$tag === 31) {
|
|
2347
2373
|
return true;
|
|
2348
2374
|
} else {
|
|
2349
2375
|
return false;
|
|
2350
2376
|
}
|
|
2351
2377
|
}
|
|
2352
2378
|
case 32: {
|
|
2353
|
-
if (
|
|
2379
|
+
if (_x_768.$tag === 32) {
|
|
2354
2380
|
return true;
|
|
2355
2381
|
} else {
|
|
2356
2382
|
return false;
|
|
2357
2383
|
}
|
|
2358
2384
|
}
|
|
2359
2385
|
case 33: {
|
|
2360
|
-
if (
|
|
2386
|
+
if (_x_768.$tag === 33) {
|
|
2361
2387
|
return true;
|
|
2362
2388
|
} else {
|
|
2363
2389
|
return false;
|
|
2364
2390
|
}
|
|
2365
2391
|
}
|
|
2366
2392
|
case 34: {
|
|
2367
|
-
if (
|
|
2393
|
+
if (_x_768.$tag === 34) {
|
|
2368
2394
|
return true;
|
|
2369
2395
|
} else {
|
|
2370
2396
|
return false;
|
|
2371
2397
|
}
|
|
2372
2398
|
}
|
|
2373
2399
|
case 35: {
|
|
2374
|
-
if (
|
|
2400
|
+
if (_x_768.$tag === 35) {
|
|
2375
2401
|
return true;
|
|
2376
2402
|
} else {
|
|
2377
2403
|
return false;
|
|
2378
2404
|
}
|
|
2379
2405
|
}
|
|
2380
2406
|
case 36: {
|
|
2381
|
-
if (
|
|
2407
|
+
if (_x_768.$tag === 36) {
|
|
2382
2408
|
return true;
|
|
2383
2409
|
} else {
|
|
2384
2410
|
return false;
|
|
2385
2411
|
}
|
|
2386
2412
|
}
|
|
2387
2413
|
case 37: {
|
|
2388
|
-
if (
|
|
2414
|
+
if (_x_768.$tag === 37) {
|
|
2389
2415
|
return true;
|
|
2390
2416
|
} else {
|
|
2391
2417
|
return false;
|
|
2392
2418
|
}
|
|
2393
2419
|
}
|
|
2394
2420
|
case 38: {
|
|
2395
|
-
if (
|
|
2421
|
+
if (_x_768.$tag === 38) {
|
|
2396
2422
|
return true;
|
|
2397
2423
|
} else {
|
|
2398
2424
|
return false;
|
|
2399
2425
|
}
|
|
2400
2426
|
}
|
|
2401
2427
|
case 39: {
|
|
2402
|
-
if (
|
|
2428
|
+
if (_x_768.$tag === 39) {
|
|
2403
2429
|
return true;
|
|
2404
2430
|
} else {
|
|
2405
2431
|
return false;
|
|
2406
2432
|
}
|
|
2407
2433
|
}
|
|
2408
2434
|
case 40: {
|
|
2409
|
-
if (
|
|
2435
|
+
if (_x_768.$tag === 40) {
|
|
2410
2436
|
return true;
|
|
2411
2437
|
} else {
|
|
2412
2438
|
return false;
|
|
2413
2439
|
}
|
|
2414
2440
|
}
|
|
2415
2441
|
case 41: {
|
|
2416
|
-
if (
|
|
2442
|
+
if (_x_768.$tag === 41) {
|
|
2417
2443
|
return true;
|
|
2418
2444
|
} else {
|
|
2419
2445
|
return false;
|
|
2420
2446
|
}
|
|
2421
2447
|
}
|
|
2422
2448
|
case 42: {
|
|
2423
|
-
if (
|
|
2449
|
+
if (_x_768.$tag === 42) {
|
|
2424
2450
|
return true;
|
|
2425
2451
|
} else {
|
|
2426
2452
|
return false;
|
|
2427
2453
|
}
|
|
2428
2454
|
}
|
|
2429
2455
|
case 43: {
|
|
2430
|
-
if (
|
|
2456
|
+
if (_x_768.$tag === 43) {
|
|
2431
2457
|
return true;
|
|
2432
2458
|
} else {
|
|
2433
2459
|
return false;
|
|
2434
2460
|
}
|
|
2435
2461
|
}
|
|
2436
2462
|
case 44: {
|
|
2437
|
-
if (
|
|
2463
|
+
if (_x_768.$tag === 44) {
|
|
2438
2464
|
return true;
|
|
2439
2465
|
} else {
|
|
2440
2466
|
return false;
|
|
2441
2467
|
}
|
|
2442
2468
|
}
|
|
2443
2469
|
case 45: {
|
|
2444
|
-
if (
|
|
2470
|
+
if (_x_768.$tag === 45) {
|
|
2445
2471
|
return true;
|
|
2446
2472
|
} else {
|
|
2447
2473
|
return false;
|
|
2448
2474
|
}
|
|
2449
2475
|
}
|
|
2450
2476
|
case 46: {
|
|
2451
|
-
if (
|
|
2477
|
+
if (_x_768.$tag === 46) {
|
|
2452
2478
|
return true;
|
|
2453
2479
|
} else {
|
|
2454
2480
|
return false;
|
|
2455
2481
|
}
|
|
2456
2482
|
}
|
|
2457
2483
|
case 47: {
|
|
2458
|
-
if (
|
|
2484
|
+
if (_x_768.$tag === 47) {
|
|
2459
2485
|
return true;
|
|
2460
2486
|
} else {
|
|
2461
2487
|
return false;
|
|
2462
2488
|
}
|
|
2463
2489
|
}
|
|
2464
2490
|
case 48: {
|
|
2465
|
-
if (
|
|
2491
|
+
if (_x_768.$tag === 48) {
|
|
2466
2492
|
return true;
|
|
2467
2493
|
} else {
|
|
2468
2494
|
return false;
|
|
2469
2495
|
}
|
|
2470
2496
|
}
|
|
2471
2497
|
case 49: {
|
|
2472
|
-
if (
|
|
2498
|
+
if (_x_768.$tag === 49) {
|
|
2473
2499
|
return true;
|
|
2474
2500
|
} else {
|
|
2475
2501
|
return false;
|
|
2476
2502
|
}
|
|
2477
2503
|
}
|
|
2478
2504
|
case 50: {
|
|
2479
|
-
if (
|
|
2505
|
+
if (_x_768.$tag === 50) {
|
|
2480
2506
|
return true;
|
|
2481
2507
|
} else {
|
|
2482
2508
|
return false;
|
|
2483
2509
|
}
|
|
2484
2510
|
}
|
|
2485
2511
|
case 51: {
|
|
2486
|
-
if (
|
|
2512
|
+
if (_x_768.$tag === 51) {
|
|
2487
2513
|
return true;
|
|
2488
2514
|
} else {
|
|
2489
2515
|
return false;
|
|
2490
2516
|
}
|
|
2491
2517
|
}
|
|
2492
2518
|
case 52: {
|
|
2493
|
-
if (
|
|
2519
|
+
if (_x_768.$tag === 52) {
|
|
2494
2520
|
return true;
|
|
2495
2521
|
} else {
|
|
2496
2522
|
return false;
|
|
2497
2523
|
}
|
|
2498
2524
|
}
|
|
2499
2525
|
case 53: {
|
|
2500
|
-
if (
|
|
2526
|
+
if (_x_768.$tag === 53) {
|
|
2501
2527
|
return true;
|
|
2502
2528
|
} else {
|
|
2503
2529
|
return false;
|
|
2504
2530
|
}
|
|
2505
2531
|
}
|
|
2506
2532
|
case 54: {
|
|
2507
|
-
if (
|
|
2533
|
+
if (_x_768.$tag === 54) {
|
|
2508
2534
|
return true;
|
|
2509
2535
|
} else {
|
|
2510
2536
|
return false;
|
|
2511
2537
|
}
|
|
2512
2538
|
}
|
|
2513
2539
|
case 55: {
|
|
2514
|
-
if (
|
|
2540
|
+
if (_x_768.$tag === 55) {
|
|
2515
2541
|
return true;
|
|
2516
2542
|
} else {
|
|
2517
2543
|
return false;
|
|
2518
2544
|
}
|
|
2519
2545
|
}
|
|
2520
2546
|
case 56: {
|
|
2521
|
-
if (
|
|
2547
|
+
if (_x_768.$tag === 56) {
|
|
2522
2548
|
return true;
|
|
2523
2549
|
} else {
|
|
2524
2550
|
return false;
|
|
2525
2551
|
}
|
|
2526
2552
|
}
|
|
2527
2553
|
case 57: {
|
|
2528
|
-
if (
|
|
2554
|
+
if (_x_768.$tag === 57) {
|
|
2529
2555
|
return true;
|
|
2530
2556
|
} else {
|
|
2531
2557
|
return false;
|
|
2532
2558
|
}
|
|
2533
2559
|
}
|
|
2534
2560
|
case 58: {
|
|
2535
|
-
if (
|
|
2561
|
+
if (_x_768.$tag === 58) {
|
|
2536
2562
|
return true;
|
|
2537
2563
|
} else {
|
|
2538
2564
|
return false;
|
|
2539
2565
|
}
|
|
2540
2566
|
}
|
|
2541
2567
|
case 59: {
|
|
2542
|
-
if (
|
|
2568
|
+
if (_x_768.$tag === 59) {
|
|
2543
2569
|
return true;
|
|
2544
2570
|
} else {
|
|
2545
2571
|
return false;
|
|
2546
2572
|
}
|
|
2547
2573
|
}
|
|
2548
2574
|
case 60: {
|
|
2549
|
-
if (
|
|
2575
|
+
if (_x_768.$tag === 60) {
|
|
2550
2576
|
return true;
|
|
2551
2577
|
} else {
|
|
2552
2578
|
return false;
|
|
2553
2579
|
}
|
|
2554
2580
|
}
|
|
2555
2581
|
case 61: {
|
|
2556
|
-
if (
|
|
2582
|
+
if (_x_768.$tag === 61) {
|
|
2557
2583
|
return true;
|
|
2558
2584
|
} else {
|
|
2559
2585
|
return false;
|
|
2560
2586
|
}
|
|
2561
2587
|
}
|
|
2562
2588
|
case 62: {
|
|
2563
|
-
if (
|
|
2589
|
+
if (_x_768.$tag === 62) {
|
|
2564
2590
|
return true;
|
|
2565
2591
|
} else {
|
|
2566
2592
|
return false;
|
|
2567
2593
|
}
|
|
2568
2594
|
}
|
|
2569
2595
|
case 63: {
|
|
2570
|
-
if (
|
|
2596
|
+
if (_x_768.$tag === 63) {
|
|
2571
2597
|
return true;
|
|
2572
2598
|
} else {
|
|
2573
2599
|
return false;
|
|
2574
2600
|
}
|
|
2575
2601
|
}
|
|
2576
2602
|
case 64: {
|
|
2577
|
-
if (
|
|
2603
|
+
if (_x_768.$tag === 64) {
|
|
2578
2604
|
return true;
|
|
2579
2605
|
} else {
|
|
2580
2606
|
return false;
|
|
2581
2607
|
}
|
|
2582
2608
|
}
|
|
2583
2609
|
case 65: {
|
|
2584
|
-
if (
|
|
2610
|
+
if (_x_768.$tag === 65) {
|
|
2585
2611
|
return true;
|
|
2586
2612
|
} else {
|
|
2587
2613
|
return false;
|
|
2588
2614
|
}
|
|
2589
2615
|
}
|
|
2590
2616
|
case 66: {
|
|
2591
|
-
if (
|
|
2617
|
+
if (_x_768.$tag === 66) {
|
|
2592
2618
|
return true;
|
|
2593
2619
|
} else {
|
|
2594
2620
|
return false;
|
|
2595
2621
|
}
|
|
2596
2622
|
}
|
|
2597
2623
|
case 67: {
|
|
2598
|
-
if (
|
|
2624
|
+
if (_x_768.$tag === 67) {
|
|
2599
2625
|
return true;
|
|
2600
2626
|
} else {
|
|
2601
2627
|
return false;
|
|
2602
2628
|
}
|
|
2603
2629
|
}
|
|
2604
2630
|
case 68: {
|
|
2605
|
-
if (
|
|
2631
|
+
if (_x_768.$tag === 68) {
|
|
2606
2632
|
return true;
|
|
2607
2633
|
} else {
|
|
2608
2634
|
return false;
|
|
2609
2635
|
}
|
|
2610
2636
|
}
|
|
2611
2637
|
case 69: {
|
|
2612
|
-
if (
|
|
2638
|
+
if (_x_768.$tag === 69) {
|
|
2613
2639
|
return true;
|
|
2614
2640
|
} else {
|
|
2615
2641
|
return false;
|
|
2616
2642
|
}
|
|
2617
2643
|
}
|
|
2618
2644
|
case 70: {
|
|
2619
|
-
if (
|
|
2645
|
+
if (_x_768.$tag === 70) {
|
|
2620
2646
|
return true;
|
|
2621
2647
|
} else {
|
|
2622
2648
|
return false;
|
|
2623
2649
|
}
|
|
2624
2650
|
}
|
|
2625
2651
|
case 71: {
|
|
2626
|
-
if (
|
|
2652
|
+
if (_x_768.$tag === 71) {
|
|
2627
2653
|
return true;
|
|
2628
2654
|
} else {
|
|
2629
2655
|
return false;
|
|
2630
2656
|
}
|
|
2631
2657
|
}
|
|
2632
2658
|
case 72: {
|
|
2633
|
-
if (
|
|
2659
|
+
if (_x_768.$tag === 72) {
|
|
2634
2660
|
return true;
|
|
2635
2661
|
} else {
|
|
2636
2662
|
return false;
|
|
2637
2663
|
}
|
|
2638
2664
|
}
|
|
2639
2665
|
case 73: {
|
|
2640
|
-
if (
|
|
2666
|
+
if (_x_768.$tag === 73) {
|
|
2641
2667
|
return true;
|
|
2642
2668
|
} else {
|
|
2643
2669
|
return false;
|
|
2644
2670
|
}
|
|
2645
2671
|
}
|
|
2646
2672
|
case 74: {
|
|
2647
|
-
if (
|
|
2673
|
+
if (_x_768.$tag === 74) {
|
|
2648
2674
|
return true;
|
|
2649
2675
|
} else {
|
|
2650
2676
|
return false;
|
|
2651
2677
|
}
|
|
2652
2678
|
}
|
|
2653
2679
|
case 75: {
|
|
2654
|
-
if (
|
|
2680
|
+
if (_x_768.$tag === 75) {
|
|
2655
2681
|
return true;
|
|
2656
2682
|
} else {
|
|
2657
2683
|
return false;
|
|
2658
2684
|
}
|
|
2659
2685
|
}
|
|
2660
2686
|
case 76: {
|
|
2661
|
-
if (
|
|
2687
|
+
if (_x_768.$tag === 76) {
|
|
2662
2688
|
return true;
|
|
2663
2689
|
} else {
|
|
2664
2690
|
return false;
|
|
2665
2691
|
}
|
|
2666
2692
|
}
|
|
2667
2693
|
case 77: {
|
|
2668
|
-
if (
|
|
2694
|
+
if (_x_768.$tag === 77) {
|
|
2669
2695
|
return true;
|
|
2670
2696
|
} else {
|
|
2671
2697
|
return false;
|
|
2672
2698
|
}
|
|
2673
2699
|
}
|
|
2674
2700
|
case 78: {
|
|
2675
|
-
if (
|
|
2701
|
+
if (_x_768.$tag === 78) {
|
|
2676
2702
|
return true;
|
|
2677
2703
|
} else {
|
|
2678
2704
|
return false;
|
|
2679
2705
|
}
|
|
2680
2706
|
}
|
|
2681
2707
|
case 79: {
|
|
2682
|
-
if (
|
|
2708
|
+
if (_x_768.$tag === 79) {
|
|
2683
2709
|
return true;
|
|
2684
2710
|
} else {
|
|
2685
2711
|
return false;
|
|
2686
2712
|
}
|
|
2687
2713
|
}
|
|
2688
2714
|
case 80: {
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
if (_x_715.$tag === 80) {
|
|
2692
|
-
const _Indent$2 = _x_715;
|
|
2693
|
-
const _$42$y0_729 = _Indent$2._0;
|
|
2694
|
-
_x0_728 = _$42$x0_728;
|
|
2695
|
-
_y0_729 = _$42$y0_729;
|
|
2696
|
-
break _L$4;
|
|
2715
|
+
if (_x_768.$tag === 80) {
|
|
2716
|
+
return true;
|
|
2697
2717
|
} else {
|
|
2698
2718
|
return false;
|
|
2699
2719
|
}
|
|
2700
2720
|
}
|
|
2701
2721
|
case 81: {
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
if (_x_715.$tag === 81) {
|
|
2705
|
-
const _Shebang$2 = _x_715;
|
|
2706
|
-
const _$42$y0_731 = _Shebang$2._0;
|
|
2707
|
-
_x0_730 = _$42$x0_730;
|
|
2708
|
-
_y0_731 = _$42$y0_731;
|
|
2709
|
-
break _L$3;
|
|
2722
|
+
if (_x_768.$tag === 81) {
|
|
2723
|
+
return true;
|
|
2710
2724
|
} else {
|
|
2711
2725
|
return false;
|
|
2712
2726
|
}
|
|
2713
2727
|
}
|
|
2714
2728
|
case 82: {
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
if (_x_715.$tag === 82) {
|
|
2718
|
-
const _Comment$2 = _x_715;
|
|
2719
|
-
const _$42$y0_733 = _Comment$2._0;
|
|
2720
|
-
_x0_732 = _$42$x0_732;
|
|
2721
|
-
_y0_733 = _$42$y0_733;
|
|
2722
|
-
break _L$2;
|
|
2729
|
+
if (_x_768.$tag === 82) {
|
|
2730
|
+
return true;
|
|
2723
2731
|
} else {
|
|
2724
2732
|
return false;
|
|
2725
2733
|
}
|
|
2726
2734
|
}
|
|
2727
2735
|
case 83: {
|
|
2728
|
-
const
|
|
2729
|
-
const _$42$
|
|
2730
|
-
if (
|
|
2731
|
-
const
|
|
2732
|
-
const _$42$
|
|
2733
|
-
|
|
2734
|
-
|
|
2736
|
+
const _Indent = _x_767;
|
|
2737
|
+
const _$42$x0_781 = _Indent._0;
|
|
2738
|
+
if (_x_768.$tag === 83) {
|
|
2739
|
+
const _Indent$2 = _x_768;
|
|
2740
|
+
const _$42$y0_782 = _Indent$2._0;
|
|
2741
|
+
_x0_781 = _$42$x0_781;
|
|
2742
|
+
_y0_782 = _$42$y0_782;
|
|
2743
|
+
break _L$4;
|
|
2744
|
+
} else {
|
|
2745
|
+
return false;
|
|
2746
|
+
}
|
|
2747
|
+
}
|
|
2748
|
+
case 84: {
|
|
2749
|
+
const _Shebang = _x_767;
|
|
2750
|
+
const _$42$x0_783 = _Shebang._0;
|
|
2751
|
+
if (_x_768.$tag === 84) {
|
|
2752
|
+
const _Shebang$2 = _x_768;
|
|
2753
|
+
const _$42$y0_784 = _Shebang$2._0;
|
|
2754
|
+
_x0_783 = _$42$x0_783;
|
|
2755
|
+
_y0_784 = _$42$y0_784;
|
|
2756
|
+
break _L$3;
|
|
2757
|
+
} else {
|
|
2758
|
+
return false;
|
|
2759
|
+
}
|
|
2760
|
+
}
|
|
2761
|
+
case 85: {
|
|
2762
|
+
const _Comment = _x_767;
|
|
2763
|
+
const _$42$x0_785 = _Comment._0;
|
|
2764
|
+
if (_x_768.$tag === 85) {
|
|
2765
|
+
const _Comment$2 = _x_768;
|
|
2766
|
+
const _$42$y0_786 = _Comment$2._0;
|
|
2767
|
+
_x0_785 = _$42$x0_785;
|
|
2768
|
+
_y0_786 = _$42$y0_786;
|
|
2769
|
+
break _L$2;
|
|
2770
|
+
} else {
|
|
2771
|
+
return false;
|
|
2772
|
+
}
|
|
2773
|
+
}
|
|
2774
|
+
case 86: {
|
|
2775
|
+
const _BlockComment = _x_767;
|
|
2776
|
+
const _$42$x0_787 = _BlockComment._0;
|
|
2777
|
+
if (_x_768.$tag === 86) {
|
|
2778
|
+
const _BlockComment$2 = _x_768;
|
|
2779
|
+
const _$42$y0_788 = _BlockComment$2._0;
|
|
2780
|
+
_x0_787 = _$42$x0_787;
|
|
2781
|
+
_y0_788 = _$42$y0_788;
|
|
2735
2782
|
break _L;
|
|
2736
2783
|
} else {
|
|
2737
2784
|
return false;
|
|
2738
2785
|
}
|
|
2739
2786
|
}
|
|
2740
2787
|
default: {
|
|
2741
|
-
if (
|
|
2788
|
+
if (_x_768.$tag === 87) {
|
|
2742
2789
|
return true;
|
|
2743
2790
|
} else {
|
|
2744
2791
|
return false;
|
|
@@ -2746,23 +2793,23 @@ function _M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_x_
|
|
|
2746
2793
|
}
|
|
2747
2794
|
}
|
|
2748
2795
|
}
|
|
2749
|
-
return
|
|
2796
|
+
return _x0_769 === _y0_770;
|
|
2750
2797
|
}
|
|
2751
|
-
return
|
|
2798
|
+
return _x0_771 === _y0_772;
|
|
2752
2799
|
}
|
|
2753
|
-
return
|
|
2800
|
+
return _x0_773 === _y0_774;
|
|
2754
2801
|
}
|
|
2755
|
-
return
|
|
2802
|
+
return _x0_775 === _y0_777 && _x1_776 === _y1_778;
|
|
2756
2803
|
}
|
|
2757
|
-
return
|
|
2804
|
+
return _x0_779 === _y0_780;
|
|
2758
2805
|
}
|
|
2759
|
-
return
|
|
2806
|
+
return _x0_781 === _y0_782;
|
|
2760
2807
|
}
|
|
2761
|
-
return
|
|
2808
|
+
return _x0_783 === _y0_784;
|
|
2762
2809
|
}
|
|
2763
|
-
return
|
|
2810
|
+
return _x0_785 === _y0_786;
|
|
2764
2811
|
}
|
|
2765
|
-
return
|
|
2812
|
+
return _x0_787 === _y0_788;
|
|
2766
2813
|
}
|
|
2767
2814
|
function _M0MP28username4core6Parser4peek(self) {
|
|
2768
2815
|
return self.pos >= self.tokens.length ? $64$username$47$core$46$TokenKind$Eof : _M0MP311moonbitlang4core5array5Array2atGRP28username4core5TokenE(self.tokens, self.pos).kind;
|
|
@@ -2869,19 +2916,19 @@ function _M0MP28username4core6Parser18parse__param__list(self) {
|
|
|
2869
2916
|
_L$3: {
|
|
2870
2917
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
2871
2918
|
switch (_bind.$tag) {
|
|
2872
|
-
case
|
|
2919
|
+
case 78: {
|
|
2873
2920
|
break _L$3;
|
|
2874
2921
|
}
|
|
2875
|
-
case
|
|
2922
|
+
case 82: {
|
|
2876
2923
|
break _L$3;
|
|
2877
2924
|
}
|
|
2878
|
-
case
|
|
2925
|
+
case 87: {
|
|
2879
2926
|
break _L$3;
|
|
2880
2927
|
}
|
|
2881
|
-
case
|
|
2928
|
+
case 29: {
|
|
2882
2929
|
break _L$3;
|
|
2883
2930
|
}
|
|
2884
|
-
case
|
|
2931
|
+
case 48: {
|
|
2885
2932
|
break _L$3;
|
|
2886
2933
|
}
|
|
2887
2934
|
case 6: {
|
|
@@ -2923,16 +2970,16 @@ function _M0MP28username4core6Parser27skip__newlines__and__indent(self) {
|
|
|
2923
2970
|
_L$4: {
|
|
2924
2971
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
2925
2972
|
switch (_bind.$tag) {
|
|
2926
|
-
case
|
|
2973
|
+
case 82: {
|
|
2927
2974
|
break _L$4;
|
|
2928
2975
|
}
|
|
2929
|
-
case
|
|
2976
|
+
case 85: {
|
|
2930
2977
|
break _L$4;
|
|
2931
2978
|
}
|
|
2932
|
-
case
|
|
2979
|
+
case 86: {
|
|
2933
2980
|
break _L$4;
|
|
2934
2981
|
}
|
|
2935
|
-
case
|
|
2982
|
+
case 83: {
|
|
2936
2983
|
const _Indent = _bind;
|
|
2937
2984
|
const _n = _Indent._0;
|
|
2938
2985
|
n = _n;
|
|
@@ -2966,10 +3013,10 @@ function _M0MP28username4core6Parser22skip__type__annotation(self) {
|
|
|
2966
3013
|
case 10: {
|
|
2967
3014
|
break _L$2;
|
|
2968
3015
|
}
|
|
2969
|
-
case
|
|
3016
|
+
case 82: {
|
|
2970
3017
|
break _L$2;
|
|
2971
3018
|
}
|
|
2972
|
-
case
|
|
3019
|
+
case 87: {
|
|
2973
3020
|
break _L$2;
|
|
2974
3021
|
}
|
|
2975
3022
|
default: {
|
|
@@ -3082,7 +3129,7 @@ function _M0MP28username4core6Parser21parse__bracket__names(self) {
|
|
|
3082
3129
|
s = _s;
|
|
3083
3130
|
break _L$2;
|
|
3084
3131
|
}
|
|
3085
|
-
case
|
|
3132
|
+
case 77: {
|
|
3086
3133
|
self.pos = self.pos + 1 | 0;
|
|
3087
3134
|
break;
|
|
3088
3135
|
}
|
|
@@ -3181,10 +3228,10 @@ function _M0MP28username4core6Parser21parse__match__pattern(self) {
|
|
|
3181
3228
|
self.pos = self.pos + 1 | 0;
|
|
3182
3229
|
return new $64$username$47$core$46$MatchPattern$LitPat(new $64$username$47$core$46$Expr$BoolLit(false));
|
|
3183
3230
|
}
|
|
3184
|
-
case
|
|
3231
|
+
case 70: {
|
|
3185
3232
|
break _L$2;
|
|
3186
3233
|
}
|
|
3187
|
-
case
|
|
3234
|
+
case 71: {
|
|
3188
3235
|
break _L$2;
|
|
3189
3236
|
}
|
|
3190
3237
|
case 6: {
|
|
@@ -3242,7 +3289,7 @@ function _M0MP28username4core6Parser9parse__or(self) {
|
|
|
3242
3289
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Or)) {
|
|
3243
3290
|
self.pos = self.pos + 1 | 0;
|
|
3244
3291
|
const right = _M0MP28username4core6Parser10parse__and(self);
|
|
3245
|
-
left.val = new $64$username$47$core$46$Expr$BinOp(
|
|
3292
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(13, left.val, right);
|
|
3246
3293
|
continue;
|
|
3247
3294
|
} else {
|
|
3248
3295
|
break;
|
|
@@ -3256,7 +3303,7 @@ function _M0MP28username4core6Parser10parse__and(self) {
|
|
|
3256
3303
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$And)) {
|
|
3257
3304
|
self.pos = self.pos + 1 | 0;
|
|
3258
3305
|
const right = _M0MP28username4core6Parser15parse__equality(self);
|
|
3259
|
-
left.val = new $64$username$47$core$46$Expr$BinOp(
|
|
3306
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(12, left.val, right);
|
|
3260
3307
|
continue;
|
|
3261
3308
|
} else {
|
|
3262
3309
|
break;
|
|
@@ -3272,19 +3319,34 @@ function _M0MP28username4core6Parser15parse__equality(self) {
|
|
|
3272
3319
|
_L$3: {
|
|
3273
3320
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
3274
3321
|
switch (_bind.$tag) {
|
|
3275
|
-
case
|
|
3322
|
+
case 18: {
|
|
3276
3323
|
break _L$3;
|
|
3277
3324
|
}
|
|
3278
|
-
case
|
|
3325
|
+
case 45: {
|
|
3279
3326
|
break _L$3;
|
|
3280
3327
|
}
|
|
3281
|
-
case
|
|
3328
|
+
case 19: {
|
|
3282
3329
|
self.pos = self.pos + 1 | 0;
|
|
3283
3330
|
const right = _M0MP28username4core6Parser17parse__comparison(self);
|
|
3284
|
-
left.val = new $64$username$47$core$46$Expr$BinOp(
|
|
3331
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(7, left.val, right);
|
|
3285
3332
|
break;
|
|
3286
3333
|
}
|
|
3287
|
-
case
|
|
3334
|
+
case 26: {
|
|
3335
|
+
if ((self.pos + 1 | 0) < self.tokens.length) {
|
|
3336
|
+
const _bind$2 = _M0MP311moonbitlang4core5array5Array2atGRP28username4core5TokenE(self.tokens, self.pos + 1 | 0).kind;
|
|
3337
|
+
if (_bind$2.$tag === 18) {
|
|
3338
|
+
self.pos = self.pos + 2 | 0;
|
|
3339
|
+
const right$2 = _M0MP28username4core6Parser17parse__comparison(self);
|
|
3340
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(7, left.val, right$2);
|
|
3341
|
+
} else {
|
|
3342
|
+
break _L;
|
|
3343
|
+
}
|
|
3344
|
+
} else {
|
|
3345
|
+
break _L;
|
|
3346
|
+
}
|
|
3347
|
+
break;
|
|
3348
|
+
}
|
|
3349
|
+
case 50: {
|
|
3288
3350
|
self.pos = self.pos + 1 | 0;
|
|
3289
3351
|
const right$2 = _M0MP28username4core6Parser17parse__comparison(self);
|
|
3290
3352
|
left.val = new $64$username$47$core$46$Expr$Instanceof(left.val, right$2);
|
|
@@ -3302,7 +3364,7 @@ function _M0MP28username4core6Parser15parse__equality(self) {
|
|
|
3302
3364
|
left.val = new $64$username$47$core$46$Expr$IsCheck(left.val, type_name);
|
|
3303
3365
|
} else {
|
|
3304
3366
|
const right = _M0MP28username4core6Parser17parse__comparison(self);
|
|
3305
|
-
left.val = new $64$username$47$core$46$Expr$BinOp(
|
|
3367
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(6, left.val, right);
|
|
3306
3368
|
}
|
|
3307
3369
|
}
|
|
3308
3370
|
continue;
|
|
@@ -3318,28 +3380,46 @@ function _M0MP28username4core6Parser17parse__comparison(self) {
|
|
|
3318
3380
|
if (self.pos < self.tokens.length) {
|
|
3319
3381
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
3320
3382
|
switch (_bind.$tag) {
|
|
3321
|
-
case
|
|
3383
|
+
case 20: {
|
|
3384
|
+
if ((self.pos + 1 | 0) < self.tokens.length) {
|
|
3385
|
+
const _bind$2 = _M0MP311moonbitlang4core5array5Array2atGRP28username4core5TokenE(self.tokens, self.pos + 1 | 0).kind;
|
|
3386
|
+
if (_bind$2.$tag === 18) {
|
|
3387
|
+
self.pos = self.pos + 2 | 0;
|
|
3388
|
+
const right = _M0MP28username4core6Parser15parse__addition(self);
|
|
3389
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(10, left.val, right);
|
|
3390
|
+
continue _L;
|
|
3391
|
+
}
|
|
3392
|
+
}
|
|
3322
3393
|
self.pos = self.pos + 1 | 0;
|
|
3323
3394
|
const right = _M0MP28username4core6Parser15parse__addition(self);
|
|
3324
|
-
left.val = new $64$username$47$core$46$Expr$BinOp(
|
|
3395
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(8, left.val, right);
|
|
3325
3396
|
break;
|
|
3326
3397
|
}
|
|
3327
|
-
case
|
|
3398
|
+
case 21: {
|
|
3399
|
+
if ((self.pos + 1 | 0) < self.tokens.length) {
|
|
3400
|
+
const _bind$2 = _M0MP311moonbitlang4core5array5Array2atGRP28username4core5TokenE(self.tokens, self.pos + 1 | 0).kind;
|
|
3401
|
+
if (_bind$2.$tag === 18) {
|
|
3402
|
+
self.pos = self.pos + 2 | 0;
|
|
3403
|
+
const right$2 = _M0MP28username4core6Parser15parse__addition(self);
|
|
3404
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(11, left.val, right$2);
|
|
3405
|
+
continue _L;
|
|
3406
|
+
}
|
|
3407
|
+
}
|
|
3328
3408
|
self.pos = self.pos + 1 | 0;
|
|
3329
3409
|
const right$2 = _M0MP28username4core6Parser15parse__addition(self);
|
|
3330
|
-
left.val = new $64$username$47$core$46$Expr$BinOp(
|
|
3410
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(9, left.val, right$2);
|
|
3331
3411
|
break;
|
|
3332
3412
|
}
|
|
3333
|
-
case
|
|
3413
|
+
case 22: {
|
|
3334
3414
|
self.pos = self.pos + 1 | 0;
|
|
3335
3415
|
const right$3 = _M0MP28username4core6Parser15parse__addition(self);
|
|
3336
|
-
left.val = new $64$username$47$core$46$Expr$BinOp(
|
|
3416
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(10, left.val, right$3);
|
|
3337
3417
|
break;
|
|
3338
3418
|
}
|
|
3339
|
-
case
|
|
3419
|
+
case 23: {
|
|
3340
3420
|
self.pos = self.pos + 1 | 0;
|
|
3341
3421
|
const right$4 = _M0MP28username4core6Parser15parse__addition(self);
|
|
3342
|
-
left.val = new $64$username$47$core$46$Expr$BinOp(
|
|
3422
|
+
left.val = new $64$username$47$core$46$Expr$BinOp(11, left.val, right$4);
|
|
3343
3423
|
break;
|
|
3344
3424
|
}
|
|
3345
3425
|
default: {
|
|
@@ -3383,26 +3463,26 @@ function _M0MP28username4core6Parser15parse__addition(self) {
|
|
|
3383
3463
|
return left.val;
|
|
3384
3464
|
}
|
|
3385
3465
|
function _M0MP28username4core6Parser21parse__multiplication(self) {
|
|
3386
|
-
const left = { val:
|
|
3466
|
+
const left = { val: _M0MP28username4core6Parser12parse__power(self) };
|
|
3387
3467
|
_L: while (true) {
|
|
3388
3468
|
if (self.pos < self.tokens.length) {
|
|
3389
3469
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
3390
3470
|
switch (_bind.$tag) {
|
|
3391
3471
|
case 13: {
|
|
3392
3472
|
self.pos = self.pos + 1 | 0;
|
|
3393
|
-
const right =
|
|
3473
|
+
const right = _M0MP28username4core6Parser12parse__power(self);
|
|
3394
3474
|
left.val = new $64$username$47$core$46$Expr$BinOp(2, left.val, right);
|
|
3395
3475
|
break;
|
|
3396
3476
|
}
|
|
3397
3477
|
case 14: {
|
|
3398
3478
|
self.pos = self.pos + 1 | 0;
|
|
3399
|
-
const right$2 =
|
|
3479
|
+
const right$2 = _M0MP28username4core6Parser12parse__power(self);
|
|
3400
3480
|
left.val = new $64$username$47$core$46$Expr$BinOp(3, left.val, right$2);
|
|
3401
3481
|
break;
|
|
3402
3482
|
}
|
|
3403
3483
|
case 15: {
|
|
3404
3484
|
self.pos = self.pos + 1 | 0;
|
|
3405
|
-
const right$3 =
|
|
3485
|
+
const right$3 = _M0MP28username4core6Parser12parse__power(self);
|
|
3406
3486
|
left.val = new $64$username$47$core$46$Expr$BinOp(4, left.val, right$3);
|
|
3407
3487
|
break;
|
|
3408
3488
|
}
|
|
@@ -3417,10 +3497,19 @@ function _M0MP28username4core6Parser21parse__multiplication(self) {
|
|
|
3417
3497
|
}
|
|
3418
3498
|
return left.val;
|
|
3419
3499
|
}
|
|
3500
|
+
function _M0MP28username4core6Parser12parse__power(self) {
|
|
3501
|
+
const left = _M0MP28username4core6Parser12parse__unary(self);
|
|
3502
|
+
if (self.pos < self.tokens.length && _M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Pow)) {
|
|
3503
|
+
self.pos = self.pos + 1 | 0;
|
|
3504
|
+
const right = _M0MP28username4core6Parser12parse__power(self);
|
|
3505
|
+
return new $64$username$47$core$46$Expr$BinOp(5, left, right);
|
|
3506
|
+
}
|
|
3507
|
+
return left;
|
|
3508
|
+
}
|
|
3420
3509
|
function _M0MP28username4core6Parser12parse__unary(self) {
|
|
3421
3510
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
3422
3511
|
switch (_bind.$tag) {
|
|
3423
|
-
case
|
|
3512
|
+
case 26: {
|
|
3424
3513
|
self.pos = self.pos + 1 | 0;
|
|
3425
3514
|
return new $64$username$47$core$46$Expr$UnaryNot(_M0MP28username4core6Parser12parse__unary(self));
|
|
3426
3515
|
}
|
|
@@ -3428,15 +3517,15 @@ function _M0MP28username4core6Parser12parse__unary(self) {
|
|
|
3428
3517
|
self.pos = self.pos + 1 | 0;
|
|
3429
3518
|
return new $64$username$47$core$46$Expr$UnaryNeg(_M0MP28username4core6Parser12parse__unary(self));
|
|
3430
3519
|
}
|
|
3431
|
-
case
|
|
3520
|
+
case 49: {
|
|
3432
3521
|
self.pos = self.pos + 1 | 0;
|
|
3433
3522
|
return new $64$username$47$core$46$Expr$UnaryTypeof(_M0MP28username4core6Parser12parse__unary(self));
|
|
3434
3523
|
}
|
|
3435
|
-
case
|
|
3524
|
+
case 55: {
|
|
3436
3525
|
self.pos = self.pos + 1 | 0;
|
|
3437
3526
|
return new $64$username$47$core$46$Expr$AwaitExpr(_M0MP28username4core6Parser12parse__unary(self));
|
|
3438
3527
|
}
|
|
3439
|
-
case
|
|
3528
|
+
case 51: {
|
|
3440
3529
|
self.pos = self.pos + 1 | 0;
|
|
3441
3530
|
const callee = _M0MP28username4core6Parser14parse__primary(self);
|
|
3442
3531
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$LBracket)) {
|
|
@@ -3490,37 +3579,64 @@ function _M0MP28username4core6Parser14parse__postfix(self) {
|
|
|
3490
3579
|
if (self.pos < self.tokens.length) {
|
|
3491
3580
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
3492
3581
|
switch (_bind.$tag) {
|
|
3493
|
-
case
|
|
3582
|
+
case 79: {
|
|
3494
3583
|
self.pos = self.pos + 1 | 0;
|
|
3495
3584
|
const field = _M0MP28username4core6Parser18parse__ident__name(self);
|
|
3496
3585
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$LBracket)) {
|
|
3497
|
-
const
|
|
3498
|
-
|
|
3586
|
+
const saved_dot = self.pos;
|
|
3587
|
+
self.pos = self.pos + 1 | 0;
|
|
3588
|
+
const start_expr = _M0MP28username4core6Parser11parse__expr(self);
|
|
3589
|
+
const _bind$2 = _M0MP28username4core6Parser4peek(self);
|
|
3590
|
+
switch (_bind$2.$tag) {
|
|
3591
|
+
case 80: {
|
|
3592
|
+
self.pos = self.pos + 1 | 0;
|
|
3593
|
+
const end_expr = _M0MP28username4core6Parser11parse__expr(self);
|
|
3594
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$RBracket)) {
|
|
3595
|
+
self.pos = self.pos + 1 | 0;
|
|
3596
|
+
}
|
|
3597
|
+
expr.val = new $64$username$47$core$46$Expr$Slice(new $64$username$47$core$46$Expr$DotAccess(expr.val, field), start_expr, end_expr, true);
|
|
3598
|
+
break;
|
|
3599
|
+
}
|
|
3600
|
+
case 81: {
|
|
3601
|
+
self.pos = self.pos + 1 | 0;
|
|
3602
|
+
const end_expr$2 = _M0MP28username4core6Parser11parse__expr(self);
|
|
3603
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$RBracket)) {
|
|
3604
|
+
self.pos = self.pos + 1 | 0;
|
|
3605
|
+
}
|
|
3606
|
+
expr.val = new $64$username$47$core$46$Expr$Slice(new $64$username$47$core$46$Expr$DotAccess(expr.val, field), start_expr, end_expr$2, false);
|
|
3607
|
+
break;
|
|
3608
|
+
}
|
|
3609
|
+
default: {
|
|
3610
|
+
self.pos = saved_dot;
|
|
3611
|
+
const args = _M0MP28username4core6Parser11parse__args(self);
|
|
3612
|
+
expr.val = new $64$username$47$core$46$Expr$MethodCall(expr.val, field, args);
|
|
3613
|
+
}
|
|
3614
|
+
}
|
|
3499
3615
|
} else {
|
|
3500
3616
|
expr.val = new $64$username$47$core$46$Expr$DotAccess(expr.val, field);
|
|
3501
3617
|
}
|
|
3502
3618
|
break;
|
|
3503
3619
|
}
|
|
3504
|
-
case
|
|
3620
|
+
case 75: {
|
|
3505
3621
|
const saved = self.pos;
|
|
3506
3622
|
self.pos = self.pos + 1 | 0;
|
|
3507
3623
|
_L$2: {
|
|
3508
3624
|
_L$3: {
|
|
3509
3625
|
const _bind$2 = expr.val;
|
|
3510
3626
|
switch (_bind$2.$tag) {
|
|
3511
|
-
case
|
|
3627
|
+
case 12: {
|
|
3512
3628
|
break _L$3;
|
|
3513
3629
|
}
|
|
3514
|
-
case
|
|
3630
|
+
case 13: {
|
|
3515
3631
|
break _L$3;
|
|
3516
3632
|
}
|
|
3517
|
-
case
|
|
3633
|
+
case 25: {
|
|
3518
3634
|
break _L$3;
|
|
3519
3635
|
}
|
|
3520
|
-
case
|
|
3636
|
+
case 24: {
|
|
3521
3637
|
break _L$3;
|
|
3522
3638
|
}
|
|
3523
|
-
case
|
|
3639
|
+
case 14: {
|
|
3524
3640
|
break _L$3;
|
|
3525
3641
|
}
|
|
3526
3642
|
default: {
|
|
@@ -3533,13 +3649,37 @@ function _M0MP28username4core6Parser14parse__postfix(self) {
|
|
|
3533
3649
|
}
|
|
3534
3650
|
break _L$2;
|
|
3535
3651
|
}
|
|
3536
|
-
|
|
3537
|
-
const
|
|
3538
|
-
|
|
3652
|
+
const start_expr = _M0MP28username4core6Parser11parse__expr(self);
|
|
3653
|
+
const _bind$2 = _M0MP28username4core6Parser4peek(self);
|
|
3654
|
+
switch (_bind$2.$tag) {
|
|
3655
|
+
case 80: {
|
|
3656
|
+
self.pos = self.pos + 1 | 0;
|
|
3657
|
+
const end_expr = _M0MP28username4core6Parser11parse__expr(self);
|
|
3658
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$RBracket)) {
|
|
3659
|
+
self.pos = self.pos + 1 | 0;
|
|
3660
|
+
}
|
|
3661
|
+
expr.val = new $64$username$47$core$46$Expr$Slice(expr.val, start_expr, end_expr, true);
|
|
3662
|
+
break;
|
|
3663
|
+
}
|
|
3664
|
+
case 81: {
|
|
3665
|
+
self.pos = self.pos + 1 | 0;
|
|
3666
|
+
const end_expr$2 = _M0MP28username4core6Parser11parse__expr(self);
|
|
3667
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$RBracket)) {
|
|
3668
|
+
self.pos = self.pos + 1 | 0;
|
|
3669
|
+
}
|
|
3670
|
+
expr.val = new $64$username$47$core$46$Expr$Slice(expr.val, start_expr, end_expr$2, false);
|
|
3671
|
+
break;
|
|
3672
|
+
}
|
|
3673
|
+
default: {
|
|
3674
|
+
self.pos = saved;
|
|
3675
|
+
const args = _M0MP28username4core6Parser11parse__args(self);
|
|
3676
|
+
expr.val = new $64$username$47$core$46$Expr$Call(expr.val, args);
|
|
3677
|
+
}
|
|
3678
|
+
}
|
|
3539
3679
|
}
|
|
3540
3680
|
break;
|
|
3541
3681
|
}
|
|
3542
|
-
case
|
|
3682
|
+
case 46: {
|
|
3543
3683
|
self.pos = self.pos + 1 | 0;
|
|
3544
3684
|
const type_name = _M0MP28username4core6Parser18parse__ident__name(self);
|
|
3545
3685
|
expr.val = new $64$username$47$core$46$Expr$AsCast(expr.val, type_name);
|
|
@@ -3605,17 +3745,17 @@ function _M0MP28username4core6Parser14parse__primary(self) {
|
|
|
3605
3745
|
self.pos = self.pos + 1 | 0;
|
|
3606
3746
|
return new $64$username$47$core$46$Expr$BoolLit(false);
|
|
3607
3747
|
}
|
|
3608
|
-
case 69: {
|
|
3609
|
-
break _L$2;
|
|
3610
|
-
}
|
|
3611
3748
|
case 70: {
|
|
3612
3749
|
break _L$2;
|
|
3613
3750
|
}
|
|
3614
3751
|
case 71: {
|
|
3752
|
+
break _L$2;
|
|
3753
|
+
}
|
|
3754
|
+
case 72: {
|
|
3615
3755
|
self.pos = self.pos + 1 | 0;
|
|
3616
3756
|
return $64$username$47$core$46$Expr$UndefinedLit;
|
|
3617
3757
|
}
|
|
3618
|
-
case
|
|
3758
|
+
case 53: {
|
|
3619
3759
|
self.pos = self.pos + 1 | 0;
|
|
3620
3760
|
return $64$username$47$core$46$Expr$ThisExpr;
|
|
3621
3761
|
}
|
|
@@ -3625,21 +3765,21 @@ function _M0MP28username4core6Parser14parse__primary(self) {
|
|
|
3625
3765
|
s = _s$2;
|
|
3626
3766
|
break _L;
|
|
3627
3767
|
}
|
|
3628
|
-
case
|
|
3768
|
+
case 73: {
|
|
3629
3769
|
self.pos = self.pos + 1 | 0;
|
|
3630
3770
|
return _M0MP28username4core6Parser20parse__list__literal(self);
|
|
3631
3771
|
}
|
|
3632
|
-
case
|
|
3772
|
+
case 74: {
|
|
3633
3773
|
self.pos = self.pos + 1 | 0;
|
|
3634
3774
|
return _M0MP28username4core6Parser22parse__object__literal(self);
|
|
3635
3775
|
}
|
|
3636
|
-
case
|
|
3776
|
+
case 75: {
|
|
3637
3777
|
return _M0MP28username4core6Parser20parse__bracket__expr(self);
|
|
3638
3778
|
}
|
|
3639
|
-
case
|
|
3779
|
+
case 27: {
|
|
3640
3780
|
return _M0MP28username4core6Parser15parse__fn__expr(self);
|
|
3641
3781
|
}
|
|
3642
|
-
case
|
|
3782
|
+
case 30: {
|
|
3643
3783
|
self.pos = self.pos + 1 | 0;
|
|
3644
3784
|
const cond = _M0MP28username4core6Parser11parse__expr(self);
|
|
3645
3785
|
_M0MP28username4core6Parser6expect(self, $64$username$47$core$46$TokenKind$Then_);
|
|
@@ -3648,14 +3788,14 @@ function _M0MP28username4core6Parser14parse__primary(self) {
|
|
|
3648
3788
|
const else_expr = _M0MP28username4core6Parser11parse__expr(self);
|
|
3649
3789
|
return new $64$username$47$core$46$Expr$IfExpr(cond, then_expr, else_expr);
|
|
3650
3790
|
}
|
|
3651
|
-
case
|
|
3791
|
+
case 42: {
|
|
3652
3792
|
self.pos = self.pos + 1 | 0;
|
|
3653
3793
|
const subject = _M0MP28username4core6Parser11parse__expr(self);
|
|
3654
3794
|
const indent = _M0MP28username4core6Parser27skip__newlines__and__indent(self);
|
|
3655
3795
|
const arms = _M0MP28username4core6Parser18parse__match__arms(self, indent);
|
|
3656
3796
|
return new $64$username$47$core$46$Expr$MatchExpr(subject, arms);
|
|
3657
3797
|
}
|
|
3658
|
-
case
|
|
3798
|
+
case 56: {
|
|
3659
3799
|
self.pos = self.pos + 1 | 0;
|
|
3660
3800
|
const tr_indent = _M0MP28username4core6Parser27skip__newlines__and__indent(self);
|
|
3661
3801
|
const try_body = _M0MP28username4core6Parser12parse__block(self, tr_indent);
|
|
@@ -3663,7 +3803,7 @@ function _M0MP28username4core6Parser14parse__primary(self) {
|
|
|
3663
3803
|
_M0MP28username4core6Parser27skip__newlines__and__indent(self);
|
|
3664
3804
|
const _bind$2 = _M0MP28username4core6Parser4peek(self);
|
|
3665
3805
|
let catch_name;
|
|
3666
|
-
if (_bind$2.$tag ===
|
|
3806
|
+
if (_bind$2.$tag === 57) {
|
|
3667
3807
|
self.pos = self.pos + 1 | 0;
|
|
3668
3808
|
let s$3;
|
|
3669
3809
|
_L$7: {
|
|
@@ -3767,13 +3907,13 @@ function _M0MP28username4core6Parser11parse__stmt(self) {
|
|
|
3767
3907
|
_L$2: {
|
|
3768
3908
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
3769
3909
|
switch (_bind.$tag) {
|
|
3770
|
-
case
|
|
3910
|
+
case 85: {
|
|
3771
3911
|
break _L$2;
|
|
3772
3912
|
}
|
|
3773
|
-
case
|
|
3913
|
+
case 86: {
|
|
3774
3914
|
break _L$2;
|
|
3775
3915
|
}
|
|
3776
|
-
case
|
|
3916
|
+
case 83: {
|
|
3777
3917
|
self.pos = self.pos + 1 | 0;
|
|
3778
3918
|
break;
|
|
3779
3919
|
}
|
|
@@ -3794,43 +3934,43 @@ function _M0MP28username4core6Parser11parse__stmt(self) {
|
|
|
3794
3934
|
case 9: {
|
|
3795
3935
|
return _M0MP28username4core6Parser16parse__var__decl(self, 2);
|
|
3796
3936
|
}
|
|
3797
|
-
case
|
|
3937
|
+
case 27: {
|
|
3798
3938
|
return _M0MP28username4core6Parser15parse__fn__decl(self, false);
|
|
3799
3939
|
}
|
|
3800
|
-
case
|
|
3940
|
+
case 54: {
|
|
3801
3941
|
self.pos = self.pos + 1 | 0;
|
|
3802
3942
|
return _M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Fn) ? _M0MP28username4core6Parser15parse__fn__decl(self, true) : new $64$username$47$core$46$Stmt$ExprStmt(_M0MP28username4core6Parser11parse__expr(self));
|
|
3803
3943
|
}
|
|
3804
|
-
case
|
|
3944
|
+
case 30: {
|
|
3805
3945
|
return _M0MP28username4core6Parser15parse__if__stmt(self);
|
|
3806
3946
|
}
|
|
3807
|
-
case
|
|
3947
|
+
case 33: {
|
|
3808
3948
|
return _M0MP28username4core6Parser19parse__unless__stmt(self);
|
|
3809
3949
|
}
|
|
3810
|
-
case
|
|
3950
|
+
case 35: {
|
|
3811
3951
|
return _M0MP28username4core6Parser18parse__while__stmt(self);
|
|
3812
3952
|
}
|
|
3813
|
-
case
|
|
3953
|
+
case 36: {
|
|
3814
3954
|
return _M0MP28username4core6Parser18parse__until__stmt(self);
|
|
3815
3955
|
}
|
|
3816
|
-
case
|
|
3956
|
+
case 37: {
|
|
3817
3957
|
return _M0MP28username4core6Parser16parse__for__stmt(self);
|
|
3818
3958
|
}
|
|
3819
|
-
case
|
|
3959
|
+
case 42: {
|
|
3820
3960
|
return _M0MP28username4core6Parser18parse__match__stmt(self);
|
|
3821
3961
|
}
|
|
3822
|
-
case
|
|
3962
|
+
case 28: {
|
|
3823
3963
|
self.pos = self.pos + 1 | 0;
|
|
3824
3964
|
_L$2: {
|
|
3825
3965
|
const _bind$2 = _M0MP28username4core6Parser4peek(self);
|
|
3826
3966
|
switch (_bind$2.$tag) {
|
|
3827
|
-
case
|
|
3967
|
+
case 82: {
|
|
3828
3968
|
break _L$2;
|
|
3829
3969
|
}
|
|
3830
|
-
case
|
|
3970
|
+
case 87: {
|
|
3831
3971
|
break _L$2;
|
|
3832
3972
|
}
|
|
3833
|
-
case
|
|
3973
|
+
case 83: {
|
|
3834
3974
|
break _L$2;
|
|
3835
3975
|
}
|
|
3836
3976
|
default: {
|
|
@@ -3840,38 +3980,38 @@ function _M0MP28username4core6Parser11parse__stmt(self) {
|
|
|
3840
3980
|
}
|
|
3841
3981
|
return new $64$username$47$core$46$Stmt$Return(undefined);
|
|
3842
3982
|
}
|
|
3843
|
-
case
|
|
3983
|
+
case 40: {
|
|
3844
3984
|
self.pos = self.pos + 1 | 0;
|
|
3845
3985
|
return $64$username$47$core$46$Stmt$Break;
|
|
3846
3986
|
}
|
|
3847
|
-
case
|
|
3987
|
+
case 41: {
|
|
3848
3988
|
self.pos = self.pos + 1 | 0;
|
|
3849
3989
|
return $64$username$47$core$46$Stmt$Continue;
|
|
3850
3990
|
}
|
|
3851
|
-
case
|
|
3991
|
+
case 56: {
|
|
3852
3992
|
return _M0MP28username4core6Parser16parse__try__stmt(self);
|
|
3853
3993
|
}
|
|
3854
|
-
case
|
|
3994
|
+
case 59: {
|
|
3855
3995
|
self.pos = self.pos + 1 | 0;
|
|
3856
3996
|
const expr = _M0MP28username4core6Parser11parse__expr(self);
|
|
3857
3997
|
return _M0MP28username4core6Parser14maybe__postfix(self, new $64$username$47$core$46$Stmt$Throw(expr));
|
|
3858
3998
|
}
|
|
3859
|
-
case
|
|
3999
|
+
case 60: {
|
|
3860
4000
|
return _M0MP28username4core6Parser19parse__import__stmt(self);
|
|
3861
4001
|
}
|
|
3862
|
-
case
|
|
4002
|
+
case 65: {
|
|
3863
4003
|
return _M0MP28username4core6Parser16parse__use__stmt(self);
|
|
3864
4004
|
}
|
|
3865
|
-
case
|
|
4005
|
+
case 61: {
|
|
3866
4006
|
return _M0MP28username4core6Parser22parse__from__use__stmt(self);
|
|
3867
4007
|
}
|
|
3868
|
-
case
|
|
4008
|
+
case 66: {
|
|
3869
4009
|
return _M0MP28username4core6Parser16parse__mod__stmt(self);
|
|
3870
4010
|
}
|
|
3871
|
-
case
|
|
4011
|
+
case 62: {
|
|
3872
4012
|
return _M0MP28username4core6Parser19parse__export__stmt(self);
|
|
3873
4013
|
}
|
|
3874
|
-
case
|
|
4014
|
+
case 67: {
|
|
3875
4015
|
self.pos = self.pos + 1 | 0;
|
|
3876
4016
|
let s;
|
|
3877
4017
|
_L$3: {
|
|
@@ -3887,11 +4027,11 @@ function _M0MP28username4core6Parser11parse__stmt(self) {
|
|
|
3887
4027
|
}
|
|
3888
4028
|
return new $64$username$47$core$46$Stmt$PubDecl(s);
|
|
3889
4029
|
}
|
|
3890
|
-
case
|
|
4030
|
+
case 52: {
|
|
3891
4031
|
self.pos = self.pos + 1 | 0;
|
|
3892
4032
|
return new $64$username$47$core$46$Stmt$DeleteStmt(_M0MP28username4core6Parser11parse__expr(self));
|
|
3893
4033
|
}
|
|
3894
|
-
case
|
|
4034
|
+
case 69: {
|
|
3895
4035
|
return _M0MP28username4core6Parser17parse__type__decl(self);
|
|
3896
4036
|
}
|
|
3897
4037
|
default: {
|
|
@@ -3909,17 +4049,17 @@ function _M0MP28username4core6Parser11parse__stmt(self) {
|
|
|
3909
4049
|
function _M0MP28username4core6Parser14maybe__postfix(self, stmt) {
|
|
3910
4050
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
3911
4051
|
switch (_bind.$tag) {
|
|
3912
|
-
case
|
|
4052
|
+
case 30: {
|
|
3913
4053
|
self.pos = self.pos + 1 | 0;
|
|
3914
4054
|
const cond = _M0MP28username4core6Parser11parse__expr(self);
|
|
3915
4055
|
return new $64$username$47$core$46$Stmt$PostfixIf(stmt, cond);
|
|
3916
4056
|
}
|
|
3917
|
-
case
|
|
4057
|
+
case 33: {
|
|
3918
4058
|
self.pos = self.pos + 1 | 0;
|
|
3919
4059
|
const cond$2 = _M0MP28username4core6Parser11parse__expr(self);
|
|
3920
4060
|
return new $64$username$47$core$46$Stmt$PostfixUnless(stmt, cond$2);
|
|
3921
4061
|
}
|
|
3922
|
-
case
|
|
4062
|
+
case 37: {
|
|
3923
4063
|
self.pos = self.pos + 1 | 0;
|
|
3924
4064
|
const name = _M0MP28username4core6Parser18parse__ident__name(self);
|
|
3925
4065
|
_M0MP28username4core6Parser6expect(self, $64$username$47$core$46$TokenKind$In_);
|
|
@@ -4040,7 +4180,7 @@ function _M0MP28username4core6Parser15parse__if__stmt(self) {
|
|
|
4040
4180
|
_M0MP28username4core6Parser27skip__newlines__and__indent(self);
|
|
4041
4181
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
4042
4182
|
switch (_bind.$tag) {
|
|
4043
|
-
case
|
|
4183
|
+
case 31: {
|
|
4044
4184
|
self.pos = self.pos + 1 | 0;
|
|
4045
4185
|
const elif_cond = _M0MP28username4core6Parser11parse__expr(self);
|
|
4046
4186
|
const elif_indent = _M0MP28username4core6Parser27skip__newlines__and__indent(self);
|
|
@@ -4048,7 +4188,7 @@ function _M0MP28username4core6Parser15parse__if__stmt(self) {
|
|
|
4048
4188
|
_M0MP311moonbitlang4core5array5Array4pushGRP28username4core10ElIfBranchE(elifs, { cond: elif_cond, body: elif_body });
|
|
4049
4189
|
break;
|
|
4050
4190
|
}
|
|
4051
|
-
case
|
|
4191
|
+
case 32: {
|
|
4052
4192
|
self.pos = self.pos + 1 | 0;
|
|
4053
4193
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$If_)) {
|
|
4054
4194
|
self.pos = self.pos + 1 | 0;
|
|
@@ -4108,7 +4248,7 @@ function _M0MP28username4core6Parser18parse__match__arms(self, min_indent) {
|
|
|
4108
4248
|
function _M0MP28username4core6Parser22parse__one__match__arm(self, arms) {
|
|
4109
4249
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
4110
4250
|
switch (_bind.$tag) {
|
|
4111
|
-
case
|
|
4251
|
+
case 43: {
|
|
4112
4252
|
self.pos = self.pos + 1 | 0;
|
|
4113
4253
|
const pattern = _M0MP28username4core6Parser21parse__match__pattern(self);
|
|
4114
4254
|
let cond_val;
|
|
@@ -4129,7 +4269,7 @@ function _M0MP28username4core6Parser22parse__one__match__arm(self, arms) {
|
|
|
4129
4269
|
_M0MP311moonbitlang4core5array5Array4pushGRP28username4core8MatchArmE(arms, { pattern: pattern, cond: cond_val, body: body });
|
|
4130
4270
|
return true;
|
|
4131
4271
|
}
|
|
4132
|
-
case
|
|
4272
|
+
case 32: {
|
|
4133
4273
|
self.pos = self.pos + 1 | 0;
|
|
4134
4274
|
let body$2;
|
|
4135
4275
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Then_) || _M0IP016_24default__implP311moonbitlang4core7builtin2Eq10not__equalGRP28username4core9TokenKindE(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Newline)) {
|
|
@@ -4222,6 +4362,28 @@ function _M0MP28username4core6Parser18parse__until__stmt(self) {
|
|
|
4222
4362
|
}
|
|
4223
4363
|
function _M0MP28username4core6Parser16parse__var__decl(self, kind) {
|
|
4224
4364
|
self.pos = self.pos + 1 | 0;
|
|
4365
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$LBracket)) {
|
|
4366
|
+
self.pos = self.pos + 1 | 0;
|
|
4367
|
+
const names = [];
|
|
4368
|
+
while (true) {
|
|
4369
|
+
if (self.pos < self.tokens.length && _M0IP016_24default__implP311moonbitlang4core7builtin2Eq10not__equalGRP28username4core9TokenKindE(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$RBracket)) {
|
|
4370
|
+
const name = _M0MP28username4core6Parser18parse__ident__name(self);
|
|
4371
|
+
_M0MP311moonbitlang4core5array5Array4pushGsE(names, name);
|
|
4372
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Semicolon) || _M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Comma)) {
|
|
4373
|
+
self.pos = self.pos + 1 | 0;
|
|
4374
|
+
}
|
|
4375
|
+
continue;
|
|
4376
|
+
} else {
|
|
4377
|
+
break;
|
|
4378
|
+
}
|
|
4379
|
+
}
|
|
4380
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$RBracket)) {
|
|
4381
|
+
self.pos = self.pos + 1 | 0;
|
|
4382
|
+
}
|
|
4383
|
+
_M0MP28username4core6Parser6expect(self, $64$username$47$core$46$TokenKind$Be);
|
|
4384
|
+
const value = _M0MP28username4core6Parser11parse__expr(self);
|
|
4385
|
+
return _M0MP28username4core6Parser14maybe__postfix(self, new $64$username$47$core$46$Stmt$DestructDecl(kind, names, value));
|
|
4386
|
+
}
|
|
4225
4387
|
const name = _M0MP28username4core6Parser18parse__ident__name(self);
|
|
4226
4388
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Of)) {
|
|
4227
4389
|
self.pos = self.pos + 1 | 0;
|
|
@@ -4255,10 +4417,26 @@ function _M0MP28username4core6Parser20parse__bracket__expr(self) {
|
|
|
4255
4417
|
const first = _M0MP28username4core6Parser11parse__expr(self);
|
|
4256
4418
|
const _bind = _M0MP28username4core6Parser4peek(self);
|
|
4257
4419
|
switch (_bind.$tag) {
|
|
4420
|
+
case 80: {
|
|
4421
|
+
self.pos = self.pos + 1 | 0;
|
|
4422
|
+
const end_expr = _M0MP28username4core6Parser11parse__expr(self);
|
|
4423
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$RBracket)) {
|
|
4424
|
+
self.pos = self.pos + 1 | 0;
|
|
4425
|
+
}
|
|
4426
|
+
return new $64$username$47$core$46$Expr$RangeArray(first, end_expr, true);
|
|
4427
|
+
}
|
|
4428
|
+
case 81: {
|
|
4429
|
+
self.pos = self.pos + 1 | 0;
|
|
4430
|
+
const end_expr$2 = _M0MP28username4core6Parser11parse__expr(self);
|
|
4431
|
+
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$RBracket)) {
|
|
4432
|
+
self.pos = self.pos + 1 | 0;
|
|
4433
|
+
}
|
|
4434
|
+
return new $64$username$47$core$46$Expr$RangeArray(first, end_expr$2, false);
|
|
4435
|
+
}
|
|
4258
4436
|
case 10: {
|
|
4259
4437
|
let key_name;
|
|
4260
4438
|
switch (first.$tag) {
|
|
4261
|
-
case
|
|
4439
|
+
case 12: {
|
|
4262
4440
|
const _Ident = first;
|
|
4263
4441
|
const _s = _Ident._0;
|
|
4264
4442
|
key_name = _s;
|
|
@@ -4297,7 +4475,7 @@ function _M0MP28username4core6Parser20parse__bracket__expr(self) {
|
|
|
4297
4475
|
}
|
|
4298
4476
|
return new $64$username$47$core$46$Expr$ObjectLit(pairs);
|
|
4299
4477
|
}
|
|
4300
|
-
case
|
|
4478
|
+
case 77: {
|
|
4301
4479
|
const elements = [first];
|
|
4302
4480
|
while (true) {
|
|
4303
4481
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Comma)) {
|
|
@@ -4316,7 +4494,7 @@ function _M0MP28username4core6Parser20parse__bracket__expr(self) {
|
|
|
4316
4494
|
}
|
|
4317
4495
|
return new $64$username$47$core$46$Expr$ArrayLit(elements);
|
|
4318
4496
|
}
|
|
4319
|
-
case
|
|
4497
|
+
case 78: {
|
|
4320
4498
|
const elements$2 = [first];
|
|
4321
4499
|
while (true) {
|
|
4322
4500
|
if (_M0IP28username4core9TokenKindP311moonbitlang4core7builtin2Eq5equal(_M0MP28username4core6Parser4peek(self), $64$username$47$core$46$TokenKind$Semicolon)) {
|
|
@@ -4335,7 +4513,7 @@ function _M0MP28username4core6Parser20parse__bracket__expr(self) {
|
|
|
4335
4513
|
}
|
|
4336
4514
|
return new $64$username$47$core$46$Expr$ArrayLit(elements$2);
|
|
4337
4515
|
}
|
|
4338
|
-
case
|
|
4516
|
+
case 76: {
|
|
4339
4517
|
self.pos = self.pos + 1 | 0;
|
|
4340
4518
|
return first;
|
|
4341
4519
|
}
|
|
@@ -4548,31 +4726,31 @@ function _M0MP28username4core5Lexer25is__neg__literal__context(self) {
|
|
|
4548
4726
|
const last = _M0MP311moonbitlang4core5array5Array2atGRP28username4core5TokenE(self.tokens, self.tokens.length - 1 | 0);
|
|
4549
4727
|
const _bind = last.kind;
|
|
4550
4728
|
switch (_bind.$tag) {
|
|
4551
|
-
case
|
|
4729
|
+
case 75: {
|
|
4552
4730
|
return true;
|
|
4553
4731
|
}
|
|
4554
|
-
case
|
|
4732
|
+
case 77: {
|
|
4555
4733
|
return true;
|
|
4556
4734
|
}
|
|
4557
|
-
case
|
|
4735
|
+
case 78: {
|
|
4558
4736
|
return true;
|
|
4559
4737
|
}
|
|
4560
4738
|
case 10: {
|
|
4561
4739
|
return true;
|
|
4562
4740
|
}
|
|
4563
|
-
case
|
|
4741
|
+
case 82: {
|
|
4564
4742
|
return true;
|
|
4565
4743
|
}
|
|
4566
|
-
case
|
|
4744
|
+
case 83: {
|
|
4567
4745
|
return true;
|
|
4568
4746
|
}
|
|
4569
|
-
case
|
|
4747
|
+
case 28: {
|
|
4570
4748
|
return true;
|
|
4571
4749
|
}
|
|
4572
|
-
case
|
|
4750
|
+
case 29: {
|
|
4573
4751
|
return true;
|
|
4574
4752
|
}
|
|
4575
|
-
case
|
|
4753
|
+
case 34: {
|
|
4576
4754
|
return true;
|
|
4577
4755
|
}
|
|
4578
4756
|
default: {
|
|
@@ -4659,12 +4837,16 @@ function _M0MP28username4core5Lexer11scan__ident(self) {
|
|
|
4659
4837
|
kind = $64$username$47$core$46$TokenKind$Neg;
|
|
4660
4838
|
break;
|
|
4661
4839
|
}
|
|
4840
|
+
case "pow": {
|
|
4841
|
+
kind = $64$username$47$core$46$TokenKind$Pow;
|
|
4842
|
+
break;
|
|
4843
|
+
}
|
|
4662
4844
|
case "eq": {
|
|
4663
4845
|
kind = $64$username$47$core$46$TokenKind$Eq;
|
|
4664
4846
|
break;
|
|
4665
4847
|
}
|
|
4666
|
-
case "
|
|
4667
|
-
kind = $64$username$47$core$46$TokenKind$
|
|
4848
|
+
case "neq": {
|
|
4849
|
+
kind = $64$username$47$core$46$TokenKind$Neq;
|
|
4668
4850
|
break;
|
|
4669
4851
|
}
|
|
4670
4852
|
case "lt": {
|
|
@@ -4851,6 +5033,10 @@ function _M0MP28username4core5Lexer11scan__ident(self) {
|
|
|
4851
5033
|
kind = $64$username$47$core$46$TokenKind$Use_;
|
|
4852
5034
|
break;
|
|
4853
5035
|
}
|
|
5036
|
+
case "namespace": {
|
|
5037
|
+
kind = $64$username$47$core$46$TokenKind$Mod_;
|
|
5038
|
+
break;
|
|
5039
|
+
}
|
|
4854
5040
|
case "pub": {
|
|
4855
5041
|
kind = $64$username$47$core$46$TokenKind$Pub_;
|
|
4856
5042
|
break;
|
|
@@ -5171,7 +5357,17 @@ function _M0MP28username4core5Lexer8tokenize(self) {
|
|
|
5171
5357
|
const line = self.line;
|
|
5172
5358
|
const col = self.col;
|
|
5173
5359
|
_M0MP28username4core5Lexer7advance(self);
|
|
5174
|
-
|
|
5360
|
+
if (_M0MP28username4core5Lexer4peek(self) === 46) {
|
|
5361
|
+
_M0MP28username4core5Lexer7advance(self);
|
|
5362
|
+
if (_M0MP28username4core5Lexer4peek(self) === 46) {
|
|
5363
|
+
_M0MP28username4core5Lexer7advance(self);
|
|
5364
|
+
_M0MP28username4core5Lexer4emit(self, $64$username$47$core$46$TokenKind$DotDotDot, line, col);
|
|
5365
|
+
} else {
|
|
5366
|
+
_M0MP28username4core5Lexer4emit(self, $64$username$47$core$46$TokenKind$DotDot, line, col);
|
|
5367
|
+
}
|
|
5368
|
+
} else {
|
|
5369
|
+
_M0MP28username4core5Lexer4emit(self, $64$username$47$core$46$TokenKind$Dot, line, col);
|
|
5370
|
+
}
|
|
5175
5371
|
continue;
|
|
5176
5372
|
}
|
|
5177
5373
|
if (_M0FP28username4core16is__ident__start(ch) && ch !== 45) {
|
|
@@ -5232,24 +5428,27 @@ function _M0FP28username4core9js__binop(op) {
|
|
|
5232
5428
|
return "%";
|
|
5233
5429
|
}
|
|
5234
5430
|
case 5: {
|
|
5235
|
-
return "
|
|
5431
|
+
return "**";
|
|
5236
5432
|
}
|
|
5237
5433
|
case 6: {
|
|
5238
|
-
return "
|
|
5434
|
+
return "===";
|
|
5239
5435
|
}
|
|
5240
5436
|
case 7: {
|
|
5241
|
-
return "
|
|
5437
|
+
return "!==";
|
|
5242
5438
|
}
|
|
5243
5439
|
case 8: {
|
|
5244
|
-
return "
|
|
5440
|
+
return "<";
|
|
5245
5441
|
}
|
|
5246
5442
|
case 9: {
|
|
5247
|
-
return "
|
|
5443
|
+
return ">";
|
|
5248
5444
|
}
|
|
5249
5445
|
case 10: {
|
|
5250
|
-
return "
|
|
5446
|
+
return "<=";
|
|
5251
5447
|
}
|
|
5252
5448
|
case 11: {
|
|
5449
|
+
return ">=";
|
|
5450
|
+
}
|
|
5451
|
+
case 12: {
|
|
5253
5452
|
return "&&";
|
|
5254
5453
|
}
|
|
5255
5454
|
default: {
|
|
@@ -5561,332 +5760,388 @@ function _M0MP28username4core9JsCodegen9gen__expr(self, expr) {
|
|
|
5561
5760
|
_L$22: {
|
|
5562
5761
|
let pairs;
|
|
5563
5762
|
_L$23: {
|
|
5564
|
-
let
|
|
5763
|
+
let end;
|
|
5764
|
+
let obj$4;
|
|
5765
|
+
let start;
|
|
5766
|
+
let inclusive;
|
|
5565
5767
|
_L$24: {
|
|
5566
|
-
let
|
|
5768
|
+
let end$2;
|
|
5769
|
+
let start$2;
|
|
5770
|
+
let inclusive$2;
|
|
5567
5771
|
_L$25: {
|
|
5568
|
-
let
|
|
5569
|
-
let flags;
|
|
5772
|
+
let elems;
|
|
5570
5773
|
_L$26: {
|
|
5571
|
-
let
|
|
5774
|
+
let b;
|
|
5572
5775
|
_L$27: {
|
|
5573
|
-
let
|
|
5776
|
+
let pattern;
|
|
5777
|
+
let flags;
|
|
5574
5778
|
_L$28: {
|
|
5575
|
-
let
|
|
5779
|
+
let parts;
|
|
5576
5780
|
_L$29: {
|
|
5577
|
-
let
|
|
5781
|
+
let s;
|
|
5578
5782
|
_L$30: {
|
|
5579
|
-
|
|
5580
|
-
|
|
5581
|
-
|
|
5582
|
-
|
|
5583
|
-
|
|
5584
|
-
|
|
5585
|
-
|
|
5586
|
-
|
|
5587
|
-
|
|
5588
|
-
|
|
5589
|
-
|
|
5590
|
-
|
|
5591
|
-
|
|
5592
|
-
|
|
5593
|
-
|
|
5594
|
-
|
|
5595
|
-
|
|
5596
|
-
|
|
5597
|
-
|
|
5598
|
-
|
|
5599
|
-
|
|
5600
|
-
|
|
5601
|
-
|
|
5602
|
-
|
|
5603
|
-
|
|
5604
|
-
|
|
5605
|
-
|
|
5606
|
-
|
|
5607
|
-
|
|
5608
|
-
|
|
5609
|
-
|
|
5610
|
-
|
|
5611
|
-
|
|
5612
|
-
|
|
5613
|
-
|
|
5614
|
-
|
|
5615
|
-
|
|
5616
|
-
|
|
5617
|
-
|
|
5618
|
-
|
|
5619
|
-
|
|
5620
|
-
|
|
5621
|
-
|
|
5622
|
-
|
|
5623
|
-
|
|
5624
|
-
|
|
5625
|
-
|
|
5626
|
-
|
|
5627
|
-
|
|
5628
|
-
|
|
5629
|
-
|
|
5630
|
-
|
|
5631
|
-
|
|
5632
|
-
|
|
5633
|
-
|
|
5634
|
-
|
|
5635
|
-
|
|
5636
|
-
|
|
5637
|
-
|
|
5638
|
-
|
|
5639
|
-
|
|
5640
|
-
|
|
5641
|
-
|
|
5642
|
-
|
|
5643
|
-
|
|
5644
|
-
|
|
5645
|
-
|
|
5646
|
-
|
|
5647
|
-
|
|
5648
|
-
|
|
5649
|
-
|
|
5650
|
-
|
|
5651
|
-
|
|
5652
|
-
|
|
5653
|
-
|
|
5654
|
-
|
|
5655
|
-
|
|
5656
|
-
|
|
5657
|
-
|
|
5658
|
-
|
|
5659
|
-
|
|
5660
|
-
|
|
5661
|
-
|
|
5662
|
-
|
|
5663
|
-
|
|
5664
|
-
|
|
5665
|
-
|
|
5666
|
-
|
|
5667
|
-
|
|
5668
|
-
|
|
5669
|
-
|
|
5670
|
-
|
|
5671
|
-
|
|
5672
|
-
|
|
5673
|
-
|
|
5674
|
-
|
|
5675
|
-
|
|
5676
|
-
|
|
5677
|
-
|
|
5678
|
-
|
|
5679
|
-
|
|
5680
|
-
|
|
5681
|
-
|
|
5682
|
-
|
|
5683
|
-
|
|
5684
|
-
|
|
5685
|
-
|
|
5686
|
-
|
|
5687
|
-
|
|
5688
|
-
|
|
5689
|
-
|
|
5690
|
-
|
|
5691
|
-
|
|
5692
|
-
|
|
5693
|
-
|
|
5694
|
-
|
|
5695
|
-
|
|
5696
|
-
|
|
5697
|
-
|
|
5698
|
-
|
|
5699
|
-
|
|
5700
|
-
|
|
5701
|
-
|
|
5702
|
-
|
|
5703
|
-
|
|
5704
|
-
|
|
5705
|
-
|
|
5706
|
-
|
|
5707
|
-
|
|
5708
|
-
|
|
5709
|
-
|
|
5710
|
-
|
|
5711
|
-
|
|
5712
|
-
|
|
5713
|
-
|
|
5714
|
-
|
|
5715
|
-
|
|
5716
|
-
|
|
5717
|
-
|
|
5718
|
-
|
|
5719
|
-
|
|
5720
|
-
|
|
5721
|
-
|
|
5722
|
-
|
|
5723
|
-
|
|
5724
|
-
|
|
5725
|
-
|
|
5726
|
-
|
|
5727
|
-
|
|
5728
|
-
|
|
5729
|
-
|
|
5730
|
-
|
|
5731
|
-
|
|
5732
|
-
|
|
5733
|
-
|
|
5734
|
-
|
|
5735
|
-
|
|
5736
|
-
|
|
5737
|
-
|
|
5738
|
-
|
|
5739
|
-
|
|
5740
|
-
|
|
5741
|
-
|
|
5742
|
-
|
|
5743
|
-
|
|
5744
|
-
|
|
5745
|
-
|
|
5746
|
-
|
|
5747
|
-
|
|
5748
|
-
|
|
5749
|
-
|
|
5750
|
-
|
|
5751
|
-
|
|
5752
|
-
|
|
5753
|
-
|
|
5754
|
-
|
|
5755
|
-
|
|
5756
|
-
|
|
5757
|
-
|
|
5758
|
-
|
|
5759
|
-
|
|
5760
|
-
|
|
5761
|
-
|
|
5762
|
-
|
|
5763
|
-
|
|
5764
|
-
|
|
5765
|
-
|
|
5766
|
-
|
|
5767
|
-
|
|
5768
|
-
|
|
5769
|
-
|
|
5770
|
-
|
|
5771
|
-
|
|
5772
|
-
|
|
5773
|
-
|
|
5774
|
-
|
|
5775
|
-
|
|
5776
|
-
|
|
5777
|
-
|
|
5778
|
-
|
|
5779
|
-
|
|
5780
|
-
|
|
5781
|
-
|
|
5782
|
-
|
|
5783
|
-
|
|
5784
|
-
|
|
5785
|
-
|
|
5786
|
-
|
|
5787
|
-
|
|
5788
|
-
|
|
5789
|
-
|
|
5790
|
-
|
|
5791
|
-
|
|
5792
|
-
|
|
5793
|
-
|
|
5794
|
-
|
|
5795
|
-
|
|
5796
|
-
|
|
5797
|
-
|
|
5798
|
-
|
|
5799
|
-
|
|
5800
|
-
|
|
5801
|
-
|
|
5802
|
-
|
|
5803
|
-
|
|
5804
|
-
|
|
5783
|
+
let f;
|
|
5784
|
+
_L$31: {
|
|
5785
|
+
let n;
|
|
5786
|
+
_L$32: {
|
|
5787
|
+
switch (expr$2.$tag) {
|
|
5788
|
+
case 0: {
|
|
5789
|
+
const _IntLit = expr$2;
|
|
5790
|
+
const _n = _IntLit._0;
|
|
5791
|
+
n = _n;
|
|
5792
|
+
break _L$32;
|
|
5793
|
+
}
|
|
5794
|
+
case 1: {
|
|
5795
|
+
const _FloatLit = expr$2;
|
|
5796
|
+
const _f = _FloatLit._0;
|
|
5797
|
+
f = _f;
|
|
5798
|
+
break _L$31;
|
|
5799
|
+
}
|
|
5800
|
+
case 2: {
|
|
5801
|
+
const _StrLit = expr$2;
|
|
5802
|
+
const _s = _StrLit._0;
|
|
5803
|
+
s = _s;
|
|
5804
|
+
break _L$30;
|
|
5805
|
+
}
|
|
5806
|
+
case 3: {
|
|
5807
|
+
const _StrInterp = expr$2;
|
|
5808
|
+
const _parts = _StrInterp._0;
|
|
5809
|
+
parts = _parts;
|
|
5810
|
+
break _L$29;
|
|
5811
|
+
}
|
|
5812
|
+
case 4: {
|
|
5813
|
+
const _RegexLit = expr$2;
|
|
5814
|
+
const _pattern = _RegexLit._0;
|
|
5815
|
+
const _flags = _RegexLit._1;
|
|
5816
|
+
pattern = _pattern;
|
|
5817
|
+
flags = _flags;
|
|
5818
|
+
break _L$28;
|
|
5819
|
+
}
|
|
5820
|
+
case 5: {
|
|
5821
|
+
const _BoolLit = expr$2;
|
|
5822
|
+
const _b = _BoolLit._0;
|
|
5823
|
+
b = _b;
|
|
5824
|
+
break _L$27;
|
|
5825
|
+
}
|
|
5826
|
+
case 6: {
|
|
5827
|
+
_M0MP28username4core9JsCodegen5write(self$2, "null");
|
|
5828
|
+
return;
|
|
5829
|
+
}
|
|
5830
|
+
case 7: {
|
|
5831
|
+
_M0MP28username4core9JsCodegen5write(self$2, "undefined");
|
|
5832
|
+
return;
|
|
5833
|
+
}
|
|
5834
|
+
case 8: {
|
|
5835
|
+
const _ArrayLit = expr$2;
|
|
5836
|
+
const _elems = _ArrayLit._0;
|
|
5837
|
+
elems = _elems;
|
|
5838
|
+
break _L$26;
|
|
5839
|
+
}
|
|
5840
|
+
case 9: {
|
|
5841
|
+
const _RangeArray = expr$2;
|
|
5842
|
+
const _start = _RangeArray._0;
|
|
5843
|
+
const _end = _RangeArray._1;
|
|
5844
|
+
const _inclusive = _RangeArray._2;
|
|
5845
|
+
end$2 = _end;
|
|
5846
|
+
start$2 = _start;
|
|
5847
|
+
inclusive$2 = _inclusive;
|
|
5848
|
+
break _L$25;
|
|
5849
|
+
}
|
|
5850
|
+
case 10: {
|
|
5851
|
+
const _Slice = expr$2;
|
|
5852
|
+
const _obj = _Slice._0;
|
|
5853
|
+
const _start$2 = _Slice._1;
|
|
5854
|
+
const _end$2 = _Slice._2;
|
|
5855
|
+
const _inclusive$2 = _Slice._3;
|
|
5856
|
+
end = _end$2;
|
|
5857
|
+
obj$4 = _obj;
|
|
5858
|
+
start = _start$2;
|
|
5859
|
+
inclusive = _inclusive$2;
|
|
5860
|
+
break _L$24;
|
|
5861
|
+
}
|
|
5862
|
+
case 11: {
|
|
5863
|
+
const _ObjectLit = expr$2;
|
|
5864
|
+
const _pairs = _ObjectLit._0;
|
|
5865
|
+
pairs = _pairs;
|
|
5866
|
+
break _L$23;
|
|
5867
|
+
}
|
|
5868
|
+
case 12: {
|
|
5869
|
+
const _Ident = expr$2;
|
|
5870
|
+
const _name = _Ident._0;
|
|
5871
|
+
name = _name;
|
|
5872
|
+
break _L$22;
|
|
5873
|
+
}
|
|
5874
|
+
case 13: {
|
|
5875
|
+
const _DotAccess = expr$2;
|
|
5876
|
+
const _obj$2 = _DotAccess._0;
|
|
5877
|
+
const _field = _DotAccess._1;
|
|
5878
|
+
obj$3 = _obj$2;
|
|
5879
|
+
field = _field;
|
|
5880
|
+
break _L$21;
|
|
5881
|
+
}
|
|
5882
|
+
case 14: {
|
|
5883
|
+
const _IndexAccess = expr$2;
|
|
5884
|
+
const _obj$3 = _IndexAccess._0;
|
|
5885
|
+
const _index = _IndexAccess._1;
|
|
5886
|
+
obj$2 = _obj$3;
|
|
5887
|
+
index = _index;
|
|
5888
|
+
break _L$20;
|
|
5889
|
+
}
|
|
5890
|
+
case 15: {
|
|
5891
|
+
const _BinOp = expr$2;
|
|
5892
|
+
const _op = _BinOp._0;
|
|
5893
|
+
const _left = _BinOp._1;
|
|
5894
|
+
const _right = _BinOp._2;
|
|
5895
|
+
left$2 = _left;
|
|
5896
|
+
op = _op;
|
|
5897
|
+
right$2 = _right;
|
|
5898
|
+
break _L$19;
|
|
5899
|
+
}
|
|
5900
|
+
case 16: {
|
|
5901
|
+
const _UnaryNeg = expr$2;
|
|
5902
|
+
const _inner = _UnaryNeg._0;
|
|
5903
|
+
inner$5 = _inner;
|
|
5904
|
+
break _L$18;
|
|
5905
|
+
}
|
|
5906
|
+
case 17: {
|
|
5907
|
+
const _UnaryNot = expr$2;
|
|
5908
|
+
const _inner$2 = _UnaryNot._0;
|
|
5909
|
+
inner$4 = _inner$2;
|
|
5910
|
+
break _L$17;
|
|
5911
|
+
}
|
|
5912
|
+
case 18: {
|
|
5913
|
+
const _UnaryTypeof = expr$2;
|
|
5914
|
+
const _inner$3 = _UnaryTypeof._0;
|
|
5915
|
+
inner$3 = _inner$3;
|
|
5916
|
+
break _L$16;
|
|
5917
|
+
}
|
|
5918
|
+
case 19: {
|
|
5919
|
+
const _IsCheck = expr$2;
|
|
5920
|
+
const _expr = _IsCheck._0;
|
|
5921
|
+
const _type_name$2 = _IsCheck._1;
|
|
5922
|
+
expr$5 = _expr;
|
|
5923
|
+
type_name = _type_name$2;
|
|
5924
|
+
break _L$15;
|
|
5925
|
+
}
|
|
5926
|
+
case 20: {
|
|
5927
|
+
const _AsCast = expr$2;
|
|
5928
|
+
const _expr$2 = _AsCast._0;
|
|
5929
|
+
const __type_name = _AsCast._1;
|
|
5930
|
+
expr$4 = _expr$2;
|
|
5931
|
+
_type_name = __type_name;
|
|
5932
|
+
break _L$14;
|
|
5933
|
+
}
|
|
5934
|
+
case 21: {
|
|
5935
|
+
const _Instanceof = expr$2;
|
|
5936
|
+
const _expr$3 = _Instanceof._0;
|
|
5937
|
+
const _type_expr = _Instanceof._1;
|
|
5938
|
+
expr$3 = _expr$3;
|
|
5939
|
+
type_expr = _type_expr;
|
|
5940
|
+
break _L$13;
|
|
5941
|
+
}
|
|
5942
|
+
case 22: {
|
|
5943
|
+
const _FnExpr = expr$2;
|
|
5944
|
+
const _params = _FnExpr._0;
|
|
5945
|
+
const _body = _FnExpr._1;
|
|
5946
|
+
params$2 = _params;
|
|
5947
|
+
body = _body;
|
|
5948
|
+
break _L$12;
|
|
5949
|
+
}
|
|
5950
|
+
case 23: {
|
|
5951
|
+
const _FnExprTo = expr$2;
|
|
5952
|
+
const _params$2 = _FnExprTo._0;
|
|
5953
|
+
const _body_expr = _FnExprTo._1;
|
|
5954
|
+
params = _params$2;
|
|
5955
|
+
body_expr = _body_expr;
|
|
5956
|
+
break _L$11;
|
|
5957
|
+
}
|
|
5958
|
+
case 24: {
|
|
5959
|
+
const _Call = expr$2;
|
|
5960
|
+
const _callee = _Call._0;
|
|
5961
|
+
const _args = _Call._1;
|
|
5962
|
+
callee$2 = _callee;
|
|
5963
|
+
args$3 = _args;
|
|
5964
|
+
break _L$10;
|
|
5965
|
+
}
|
|
5966
|
+
case 25: {
|
|
5967
|
+
const _MethodCall = expr$2;
|
|
5968
|
+
const _obj$4 = _MethodCall._0;
|
|
5969
|
+
const _meth_name = _MethodCall._1;
|
|
5970
|
+
const _args$2 = _MethodCall._2;
|
|
5971
|
+
meth_name = _meth_name;
|
|
5972
|
+
obj = _obj$4;
|
|
5973
|
+
args$2 = _args$2;
|
|
5974
|
+
break _L$9;
|
|
5975
|
+
}
|
|
5976
|
+
case 26: {
|
|
5977
|
+
const _NewExpr = expr$2;
|
|
5978
|
+
const _callee$2 = _NewExpr._0;
|
|
5979
|
+
const _args$3 = _NewExpr._1;
|
|
5980
|
+
callee = _callee$2;
|
|
5981
|
+
args = _args$3;
|
|
5982
|
+
break _L$8;
|
|
5983
|
+
}
|
|
5984
|
+
case 27: {
|
|
5985
|
+
const _Pipe = expr$2;
|
|
5986
|
+
const _left$2 = _Pipe._0;
|
|
5987
|
+
const _right$2 = _Pipe._1;
|
|
5988
|
+
left = _left$2;
|
|
5989
|
+
right = _right$2;
|
|
5990
|
+
break _L$7;
|
|
5991
|
+
}
|
|
5992
|
+
case 28: {
|
|
5993
|
+
const _IfExpr = expr$2;
|
|
5994
|
+
const _cond = _IfExpr._0;
|
|
5995
|
+
const _then_expr = _IfExpr._1;
|
|
5996
|
+
const _else_expr = _IfExpr._2;
|
|
5997
|
+
then_expr = _then_expr;
|
|
5998
|
+
cond = _cond;
|
|
5999
|
+
else_expr = _else_expr;
|
|
6000
|
+
break _L$6;
|
|
6001
|
+
}
|
|
6002
|
+
case 29: {
|
|
6003
|
+
const _TryExpr = expr$2;
|
|
6004
|
+
const _try_body = _TryExpr._0;
|
|
6005
|
+
const _catch_name = _TryExpr._1;
|
|
6006
|
+
const _catch_body = _TryExpr._2;
|
|
6007
|
+
catch_name = _catch_name;
|
|
6008
|
+
try_body = _try_body;
|
|
6009
|
+
catch_body = _catch_body;
|
|
6010
|
+
break _L$5;
|
|
6011
|
+
}
|
|
6012
|
+
case 30: {
|
|
6013
|
+
const _MatchExpr = expr$2;
|
|
6014
|
+
const _subject = _MatchExpr._0;
|
|
6015
|
+
const _arms = _MatchExpr._1;
|
|
6016
|
+
subject = _subject;
|
|
6017
|
+
arms = _arms;
|
|
6018
|
+
break _L$4;
|
|
6019
|
+
}
|
|
6020
|
+
case 31: {
|
|
6021
|
+
const _AwaitExpr = expr$2;
|
|
6022
|
+
const _inner$4 = _AwaitExpr._0;
|
|
6023
|
+
inner$2 = _inner$4;
|
|
6024
|
+
break _L$3;
|
|
6025
|
+
}
|
|
6026
|
+
case 32: {
|
|
6027
|
+
const _DeleteExpr = expr$2;
|
|
6028
|
+
const _inner$5 = _DeleteExpr._0;
|
|
6029
|
+
inner = _inner$5;
|
|
6030
|
+
break _L$2;
|
|
6031
|
+
}
|
|
6032
|
+
default: {
|
|
6033
|
+
_M0MP28username4core9JsCodegen5write(self$2, "this");
|
|
6034
|
+
return;
|
|
6035
|
+
}
|
|
6036
|
+
}
|
|
5805
6037
|
}
|
|
6038
|
+
_M0MP28username4core9JsCodegen5write(self$2, _M0MP311moonbitlang4core3int3Int18to__string_2einner(n, 10));
|
|
6039
|
+
return;
|
|
5806
6040
|
}
|
|
6041
|
+
_M0MP28username4core9JsCodegen5write(self$2, _M0MP311moonbitlang4core6double6Double10to__string(f));
|
|
6042
|
+
return;
|
|
5807
6043
|
}
|
|
5808
|
-
_M0MP28username4core9JsCodegen5write(self$2,
|
|
6044
|
+
_M0MP28username4core9JsCodegen5write(self$2, "\"");
|
|
6045
|
+
_M0MP28username4core9JsCodegen5write(self$2, _M0FP28username4core15js__escape__str(s));
|
|
6046
|
+
_M0MP28username4core9JsCodegen5write(self$2, "\"");
|
|
5809
6047
|
return;
|
|
5810
6048
|
}
|
|
5811
|
-
_M0MP28username4core9JsCodegen5write(self$2,
|
|
5812
|
-
|
|
5813
|
-
|
|
5814
|
-
|
|
5815
|
-
|
|
5816
|
-
|
|
5817
|
-
|
|
5818
|
-
|
|
5819
|
-
|
|
5820
|
-
const _arr = parts;
|
|
5821
|
-
const _len = _arr.length;
|
|
5822
|
-
let _tmp$3 = 0;
|
|
5823
|
-
while (true) {
|
|
5824
|
-
const _i = _tmp$3;
|
|
5825
|
-
if (_i < _len) {
|
|
5826
|
-
const part = _arr[_i];
|
|
5827
|
-
let expr$6;
|
|
5828
|
-
_L$28: {
|
|
5829
|
-
_L$29: {
|
|
5830
|
-
let s;
|
|
6049
|
+
_M0MP28username4core9JsCodegen5write(self$2, "`");
|
|
6050
|
+
const _arr = parts;
|
|
6051
|
+
const _len = _arr.length;
|
|
6052
|
+
let _tmp$3 = 0;
|
|
6053
|
+
while (true) {
|
|
6054
|
+
const _i = _tmp$3;
|
|
6055
|
+
if (_i < _len) {
|
|
6056
|
+
const part = _arr[_i];
|
|
6057
|
+
let expr$6;
|
|
5831
6058
|
_L$30: {
|
|
5832
|
-
|
|
5833
|
-
|
|
5834
|
-
|
|
5835
|
-
|
|
6059
|
+
_L$31: {
|
|
6060
|
+
let s;
|
|
6061
|
+
_L$32: {
|
|
6062
|
+
if (part.$tag === 0) {
|
|
6063
|
+
const _Lit = part;
|
|
6064
|
+
const _s = _Lit._0;
|
|
6065
|
+
s = _s;
|
|
6066
|
+
break _L$32;
|
|
6067
|
+
} else {
|
|
6068
|
+
const _Interp = part;
|
|
6069
|
+
const _expr = _Interp._0;
|
|
6070
|
+
expr$6 = _expr;
|
|
6071
|
+
break _L$31;
|
|
6072
|
+
}
|
|
6073
|
+
}
|
|
6074
|
+
_M0MP28username4core9JsCodegen5write(self$2, _M0FP28username4core20js__escape__template(s));
|
|
5836
6075
|
break _L$30;
|
|
5837
|
-
} else {
|
|
5838
|
-
const _Interp = part;
|
|
5839
|
-
const _expr = _Interp._0;
|
|
5840
|
-
expr$6 = _expr;
|
|
5841
|
-
break _L$29;
|
|
5842
6076
|
}
|
|
6077
|
+
_M0MP28username4core9JsCodegen5write(self$2, "${");
|
|
6078
|
+
_M0MP28username4core9JsCodegen9gen__expr(self$2, expr$6);
|
|
6079
|
+
_M0MP28username4core9JsCodegen5write(self$2, "}");
|
|
5843
6080
|
}
|
|
5844
|
-
|
|
5845
|
-
|
|
6081
|
+
_tmp$3 = _i + 1 | 0;
|
|
6082
|
+
continue;
|
|
6083
|
+
} else {
|
|
6084
|
+
break;
|
|
5846
6085
|
}
|
|
5847
|
-
_M0MP28username4core9JsCodegen5write(self$2, "${");
|
|
5848
|
-
_M0MP28username4core9JsCodegen9gen__expr(self$2, expr$6);
|
|
5849
|
-
_M0MP28username4core9JsCodegen5write(self$2, "}");
|
|
5850
6086
|
}
|
|
5851
|
-
|
|
5852
|
-
|
|
5853
|
-
} else {
|
|
5854
|
-
break;
|
|
6087
|
+
_M0MP28username4core9JsCodegen5write(self$2, "`");
|
|
6088
|
+
return;
|
|
5855
6089
|
}
|
|
6090
|
+
_M0MP28username4core9JsCodegen5write(self$2, "/");
|
|
6091
|
+
_M0MP28username4core9JsCodegen5write(self$2, pattern);
|
|
6092
|
+
_M0MP28username4core9JsCodegen5write(self$2, "/");
|
|
6093
|
+
_M0MP28username4core9JsCodegen5write(self$2, flags);
|
|
6094
|
+
return;
|
|
5856
6095
|
}
|
|
5857
|
-
_M0MP28username4core9JsCodegen5write(self$2, "
|
|
6096
|
+
_M0MP28username4core9JsCodegen5write(self$2, b ? "true" : "false");
|
|
5858
6097
|
return;
|
|
5859
6098
|
}
|
|
5860
|
-
_M0MP28username4core9JsCodegen5write(self$2, "
|
|
5861
|
-
|
|
5862
|
-
|
|
5863
|
-
|
|
6099
|
+
_M0MP28username4core9JsCodegen5write(self$2, "[");
|
|
6100
|
+
const first = { val: true };
|
|
6101
|
+
const _arr = elems;
|
|
6102
|
+
const _len = _arr.length;
|
|
6103
|
+
let _tmp$3 = 0;
|
|
6104
|
+
while (true) {
|
|
6105
|
+
const _i = _tmp$3;
|
|
6106
|
+
if (_i < _len) {
|
|
6107
|
+
const e = _arr[_i];
|
|
6108
|
+
if (!first.val) {
|
|
6109
|
+
_M0MP28username4core9JsCodegen5write(self$2, ", ");
|
|
6110
|
+
}
|
|
6111
|
+
_M0MP28username4core9JsCodegen9gen__expr(self$2, e);
|
|
6112
|
+
first.val = false;
|
|
6113
|
+
_tmp$3 = _i + 1 | 0;
|
|
6114
|
+
continue;
|
|
6115
|
+
} else {
|
|
6116
|
+
break;
|
|
6117
|
+
}
|
|
6118
|
+
}
|
|
6119
|
+
_M0MP28username4core9JsCodegen5write(self$2, "]");
|
|
5864
6120
|
return;
|
|
5865
6121
|
}
|
|
5866
|
-
_M0MP28username4core9JsCodegen5write(self$2,
|
|
6122
|
+
_M0MP28username4core9JsCodegen5write(self$2, "Array.from({ length: ");
|
|
6123
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self$2, end$2);
|
|
6124
|
+
_M0MP28username4core9JsCodegen5write(self$2, " - ");
|
|
6125
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self$2, start$2);
|
|
6126
|
+
if (inclusive$2) {
|
|
6127
|
+
_M0MP28username4core9JsCodegen5write(self$2, " + 1");
|
|
6128
|
+
}
|
|
6129
|
+
_M0MP28username4core9JsCodegen5write(self$2, " }, (_, i) => i + ");
|
|
6130
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self$2, start$2);
|
|
6131
|
+
_M0MP28username4core9JsCodegen5write(self$2, ")");
|
|
5867
6132
|
return;
|
|
5868
6133
|
}
|
|
5869
|
-
|
|
5870
|
-
|
|
5871
|
-
|
|
5872
|
-
|
|
5873
|
-
|
|
5874
|
-
|
|
5875
|
-
|
|
5876
|
-
|
|
5877
|
-
|
|
5878
|
-
if (!first.val) {
|
|
5879
|
-
_M0MP28username4core9JsCodegen5write(self$2, ", ");
|
|
5880
|
-
}
|
|
5881
|
-
_M0MP28username4core9JsCodegen9gen__expr(self$2, e);
|
|
5882
|
-
first.val = false;
|
|
5883
|
-
_tmp$3 = _i + 1 | 0;
|
|
5884
|
-
continue;
|
|
5885
|
-
} else {
|
|
5886
|
-
break;
|
|
5887
|
-
}
|
|
6134
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self$2, obj$4);
|
|
6135
|
+
_M0MP28username4core9JsCodegen5write(self$2, ".slice(");
|
|
6136
|
+
_M0MP28username4core9JsCodegen9gen__expr(self$2, start);
|
|
6137
|
+
_M0MP28username4core9JsCodegen5write(self$2, ", ");
|
|
6138
|
+
if (inclusive) {
|
|
6139
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self$2, end);
|
|
6140
|
+
_M0MP28username4core9JsCodegen5write(self$2, " + 1");
|
|
6141
|
+
} else {
|
|
6142
|
+
_M0MP28username4core9JsCodegen9gen__expr(self$2, end);
|
|
5888
6143
|
}
|
|
5889
|
-
_M0MP28username4core9JsCodegen5write(self$2, "
|
|
6144
|
+
_M0MP28username4core9JsCodegen5write(self$2, ")");
|
|
5890
6145
|
return;
|
|
5891
6146
|
}
|
|
5892
6147
|
if (_M0MP311moonbitlang4core5array5Array9is__emptyGUsRP28username4core4ExprEE(pairs)) {
|
|
@@ -6157,7 +6412,7 @@ function _M0MP28username4core9JsCodegen9gen__expr(self, expr) {
|
|
|
6157
6412
|
let args$2;
|
|
6158
6413
|
_L$9: {
|
|
6159
6414
|
switch (right.$tag) {
|
|
6160
|
-
case
|
|
6415
|
+
case 24: {
|
|
6161
6416
|
const _Call = right;
|
|
6162
6417
|
const _callee = _Call._0;
|
|
6163
6418
|
const _args = _Call._1;
|
|
@@ -6165,7 +6420,7 @@ function _M0MP28username4core9JsCodegen9gen__expr(self, expr) {
|
|
|
6165
6420
|
args$2 = _args;
|
|
6166
6421
|
break _L$9;
|
|
6167
6422
|
}
|
|
6168
|
-
case
|
|
6423
|
+
case 25: {
|
|
6169
6424
|
const _MethodCall = right;
|
|
6170
6425
|
const _meth_name = _MethodCall._1;
|
|
6171
6426
|
const _args$2 = _MethodCall._2;
|
|
@@ -6173,7 +6428,7 @@ function _M0MP28username4core9JsCodegen9gen__expr(self, expr) {
|
|
|
6173
6428
|
args = _args$2;
|
|
6174
6429
|
break _L$8;
|
|
6175
6430
|
}
|
|
6176
|
-
case
|
|
6431
|
+
case 12: {
|
|
6177
6432
|
_M0MP28username4core9JsCodegen9gen__expr(self$2, right);
|
|
6178
6433
|
_M0MP28username4core9JsCodegen5write(self$2, "(");
|
|
6179
6434
|
_M0MP28username4core9JsCodegen9gen__expr(self$2, left);
|
|
@@ -6422,19 +6677,19 @@ function _M0MP28username4core9JsCodegen9gen__expr(self, expr) {
|
|
|
6422
6677
|
function _M0MP28username4core9JsCodegen15gen__expr__wrap(self, expr) {
|
|
6423
6678
|
_L: {
|
|
6424
6679
|
switch (expr.$tag) {
|
|
6425
|
-
case
|
|
6680
|
+
case 15: {
|
|
6426
6681
|
break _L;
|
|
6427
6682
|
}
|
|
6428
|
-
case
|
|
6683
|
+
case 16: {
|
|
6429
6684
|
break _L;
|
|
6430
6685
|
}
|
|
6431
|
-
case
|
|
6686
|
+
case 17: {
|
|
6432
6687
|
break _L;
|
|
6433
6688
|
}
|
|
6434
|
-
case
|
|
6689
|
+
case 28: {
|
|
6435
6690
|
break _L;
|
|
6436
6691
|
}
|
|
6437
|
-
case
|
|
6692
|
+
case 27: {
|
|
6438
6693
|
break _L;
|
|
6439
6694
|
}
|
|
6440
6695
|
default: {
|
|
@@ -6515,211 +6770,248 @@ function _M0MP28username4core9JsCodegen9gen__stmt(self, stmt) {
|
|
|
6515
6770
|
let target;
|
|
6516
6771
|
let value$2;
|
|
6517
6772
|
_L$22: {
|
|
6518
|
-
let
|
|
6773
|
+
let names$2;
|
|
6519
6774
|
let kind;
|
|
6520
6775
|
let value$3;
|
|
6521
6776
|
_L$23: {
|
|
6522
|
-
|
|
6777
|
+
let name$5;
|
|
6778
|
+
let kind$2;
|
|
6779
|
+
let value$4;
|
|
6780
|
+
_L$24: {
|
|
6781
|
+
switch (stmt.$tag) {
|
|
6782
|
+
case 0: {
|
|
6783
|
+
const _VarDecl = stmt;
|
|
6784
|
+
const _kind = _VarDecl._0;
|
|
6785
|
+
const _name = _VarDecl._1;
|
|
6786
|
+
const _value = _VarDecl._2;
|
|
6787
|
+
name$5 = _name;
|
|
6788
|
+
kind$2 = _kind;
|
|
6789
|
+
value$4 = _value;
|
|
6790
|
+
break _L$24;
|
|
6791
|
+
}
|
|
6792
|
+
case 1: {
|
|
6793
|
+
const _DestructDecl = stmt;
|
|
6794
|
+
const _kind$2 = _DestructDecl._0;
|
|
6795
|
+
const _names = _DestructDecl._1;
|
|
6796
|
+
const _value$2 = _DestructDecl._2;
|
|
6797
|
+
names$2 = _names;
|
|
6798
|
+
kind = _kind$2;
|
|
6799
|
+
value$3 = _value$2;
|
|
6800
|
+
break _L$23;
|
|
6801
|
+
}
|
|
6802
|
+
case 2: {
|
|
6803
|
+
const _Assign = stmt;
|
|
6804
|
+
const _target = _Assign._0;
|
|
6805
|
+
const _value$3 = _Assign._1;
|
|
6806
|
+
target = _target;
|
|
6807
|
+
value$2 = _value$3;
|
|
6808
|
+
break _L$22;
|
|
6809
|
+
}
|
|
6810
|
+
case 3: {
|
|
6811
|
+
const _FnDecl = stmt;
|
|
6812
|
+
const _decl = _FnDecl._0;
|
|
6813
|
+
decl$2 = _decl;
|
|
6814
|
+
break _L$21;
|
|
6815
|
+
}
|
|
6816
|
+
case 4: {
|
|
6817
|
+
const _If = stmt;
|
|
6818
|
+
const _cond = _If._0;
|
|
6819
|
+
const _body = _If._1;
|
|
6820
|
+
const _elifs = _If._2;
|
|
6821
|
+
const _else_body = _If._3;
|
|
6822
|
+
elifs = _elifs;
|
|
6823
|
+
cond$6 = _cond;
|
|
6824
|
+
body$7 = _body;
|
|
6825
|
+
else_body = _else_body;
|
|
6826
|
+
break _L$20;
|
|
6827
|
+
}
|
|
6828
|
+
case 5: {
|
|
6829
|
+
const _Unless = stmt;
|
|
6830
|
+
const _cond$2 = _Unless._0;
|
|
6831
|
+
const _body$2 = _Unless._1;
|
|
6832
|
+
cond$5 = _cond$2;
|
|
6833
|
+
body$6 = _body$2;
|
|
6834
|
+
break _L$19;
|
|
6835
|
+
}
|
|
6836
|
+
case 6: {
|
|
6837
|
+
const _While = stmt;
|
|
6838
|
+
const _cond$3 = _While._0;
|
|
6839
|
+
const _body$3 = _While._1;
|
|
6840
|
+
cond$4 = _cond$3;
|
|
6841
|
+
body$5 = _body$3;
|
|
6842
|
+
break _L$18;
|
|
6843
|
+
}
|
|
6844
|
+
case 7: {
|
|
6845
|
+
const _Until = stmt;
|
|
6846
|
+
const _cond$4 = _Until._0;
|
|
6847
|
+
const _body$4 = _Until._1;
|
|
6848
|
+
cond$3 = _cond$4;
|
|
6849
|
+
body$4 = _body$4;
|
|
6850
|
+
break _L$17;
|
|
6851
|
+
}
|
|
6852
|
+
case 8: {
|
|
6853
|
+
const _ForIn = stmt;
|
|
6854
|
+
const _name$2 = _ForIn._0;
|
|
6855
|
+
const _index = _ForIn._1;
|
|
6856
|
+
const _iter = _ForIn._2;
|
|
6857
|
+
const _body$5 = _ForIn._3;
|
|
6858
|
+
iter$2 = _iter;
|
|
6859
|
+
name$4 = _name$2;
|
|
6860
|
+
index = _index;
|
|
6861
|
+
body$3 = _body$5;
|
|
6862
|
+
break _L$16;
|
|
6863
|
+
}
|
|
6864
|
+
case 9: {
|
|
6865
|
+
const _ForRange = stmt;
|
|
6866
|
+
const _name$3 = _ForRange._0;
|
|
6867
|
+
const _start = _ForRange._1;
|
|
6868
|
+
const _end = _ForRange._2;
|
|
6869
|
+
const _body$6 = _ForRange._3;
|
|
6870
|
+
end = _end;
|
|
6871
|
+
name$3 = _name$3;
|
|
6872
|
+
start = _start;
|
|
6873
|
+
body$2 = _body$6;
|
|
6874
|
+
break _L$15;
|
|
6875
|
+
}
|
|
6876
|
+
case 10: {
|
|
6877
|
+
const _MatchStmt = stmt;
|
|
6878
|
+
const _subject = _MatchStmt._0;
|
|
6879
|
+
const _arms = _MatchStmt._1;
|
|
6880
|
+
subject = _subject;
|
|
6881
|
+
arms = _arms;
|
|
6882
|
+
break _L$14;
|
|
6883
|
+
}
|
|
6884
|
+
case 11: {
|
|
6885
|
+
const _PostfixIf = stmt;
|
|
6886
|
+
const _inner = _PostfixIf._0;
|
|
6887
|
+
const _cond$5 = _PostfixIf._1;
|
|
6888
|
+
inner$5 = _inner;
|
|
6889
|
+
cond$2 = _cond$5;
|
|
6890
|
+
break _L$13;
|
|
6891
|
+
}
|
|
6892
|
+
case 12: {
|
|
6893
|
+
const _PostfixUnless = stmt;
|
|
6894
|
+
const _inner$2 = _PostfixUnless._0;
|
|
6895
|
+
const _cond$6 = _PostfixUnless._1;
|
|
6896
|
+
inner$4 = _inner$2;
|
|
6897
|
+
cond = _cond$6;
|
|
6898
|
+
break _L$12;
|
|
6899
|
+
}
|
|
6900
|
+
case 13: {
|
|
6901
|
+
const _PostfixFor = stmt;
|
|
6902
|
+
const _inner$3 = _PostfixFor._0;
|
|
6903
|
+
const _name$4 = _PostfixFor._1;
|
|
6904
|
+
const _iter$2 = _PostfixFor._2;
|
|
6905
|
+
name$2 = _name$4;
|
|
6906
|
+
inner$3 = _inner$3;
|
|
6907
|
+
iter = _iter$2;
|
|
6908
|
+
break _L$11;
|
|
6909
|
+
}
|
|
6910
|
+
case 14: {
|
|
6911
|
+
const _TryCatch = stmt;
|
|
6912
|
+
const _try_body = _TryCatch._0;
|
|
6913
|
+
const _catch_name = _TryCatch._1;
|
|
6914
|
+
const _catch_body = _TryCatch._2;
|
|
6915
|
+
const _finally_body = _TryCatch._3;
|
|
6916
|
+
catch_body = _catch_body;
|
|
6917
|
+
try_body = _try_body;
|
|
6918
|
+
catch_name = _catch_name;
|
|
6919
|
+
finally_body = _finally_body;
|
|
6920
|
+
break _L$10;
|
|
6921
|
+
}
|
|
6922
|
+
case 15: {
|
|
6923
|
+
const _Throw = stmt;
|
|
6924
|
+
const _expr = _Throw._0;
|
|
6925
|
+
expr$3 = _expr;
|
|
6926
|
+
break _L$9;
|
|
6927
|
+
}
|
|
6928
|
+
case 16: {
|
|
6929
|
+
const _Return = stmt;
|
|
6930
|
+
const _value$4 = _Return._0;
|
|
6931
|
+
value = _value$4;
|
|
6932
|
+
break _L$8;
|
|
6933
|
+
}
|
|
6934
|
+
case 17: {
|
|
6935
|
+
_M0MP28username4core9JsCodegen7writeln(self, "break;");
|
|
6936
|
+
return;
|
|
6937
|
+
}
|
|
6938
|
+
case 18: {
|
|
6939
|
+
_M0MP28username4core9JsCodegen7writeln(self, "continue;");
|
|
6940
|
+
return;
|
|
6941
|
+
}
|
|
6942
|
+
case 19: {
|
|
6943
|
+
const _ExprStmt = stmt;
|
|
6944
|
+
const _expr$2 = _ExprStmt._0;
|
|
6945
|
+
expr$2 = _expr$2;
|
|
6946
|
+
break _L$7;
|
|
6947
|
+
}
|
|
6948
|
+
case 20: {
|
|
6949
|
+
const _ImportDecl = stmt;
|
|
6950
|
+
const _decl$2 = _ImportDecl._0;
|
|
6951
|
+
decl = _decl$2;
|
|
6952
|
+
break _L$6;
|
|
6953
|
+
}
|
|
6954
|
+
case 21: {
|
|
6955
|
+
const _UseDecl = stmt;
|
|
6956
|
+
const _path = _UseDecl._0;
|
|
6957
|
+
const _names$2 = _UseDecl._1;
|
|
6958
|
+
path = _path;
|
|
6959
|
+
names = _names$2;
|
|
6960
|
+
break _L$5;
|
|
6961
|
+
}
|
|
6962
|
+
case 22: {
|
|
6963
|
+
const _ModDecl = stmt;
|
|
6964
|
+
const _name$5 = _ModDecl._0;
|
|
6965
|
+
const _body$7 = _ModDecl._1;
|
|
6966
|
+
name = _name$5;
|
|
6967
|
+
body = _body$7;
|
|
6968
|
+
break _L$4;
|
|
6969
|
+
}
|
|
6970
|
+
case 23: {
|
|
6971
|
+
const _ExportDefault = stmt;
|
|
6972
|
+
const _inner$4 = _ExportDefault._0;
|
|
6973
|
+
inner$2 = _inner$4;
|
|
6974
|
+
break _L$3;
|
|
6975
|
+
}
|
|
6976
|
+
case 24: {
|
|
6977
|
+
const _PubDecl = stmt;
|
|
6978
|
+
const _inner$5 = _PubDecl._0;
|
|
6979
|
+
inner = _inner$5;
|
|
6980
|
+
break _L$2;
|
|
6981
|
+
}
|
|
6982
|
+
case 25: {
|
|
6983
|
+
return;
|
|
6984
|
+
}
|
|
6985
|
+
default: {
|
|
6986
|
+
const _DeleteStmt = stmt;
|
|
6987
|
+
const _expr$3 = _DeleteStmt._0;
|
|
6988
|
+
expr = _expr$3;
|
|
6989
|
+
break _L;
|
|
6990
|
+
}
|
|
6991
|
+
}
|
|
6992
|
+
}
|
|
6993
|
+
let kw;
|
|
6994
|
+
switch (kind$2) {
|
|
6523
6995
|
case 0: {
|
|
6524
|
-
|
|
6525
|
-
|
|
6526
|
-
const _name = _VarDecl._1;
|
|
6527
|
-
const _value = _VarDecl._2;
|
|
6528
|
-
name$5 = _name;
|
|
6529
|
-
kind = _kind;
|
|
6530
|
-
value$3 = _value;
|
|
6531
|
-
break _L$23;
|
|
6996
|
+
kw = "const";
|
|
6997
|
+
break;
|
|
6532
6998
|
}
|
|
6533
6999
|
case 1: {
|
|
6534
|
-
|
|
6535
|
-
|
|
6536
|
-
const _value$2 = _Assign._1;
|
|
6537
|
-
target = _target;
|
|
6538
|
-
value$2 = _value$2;
|
|
6539
|
-
break _L$22;
|
|
6540
|
-
}
|
|
6541
|
-
case 2: {
|
|
6542
|
-
const _FnDecl = stmt;
|
|
6543
|
-
const _decl = _FnDecl._0;
|
|
6544
|
-
decl$2 = _decl;
|
|
6545
|
-
break _L$21;
|
|
6546
|
-
}
|
|
6547
|
-
case 3: {
|
|
6548
|
-
const _If = stmt;
|
|
6549
|
-
const _cond = _If._0;
|
|
6550
|
-
const _body = _If._1;
|
|
6551
|
-
const _elifs = _If._2;
|
|
6552
|
-
const _else_body = _If._3;
|
|
6553
|
-
elifs = _elifs;
|
|
6554
|
-
cond$6 = _cond;
|
|
6555
|
-
body$7 = _body;
|
|
6556
|
-
else_body = _else_body;
|
|
6557
|
-
break _L$20;
|
|
6558
|
-
}
|
|
6559
|
-
case 4: {
|
|
6560
|
-
const _Unless = stmt;
|
|
6561
|
-
const _cond$2 = _Unless._0;
|
|
6562
|
-
const _body$2 = _Unless._1;
|
|
6563
|
-
cond$5 = _cond$2;
|
|
6564
|
-
body$6 = _body$2;
|
|
6565
|
-
break _L$19;
|
|
6566
|
-
}
|
|
6567
|
-
case 5: {
|
|
6568
|
-
const _While = stmt;
|
|
6569
|
-
const _cond$3 = _While._0;
|
|
6570
|
-
const _body$3 = _While._1;
|
|
6571
|
-
cond$4 = _cond$3;
|
|
6572
|
-
body$5 = _body$3;
|
|
6573
|
-
break _L$18;
|
|
6574
|
-
}
|
|
6575
|
-
case 6: {
|
|
6576
|
-
const _Until = stmt;
|
|
6577
|
-
const _cond$4 = _Until._0;
|
|
6578
|
-
const _body$4 = _Until._1;
|
|
6579
|
-
cond$3 = _cond$4;
|
|
6580
|
-
body$4 = _body$4;
|
|
6581
|
-
break _L$17;
|
|
6582
|
-
}
|
|
6583
|
-
case 7: {
|
|
6584
|
-
const _ForIn = stmt;
|
|
6585
|
-
const _name$2 = _ForIn._0;
|
|
6586
|
-
const _index = _ForIn._1;
|
|
6587
|
-
const _iter = _ForIn._2;
|
|
6588
|
-
const _body$5 = _ForIn._3;
|
|
6589
|
-
iter$2 = _iter;
|
|
6590
|
-
name$4 = _name$2;
|
|
6591
|
-
index = _index;
|
|
6592
|
-
body$3 = _body$5;
|
|
6593
|
-
break _L$16;
|
|
6594
|
-
}
|
|
6595
|
-
case 8: {
|
|
6596
|
-
const _ForRange = stmt;
|
|
6597
|
-
const _name$3 = _ForRange._0;
|
|
6598
|
-
const _start = _ForRange._1;
|
|
6599
|
-
const _end = _ForRange._2;
|
|
6600
|
-
const _body$6 = _ForRange._3;
|
|
6601
|
-
end = _end;
|
|
6602
|
-
name$3 = _name$3;
|
|
6603
|
-
start = _start;
|
|
6604
|
-
body$2 = _body$6;
|
|
6605
|
-
break _L$15;
|
|
6606
|
-
}
|
|
6607
|
-
case 9: {
|
|
6608
|
-
const _MatchStmt = stmt;
|
|
6609
|
-
const _subject = _MatchStmt._0;
|
|
6610
|
-
const _arms = _MatchStmt._1;
|
|
6611
|
-
subject = _subject;
|
|
6612
|
-
arms = _arms;
|
|
6613
|
-
break _L$14;
|
|
6614
|
-
}
|
|
6615
|
-
case 10: {
|
|
6616
|
-
const _PostfixIf = stmt;
|
|
6617
|
-
const _inner = _PostfixIf._0;
|
|
6618
|
-
const _cond$5 = _PostfixIf._1;
|
|
6619
|
-
inner$5 = _inner;
|
|
6620
|
-
cond$2 = _cond$5;
|
|
6621
|
-
break _L$13;
|
|
6622
|
-
}
|
|
6623
|
-
case 11: {
|
|
6624
|
-
const _PostfixUnless = stmt;
|
|
6625
|
-
const _inner$2 = _PostfixUnless._0;
|
|
6626
|
-
const _cond$6 = _PostfixUnless._1;
|
|
6627
|
-
inner$4 = _inner$2;
|
|
6628
|
-
cond = _cond$6;
|
|
6629
|
-
break _L$12;
|
|
6630
|
-
}
|
|
6631
|
-
case 12: {
|
|
6632
|
-
const _PostfixFor = stmt;
|
|
6633
|
-
const _inner$3 = _PostfixFor._0;
|
|
6634
|
-
const _name$4 = _PostfixFor._1;
|
|
6635
|
-
const _iter$2 = _PostfixFor._2;
|
|
6636
|
-
name$2 = _name$4;
|
|
6637
|
-
inner$3 = _inner$3;
|
|
6638
|
-
iter = _iter$2;
|
|
6639
|
-
break _L$11;
|
|
6640
|
-
}
|
|
6641
|
-
case 13: {
|
|
6642
|
-
const _TryCatch = stmt;
|
|
6643
|
-
const _try_body = _TryCatch._0;
|
|
6644
|
-
const _catch_name = _TryCatch._1;
|
|
6645
|
-
const _catch_body = _TryCatch._2;
|
|
6646
|
-
const _finally_body = _TryCatch._3;
|
|
6647
|
-
catch_body = _catch_body;
|
|
6648
|
-
try_body = _try_body;
|
|
6649
|
-
catch_name = _catch_name;
|
|
6650
|
-
finally_body = _finally_body;
|
|
6651
|
-
break _L$10;
|
|
6652
|
-
}
|
|
6653
|
-
case 14: {
|
|
6654
|
-
const _Throw = stmt;
|
|
6655
|
-
const _expr = _Throw._0;
|
|
6656
|
-
expr$3 = _expr;
|
|
6657
|
-
break _L$9;
|
|
6658
|
-
}
|
|
6659
|
-
case 15: {
|
|
6660
|
-
const _Return = stmt;
|
|
6661
|
-
const _value$3 = _Return._0;
|
|
6662
|
-
value = _value$3;
|
|
6663
|
-
break _L$8;
|
|
6664
|
-
}
|
|
6665
|
-
case 16: {
|
|
6666
|
-
_M0MP28username4core9JsCodegen7writeln(self, "break;");
|
|
6667
|
-
return;
|
|
6668
|
-
}
|
|
6669
|
-
case 17: {
|
|
6670
|
-
_M0MP28username4core9JsCodegen7writeln(self, "continue;");
|
|
6671
|
-
return;
|
|
6672
|
-
}
|
|
6673
|
-
case 18: {
|
|
6674
|
-
const _ExprStmt = stmt;
|
|
6675
|
-
const _expr$2 = _ExprStmt._0;
|
|
6676
|
-
expr$2 = _expr$2;
|
|
6677
|
-
break _L$7;
|
|
6678
|
-
}
|
|
6679
|
-
case 19: {
|
|
6680
|
-
const _ImportDecl = stmt;
|
|
6681
|
-
const _decl$2 = _ImportDecl._0;
|
|
6682
|
-
decl = _decl$2;
|
|
6683
|
-
break _L$6;
|
|
6684
|
-
}
|
|
6685
|
-
case 20: {
|
|
6686
|
-
const _UseDecl = stmt;
|
|
6687
|
-
const _path = _UseDecl._0;
|
|
6688
|
-
const _names = _UseDecl._1;
|
|
6689
|
-
path = _path;
|
|
6690
|
-
names = _names;
|
|
6691
|
-
break _L$5;
|
|
6692
|
-
}
|
|
6693
|
-
case 21: {
|
|
6694
|
-
const _ModDecl = stmt;
|
|
6695
|
-
const _name$5 = _ModDecl._0;
|
|
6696
|
-
const _body$7 = _ModDecl._1;
|
|
6697
|
-
name = _name$5;
|
|
6698
|
-
body = _body$7;
|
|
6699
|
-
break _L$4;
|
|
6700
|
-
}
|
|
6701
|
-
case 22: {
|
|
6702
|
-
const _ExportDefault = stmt;
|
|
6703
|
-
const _inner$4 = _ExportDefault._0;
|
|
6704
|
-
inner$2 = _inner$4;
|
|
6705
|
-
break _L$3;
|
|
6706
|
-
}
|
|
6707
|
-
case 23: {
|
|
6708
|
-
const _PubDecl = stmt;
|
|
6709
|
-
const _inner$5 = _PubDecl._0;
|
|
6710
|
-
inner = _inner$5;
|
|
6711
|
-
break _L$2;
|
|
6712
|
-
}
|
|
6713
|
-
case 24: {
|
|
6714
|
-
return;
|
|
7000
|
+
kw = "let";
|
|
7001
|
+
break;
|
|
6715
7002
|
}
|
|
6716
7003
|
default: {
|
|
6717
|
-
|
|
6718
|
-
const _expr$3 = _DeleteStmt._0;
|
|
6719
|
-
expr = _expr$3;
|
|
6720
|
-
break _L;
|
|
7004
|
+
kw = "var";
|
|
6721
7005
|
}
|
|
6722
7006
|
}
|
|
7007
|
+
_M0MP28username4core9JsCodegen13write__indent(self);
|
|
7008
|
+
_M0MP28username4core9JsCodegen5write(self, kw);
|
|
7009
|
+
_M0MP28username4core9JsCodegen5write(self, " ");
|
|
7010
|
+
_M0MP28username4core9JsCodegen5write(self, _M0FP28username4core9js__ident(name$5));
|
|
7011
|
+
_M0MP28username4core9JsCodegen5write(self, " = ");
|
|
7012
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, value$4);
|
|
7013
|
+
_M0MP28username4core9JsCodegen5write(self, ";\n");
|
|
7014
|
+
return;
|
|
6723
7015
|
}
|
|
6724
7016
|
let kw;
|
|
6725
7017
|
switch (kind) {
|
|
@@ -6737,18 +7029,98 @@ function _M0MP28username4core9JsCodegen9gen__stmt(self, stmt) {
|
|
|
6737
7029
|
}
|
|
6738
7030
|
_M0MP28username4core9JsCodegen13write__indent(self);
|
|
6739
7031
|
_M0MP28username4core9JsCodegen5write(self, kw);
|
|
6740
|
-
_M0MP28username4core9JsCodegen5write(self, " ");
|
|
6741
|
-
|
|
6742
|
-
|
|
7032
|
+
_M0MP28username4core9JsCodegen5write(self, " [");
|
|
7033
|
+
const first = { val: true };
|
|
7034
|
+
const _arr = names$2;
|
|
7035
|
+
const _len = _arr.length;
|
|
7036
|
+
let _tmp = 0;
|
|
7037
|
+
while (true) {
|
|
7038
|
+
const _i = _tmp;
|
|
7039
|
+
if (_i < _len) {
|
|
7040
|
+
const n = _arr[_i];
|
|
7041
|
+
if (!first.val) {
|
|
7042
|
+
_M0MP28username4core9JsCodegen5write(self, ", ");
|
|
7043
|
+
}
|
|
7044
|
+
_M0MP28username4core9JsCodegen5write(self, _M0FP28username4core9js__ident(n));
|
|
7045
|
+
first.val = false;
|
|
7046
|
+
_tmp = _i + 1 | 0;
|
|
7047
|
+
continue;
|
|
7048
|
+
} else {
|
|
7049
|
+
break;
|
|
7050
|
+
}
|
|
7051
|
+
}
|
|
7052
|
+
_M0MP28username4core9JsCodegen5write(self, "] = ");
|
|
6743
7053
|
_M0MP28username4core9JsCodegen9gen__expr(self, value$3);
|
|
6744
7054
|
_M0MP28username4core9JsCodegen5write(self, ";\n");
|
|
6745
7055
|
return;
|
|
6746
7056
|
}
|
|
7057
|
+
let end$2;
|
|
7058
|
+
let obj;
|
|
7059
|
+
let start$2;
|
|
7060
|
+
let inclusive;
|
|
7061
|
+
_L$23: {
|
|
7062
|
+
if (target.$tag === 10) {
|
|
7063
|
+
const _Slice = target;
|
|
7064
|
+
const _obj = _Slice._0;
|
|
7065
|
+
const _start = _Slice._1;
|
|
7066
|
+
const _end = _Slice._2;
|
|
7067
|
+
const _inclusive = _Slice._3;
|
|
7068
|
+
end$2 = _end;
|
|
7069
|
+
obj = _obj;
|
|
7070
|
+
start$2 = _start;
|
|
7071
|
+
inclusive = _inclusive;
|
|
7072
|
+
break _L$23;
|
|
7073
|
+
} else {
|
|
7074
|
+
_M0MP28username4core9JsCodegen13write__indent(self);
|
|
7075
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, target);
|
|
7076
|
+
_M0MP28username4core9JsCodegen5write(self, " = ");
|
|
7077
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, value$2);
|
|
7078
|
+
_M0MP28username4core9JsCodegen5write(self, ";\n");
|
|
7079
|
+
return;
|
|
7080
|
+
}
|
|
7081
|
+
}
|
|
6747
7082
|
_M0MP28username4core9JsCodegen13write__indent(self);
|
|
6748
|
-
_M0MP28username4core9JsCodegen9gen__expr(self,
|
|
6749
|
-
_M0MP28username4core9JsCodegen5write(self, "
|
|
6750
|
-
_M0MP28username4core9JsCodegen9gen__expr(self,
|
|
6751
|
-
_M0MP28username4core9JsCodegen5write(self, "
|
|
7083
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, obj);
|
|
7084
|
+
_M0MP28username4core9JsCodegen5write(self, ".splice(");
|
|
7085
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, start$2);
|
|
7086
|
+
_M0MP28username4core9JsCodegen5write(self, ", ");
|
|
7087
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self, end$2);
|
|
7088
|
+
_M0MP28username4core9JsCodegen5write(self, " - ");
|
|
7089
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self, start$2);
|
|
7090
|
+
if (inclusive) {
|
|
7091
|
+
_M0MP28username4core9JsCodegen5write(self, " + 1");
|
|
7092
|
+
}
|
|
7093
|
+
let elems;
|
|
7094
|
+
_L$24: {
|
|
7095
|
+
_L$25: {
|
|
7096
|
+
if (value$2.$tag === 8) {
|
|
7097
|
+
const _ArrayLit = value$2;
|
|
7098
|
+
const _elems = _ArrayLit._0;
|
|
7099
|
+
elems = _elems;
|
|
7100
|
+
break _L$25;
|
|
7101
|
+
} else {
|
|
7102
|
+
_M0MP28username4core9JsCodegen5write(self, ", ...");
|
|
7103
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, value$2);
|
|
7104
|
+
}
|
|
7105
|
+
break _L$24;
|
|
7106
|
+
}
|
|
7107
|
+
const _arr = elems;
|
|
7108
|
+
const _len = _arr.length;
|
|
7109
|
+
let _tmp = 0;
|
|
7110
|
+
while (true) {
|
|
7111
|
+
const _i = _tmp;
|
|
7112
|
+
if (_i < _len) {
|
|
7113
|
+
const e = _arr[_i];
|
|
7114
|
+
_M0MP28username4core9JsCodegen5write(self, ", ");
|
|
7115
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, e);
|
|
7116
|
+
_tmp = _i + 1 | 0;
|
|
7117
|
+
continue;
|
|
7118
|
+
} else {
|
|
7119
|
+
break;
|
|
7120
|
+
}
|
|
7121
|
+
}
|
|
7122
|
+
}
|
|
7123
|
+
_M0MP28username4core9JsCodegen5write(self, ");\n");
|
|
6752
7124
|
return;
|
|
6753
7125
|
}
|
|
6754
7126
|
_M0MP28username4core9JsCodegen13gen__fn__decl(self, decl$2);
|
|
@@ -7466,13 +7838,13 @@ function _M0MP28username4core9JsCodegen17gen__stmt__inline(self, stmt) {
|
|
|
7466
7838
|
value$2 = _value;
|
|
7467
7839
|
break _L$5;
|
|
7468
7840
|
}
|
|
7469
|
-
case
|
|
7841
|
+
case 19: {
|
|
7470
7842
|
const _ExprStmt = stmt;
|
|
7471
7843
|
const _expr = _ExprStmt._0;
|
|
7472
7844
|
expr$2 = _expr;
|
|
7473
7845
|
break _L$4;
|
|
7474
7846
|
}
|
|
7475
|
-
case
|
|
7847
|
+
case 16: {
|
|
7476
7848
|
const _Return = stmt;
|
|
7477
7849
|
const _x = _Return._0;
|
|
7478
7850
|
if (_x === undefined) {
|
|
@@ -7485,13 +7857,13 @@ function _M0MP28username4core9JsCodegen17gen__stmt__inline(self, stmt) {
|
|
|
7485
7857
|
break _L$3;
|
|
7486
7858
|
}
|
|
7487
7859
|
}
|
|
7488
|
-
case
|
|
7860
|
+
case 15: {
|
|
7489
7861
|
const _Throw = stmt;
|
|
7490
7862
|
const _expr$2 = _Throw._0;
|
|
7491
7863
|
expr = _expr$2;
|
|
7492
7864
|
break _L$2;
|
|
7493
7865
|
}
|
|
7494
|
-
case
|
|
7866
|
+
case 2: {
|
|
7495
7867
|
const _Assign = stmt;
|
|
7496
7868
|
const _target = _Assign._0;
|
|
7497
7869
|
const _value$2 = _Assign._1;
|
|
@@ -7541,10 +7913,71 @@ function _M0MP28username4core9JsCodegen17gen__stmt__inline(self, stmt) {
|
|
|
7541
7913
|
_M0MP28username4core9JsCodegen5write(self, ";");
|
|
7542
7914
|
return;
|
|
7543
7915
|
}
|
|
7544
|
-
|
|
7545
|
-
|
|
7546
|
-
|
|
7547
|
-
|
|
7916
|
+
let end;
|
|
7917
|
+
let obj;
|
|
7918
|
+
let start;
|
|
7919
|
+
let inclusive;
|
|
7920
|
+
_L$2: {
|
|
7921
|
+
if (target.$tag === 10) {
|
|
7922
|
+
const _Slice = target;
|
|
7923
|
+
const _obj = _Slice._0;
|
|
7924
|
+
const _start = _Slice._1;
|
|
7925
|
+
const _end = _Slice._2;
|
|
7926
|
+
const _inclusive = _Slice._3;
|
|
7927
|
+
end = _end;
|
|
7928
|
+
obj = _obj;
|
|
7929
|
+
start = _start;
|
|
7930
|
+
inclusive = _inclusive;
|
|
7931
|
+
break _L$2;
|
|
7932
|
+
} else {
|
|
7933
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, target);
|
|
7934
|
+
_M0MP28username4core9JsCodegen5write(self, " = ");
|
|
7935
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, value);
|
|
7936
|
+
_M0MP28username4core9JsCodegen5write(self, ";");
|
|
7937
|
+
return;
|
|
7938
|
+
}
|
|
7939
|
+
}
|
|
7940
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, obj);
|
|
7941
|
+
_M0MP28username4core9JsCodegen5write(self, ".splice(");
|
|
7942
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, start);
|
|
7943
|
+
_M0MP28username4core9JsCodegen5write(self, ", ");
|
|
7944
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self, end);
|
|
7945
|
+
_M0MP28username4core9JsCodegen5write(self, " - ");
|
|
7946
|
+
_M0MP28username4core9JsCodegen15gen__expr__wrap(self, start);
|
|
7947
|
+
if (inclusive) {
|
|
7948
|
+
_M0MP28username4core9JsCodegen5write(self, " + 1");
|
|
7949
|
+
}
|
|
7950
|
+
let elems;
|
|
7951
|
+
_L$3: {
|
|
7952
|
+
_L$4: {
|
|
7953
|
+
if (value.$tag === 8) {
|
|
7954
|
+
const _ArrayLit = value;
|
|
7955
|
+
const _elems = _ArrayLit._0;
|
|
7956
|
+
elems = _elems;
|
|
7957
|
+
break _L$4;
|
|
7958
|
+
} else {
|
|
7959
|
+
_M0MP28username4core9JsCodegen5write(self, ", ...");
|
|
7960
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, value);
|
|
7961
|
+
}
|
|
7962
|
+
break _L$3;
|
|
7963
|
+
}
|
|
7964
|
+
const _arr = elems;
|
|
7965
|
+
const _len = _arr.length;
|
|
7966
|
+
let _tmp = 0;
|
|
7967
|
+
while (true) {
|
|
7968
|
+
const _i = _tmp;
|
|
7969
|
+
if (_i < _len) {
|
|
7970
|
+
const e = _arr[_i];
|
|
7971
|
+
_M0MP28username4core9JsCodegen5write(self, ", ");
|
|
7972
|
+
_M0MP28username4core9JsCodegen9gen__expr(self, e);
|
|
7973
|
+
_tmp = _i + 1 | 0;
|
|
7974
|
+
continue;
|
|
7975
|
+
} else {
|
|
7976
|
+
break;
|
|
7977
|
+
}
|
|
7978
|
+
}
|
|
7979
|
+
}
|
|
7980
|
+
_M0MP28username4core9JsCodegen5write(self, ");");
|
|
7548
7981
|
}
|
|
7549
7982
|
function _M0MP28username4core9JsCodegen3new() {
|
|
7550
7983
|
return { buf: _M0MP311moonbitlang4core7builtin13StringBuilder11new_2einner(0), indent_level: 0 };
|
|
@@ -7634,7 +8067,7 @@ function _M0FP48username4core3cmd4main10cmd__build(args) {
|
|
|
7634
8067
|
_L$2: {
|
|
7635
8068
|
_L$3: {
|
|
7636
8069
|
const _bind = _M0MP311moonbitlang4core5array5Array2atGRP28username4core5TokenE(tokens, 0).kind;
|
|
7637
|
-
if (_bind.$tag ===
|
|
8070
|
+
if (_bind.$tag === 84) {
|
|
7638
8071
|
const _Shebang = _bind;
|
|
7639
8072
|
const _s = _Shebang._0;
|
|
7640
8073
|
s = _s;
|
|
@@ -7646,7 +8079,7 @@ function _M0FP48username4core3cmd4main10cmd__build(args) {
|
|
|
7646
8079
|
tok_start.val = 1;
|
|
7647
8080
|
if (tok_start.val < tokens.length) {
|
|
7648
8081
|
const _bind = _M0MP311moonbitlang4core5array5Array2atGRP28username4core5TokenE(tokens, tok_start.val).kind;
|
|
7649
|
-
if (_bind.$tag ===
|
|
8082
|
+
if (_bind.$tag === 82) {
|
|
7650
8083
|
tok_start.val = tok_start.val + 1 | 0;
|
|
7651
8084
|
}
|
|
7652
8085
|
}
|
|
@@ -7664,7 +8097,7 @@ function _M0FP48username4core3cmd4main10cmd__build(args) {
|
|
|
7664
8097
|
}
|
|
7665
8098
|
}
|
|
7666
8099
|
const stmts = _M0MP28username4core6Parser5parse(_M0MP28username4core6Parser3new(filtered));
|
|
7667
|
-
const header = no_header.val ? "" : "// Generated by Purus 0.
|
|
8100
|
+
const header = no_header.val ? "" : "// Generated by Purus 0.4.1";
|
|
7668
8101
|
const js = _M0MP28username4core9JsCodegen16generate_2einner(_M0MP28username4core9JsCodegen3new(), stmts, header, shebang.val);
|
|
7669
8102
|
if (to_stdout.val) {
|
|
7670
8103
|
_M0FP311moonbitlang4core7builtin7printlnGsE(js);
|