@loro-dev/flock 2.0.1 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -443,7 +443,62 @@ function Result$Ok$16$(param0) {
443
443
  Result$Ok$16$.prototype.$tag = 1;
444
444
  const moonbitlang$core$builtin$$get_int64_wasm_helper = function f() {
445
445
  if (f._exports) return f._exports;
446
- return f._exports = new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0, 97, 115, 109, 1, 0, 0, 0, 1, 13, 2, 96, 0, 1, 127, 96, 4, 127, 127, 127, 127, 1, 127, 3, 7, 6, 0, 1, 1, 1, 1, 1, 6, 6, 1, 127, 1, 65, 0, 11, 7, 50, 6, 3, 109, 117, 108, 0, 1, 5, 100, 105, 118, 95, 115, 0, 2, 5, 100, 105, 118, 95, 117, 0, 3, 5, 114, 101, 109, 95, 115, 0, 4, 5, 114, 101, 109, 95, 117, 0, 5, 8, 103, 101, 116, 95, 104, 105, 103, 104, 0, 0, 10, 191, 1, 6, 4, 0, 35, 0, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 126, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 127, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 128, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 129, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 130, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11])), {}).exports;
446
+ if (typeof WebAssembly !== "undefined") {
447
+ try {
448
+ return f._exports = new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0, 97, 115, 109, 1, 0, 0, 0, 1, 13, 2, 96, 0, 1, 127, 96, 4, 127, 127, 127, 127, 1, 127, 3, 7, 6, 0, 1, 1, 1, 1, 1, 6, 6, 1, 127, 1, 65, 0, 11, 7, 50, 6, 3, 109, 117, 108, 0, 1, 5, 100, 105, 118, 95, 115, 0, 2, 5, 100, 105, 118, 95, 117, 0, 3, 5, 114, 101, 109, 95, 115, 0, 4, 5, 114, 101, 109, 95, 117, 0, 5, 8, 103, 101, 116, 95, 104, 105, 103, 104, 0, 0, 10, 191, 1, 6, 4, 0, 35, 0, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 126, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 127, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 128, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 129, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11, 36, 1, 1, 126, 32, 0, 173, 32, 1, 173, 66, 32, 134, 132, 32, 2, 173, 32, 3, 173, 66, 32, 134, 132, 130, 34, 4, 66, 32, 135, 167, 36, 0, 32, 4, 167, 11])), {}).exports;
449
+ } catch (_err) {
450
+ // Fall through to the JS fallback when WebAssembly instantiation is blocked.
451
+ }
452
+ }
453
+ if (typeof BigInt !== "function") {
454
+ throw new Error("WebAssembly unavailable and BigInt unsupported; cannot emulate int64 helpers");
455
+ }
456
+ let high = 0;
457
+ const to_int64 = (lo, hi) => BigInt.asIntN(64, (BigInt(hi >>> 0) << 32n) | BigInt(lo >>> 0));
458
+ const to_uint64 = (lo, hi) => BigInt.asUintN(64, (BigInt(hi >>> 0) << 32n) | BigInt(lo >>> 0));
459
+ const update = (value) => {
460
+ const normalized = BigInt.asUintN(64, value);
461
+ const lo = Number(normalized & 4294967295n) | 0;
462
+ high = Number(normalized >> 32n) | 0;
463
+ return lo;
464
+ };
465
+ const throw_on_divide_by_zero = () => {
466
+ throw new Error("integer divide by zero");
467
+ };
468
+ const div_overflow = -9223372036854775808n;
469
+ const exports = {
470
+ get_high: () => high,
471
+ mul: (alo, ahi, blo, bhi) => {
472
+ const result = to_int64(alo, ahi) * to_int64(blo, bhi);
473
+ return update(result);
474
+ },
475
+ div_s: (alo, ahi, blo, bhi) => {
476
+ const dividend = to_int64(alo, ahi);
477
+ const divisor = to_int64(blo, bhi);
478
+ if (divisor === 0n) return throw_on_divide_by_zero();
479
+ if (dividend === div_overflow && divisor === -1n) return throw_on_divide_by_zero();
480
+ return update(dividend / divisor);
481
+ },
482
+ div_u: (alo, ahi, blo, bhi) => {
483
+ const dividend = to_uint64(alo, ahi);
484
+ const divisor = to_uint64(blo, bhi);
485
+ if (divisor === 0n) return throw_on_divide_by_zero();
486
+ return update(dividend / divisor);
487
+ },
488
+ rem_s: (alo, ahi, blo, bhi) => {
489
+ const dividend = to_int64(alo, ahi);
490
+ const divisor = to_int64(blo, bhi);
491
+ if (divisor === 0n) return throw_on_divide_by_zero();
492
+ return update(dividend % divisor);
493
+ },
494
+ rem_u: (alo, ahi, blo, bhi) => {
495
+ const dividend = to_uint64(alo, ahi);
496
+ const divisor = to_uint64(blo, bhi);
497
+ if (divisor === 0n) return throw_on_divide_by_zero();
498
+ return update(dividend % divisor);
499
+ }
500
+ };
501
+ return f._exports = exports;
447
502
  };
448
503
  const moonbitlang$core$builtin$$MyInt64$compare = (a, b) => {
449
504
  const ahi = a.hi;
@@ -948,11 +1003,11 @@ const zxch3n$expect$$yellow$46$constr$47$2572 = 3;
948
1003
  const zxch3n$expect$$blue$46$constr$47$2574 = 4;
949
1004
  const zxch3n$flock$sorted_map$$range$46$tuple$47$2971 = { _0: true, _1: true };
950
1005
  const zxch3n$flock$sorted_map$$range$46$tuple$47$2972 = { _0: true, _1: true };
951
- const zxch3n$flock$flock$$from_string$46$42$bind$124$593 = ",";
1006
+ const zxch3n$flock$flock$$from_string$46$42$bind$124$598 = ",";
952
1007
  const zxch3n$flock$flock$$zero$46$record$47$3050 = { physical_time: 0, logical_counter: 0 };
953
1008
  const zxch3n$flock$flock$$new$46$42$bind$47$3233 = { physical_time: 0, logical_counter: 0 };
954
- const zxch3n$flock$flock$$import_json$46$inner$46$constr$47$3475 = new Source$Import("import_json");
955
- const zxch3n$flock$flock$$newFlock$46$42$bind$47$3584 = { physical_time: 0, logical_counter: 0 };
1009
+ const zxch3n$flock$flock$$import_json$46$inner$46$constr$47$3484 = new Source$Import("import_json");
1010
+ const zxch3n$flock$flock$$newFlock$46$42$bind$47$3593 = { physical_time: 0, logical_counter: 0 };
956
1011
  (() => {
957
1012
  Yoorkin$jmop$$ffi_init(Yoorkin$jmop$$convert_thrown_error);
958
1013
  })();
@@ -969,10 +1024,10 @@ function moonbitlang$core$abort$$abort$2$(msg) {
969
1024
  return $panic();
970
1025
  }
971
1026
  function moonbitlang$core$abort$$abort$3$(msg) {
972
- return $panic();
1027
+ $panic();
973
1028
  }
974
1029
  function moonbitlang$core$abort$$abort$4$(msg) {
975
- $panic();
1030
+ return $panic();
976
1031
  }
977
1032
  function moonbitlang$core$abort$$abort$5$(msg) {
978
1033
  return $panic();
@@ -1016,7 +1071,7 @@ function moonbitlang$core$abort$$abort$17$(msg) {
1016
1071
  function moonbitlang$core$abort$$abort$18$(msg) {
1017
1072
  return $panic();
1018
1073
  }
1019
- function moonbitlang$core$string$$ToStringView$to_string_view$8$(self) {
1074
+ function moonbitlang$core$string$$ToStringView$to_string_view$7$(self) {
1020
1075
  return { str: self, start: 0, end: self.length };
1021
1076
  }
1022
1077
  function moonbitlang$core$uint$$UInt$to_int64(self) {
@@ -1032,7 +1087,7 @@ function moonbitlang$core$bytes$$BytesView$at(self, index) {
1032
1087
  $bound_check(_tmp, _tmp$2);
1033
1088
  return _tmp[_tmp$2];
1034
1089
  } else {
1035
- return moonbitlang$core$abort$$abort$12$(`index out of bounds: the len is from 0 to ${moonbitlang$core$builtin$$Show$to_string$19$(self.end - self.start | 0)} but the index is ${moonbitlang$core$builtin$$Show$to_string$19$(index)}`);
1090
+ return moonbitlang$core$abort$$abort$13$(`index out of bounds: the len is from 0 to ${moonbitlang$core$builtin$$Show$to_string$19$(self.end - self.start | 0)} but the index is ${moonbitlang$core$builtin$$Show$to_string$19$(index)}`);
1036
1091
  }
1037
1092
  }
1038
1093
  function moonbitlang$core$bytes$$Bytes$sub$46$inner(self, start, end) {
@@ -1101,13 +1156,13 @@ function moonbitlang$core$bytes$$BytesView$iterator(self) {
1101
1156
  return _p;
1102
1157
  }
1103
1158
  function moonbitlang$core$bytes$$Bytes$from_array(arr) {
1104
- return moonbitlang$core$bytes$$Bytes$makei$20$(arr.end - arr.start | 0, (i) => moonbitlang$core$array$$ArrayView$at$12$(arr, i));
1159
+ return moonbitlang$core$bytes$$Bytes$makei$20$(arr.end - arr.start | 0, (i) => moonbitlang$core$array$$ArrayView$at$13$(arr, i));
1105
1160
  }
1106
1161
  function moonbitlang$core$bytes$$Bytes$from_iter(iter) {
1107
- const _bind = moonbitlang$core$builtin$$Iter$collect$12$(iter);
1162
+ const _bind = moonbitlang$core$builtin$$Iter$collect$13$(iter);
1108
1163
  return moonbitlang$core$bytes$$Bytes$from_array({ buf: _bind, start: 0, end: _bind.length });
1109
1164
  }
1110
- function moonbitlang$core$builtin$$Hash$hash_combine$3$(self, hasher) {
1165
+ function moonbitlang$core$builtin$$Hash$hash_combine$2$(self, hasher) {
1111
1166
  moonbitlang$core$builtin$$Hasher$combine$11$(hasher, moonbitlang$core$bytes$$Bytes$sub$46$inner(self, 0, self.length));
1112
1167
  }
1113
1168
  function moonbitlang$core$env$$now() {
@@ -1136,7 +1191,7 @@ function moonbitlang$core$builtin$$Mod$mod$21$(self, other) {
1136
1191
  }
1137
1192
  function moonbitlang$core$builtin$$Shr$shr$21$(self, n) {
1138
1193
  if (n < 0) {
1139
- moonbitlang$core$abort$$abort$4$("negative shift count");
1194
+ moonbitlang$core$abort$$abort$3$("negative shift count");
1140
1195
  }
1141
1196
  return moonbitlang$core$bigint$$BigInt$js_shr(self, n);
1142
1197
  }
@@ -1420,10 +1475,10 @@ function moonbitlang$core$strconv$$check_and_consume_base(view, base) {
1420
1475
  function moonbitlang$core$strconv$$range_err$22$() {
1421
1476
  return new Result$Err$1$(new Error$moonbitlang$47$core$47$strconv$46$StrConvError$46$StrConvError(moonbitlang$core$strconv$$range_err_str));
1422
1477
  }
1423
- function moonbitlang$core$strconv$$range_err$4$() {
1478
+ function moonbitlang$core$strconv$$range_err$3$() {
1424
1479
  return new Result$Err$2$(new Error$moonbitlang$47$core$47$strconv$46$StrConvError$46$StrConvError(moonbitlang$core$strconv$$range_err_str));
1425
1480
  }
1426
- function moonbitlang$core$strconv$$syntax_err$13$() {
1481
+ function moonbitlang$core$strconv$$syntax_err$12$() {
1427
1482
  return new Result$Err$3$(new Error$moonbitlang$47$core$47$strconv$46$StrConvError$46$StrConvError(moonbitlang$core$strconv$$syntax_err_str));
1428
1483
  }
1429
1484
  function moonbitlang$core$strconv$$syntax_err$22$() {
@@ -1435,7 +1490,7 @@ function moonbitlang$core$strconv$$syntax_err$24$() {
1435
1490
  function moonbitlang$core$strconv$$syntax_err$25$() {
1436
1491
  return new Result$Err$5$(new Error$moonbitlang$47$core$47$strconv$46$StrConvError$46$StrConvError(moonbitlang$core$strconv$$syntax_err_str));
1437
1492
  }
1438
- function moonbitlang$core$strconv$$syntax_err$16$() {
1493
+ function moonbitlang$core$strconv$$syntax_err$15$() {
1439
1494
  return new Result$Err$6$(new Error$moonbitlang$47$core$47$strconv$46$StrConvError$46$StrConvError(moonbitlang$core$strconv$$syntax_err_str));
1440
1495
  }
1441
1496
  function moonbitlang$core$strconv$$syntax_err$26$() {
@@ -1445,7 +1500,7 @@ function moonbitlang$core$strconv$$overflow_threshold(base, neg) {
1445
1500
  return !neg ? (base === 10 ? moonbitlang$core$builtin$$Add$add$22$(moonbitlang$core$builtin$$Div$div$22$($9223372036854775807L, $10L), $1L) : base === 16 ? moonbitlang$core$builtin$$Add$add$22$(moonbitlang$core$builtin$$Div$div$22$($9223372036854775807L, $16L), $1L) : moonbitlang$core$builtin$$Add$add$22$(moonbitlang$core$builtin$$Div$div$22$($9223372036854775807L, moonbitlang$core$int$$Int$to_int64(base)), $1L)) : base === 10 ? moonbitlang$core$builtin$$Div$div$22$($_9223372036854775808L, $10L) : base === 16 ? moonbitlang$core$builtin$$Div$div$22$($_9223372036854775808L, $16L) : moonbitlang$core$builtin$$Div$div$22$($_9223372036854775808L, moonbitlang$core$int$$Int$to_int64(base));
1446
1501
  }
1447
1502
  function moonbitlang$core$strconv$$parse_int64$46$inner(str, base) {
1448
- if (moonbitlang$core$builtin$$op_notequal$16$(str, { str: moonbitlang$core$strconv$$parse_int64$46$inner$46$42$bind$124$600, start: 0, end: moonbitlang$core$strconv$$parse_int64$46$inner$46$42$bind$124$600.length })) {
1503
+ if (moonbitlang$core$builtin$$op_notequal$15$(str, { str: moonbitlang$core$strconv$$parse_int64$46$inner$46$42$bind$124$600, start: 0, end: moonbitlang$core$strconv$$parse_int64$46$inner$46$42$bind$124$600.length })) {
1449
1504
  let _bind;
1450
1505
  let rest;
1451
1506
  _L: {
@@ -1643,7 +1698,7 @@ function moonbitlang$core$strconv$$parse_int64$46$inner(str, base) {
1643
1698
  if (c$2 >= 65 && c$2 <= 90) {
1644
1699
  d = c$2 + -55 | 0;
1645
1700
  } else {
1646
- const _bind$4 = moonbitlang$core$strconv$$syntax_err$13$();
1701
+ const _bind$4 = moonbitlang$core$strconv$$syntax_err$12$();
1647
1702
  if (_bind$4.$tag === 1) {
1648
1703
  const _ok = _bind$4;
1649
1704
  d = _ok._0;
@@ -2123,7 +2178,7 @@ function moonbitlang$core$strconv$$parse_decimal_from_view(str) {
2123
2178
  _tmp = _x$2;
2124
2179
  continue;
2125
2180
  } else {
2126
- const _bind$2 = moonbitlang$core$strconv$$syntax_err$16$();
2181
+ const _bind$2 = moonbitlang$core$strconv$$syntax_err$15$();
2127
2182
  if (_bind$2.$tag === 1) {
2128
2183
  const _ok = _bind$2;
2129
2184
  rest$2 = _ok._0;
@@ -2329,7 +2384,7 @@ function moonbitlang$core$strconv$$parse_decimal_from_view(str) {
2329
2384
  }
2330
2385
  break _L$4;
2331
2386
  }
2332
- const _bind = moonbitlang$core$strconv$$syntax_err$16$();
2387
+ const _bind = moonbitlang$core$strconv$$syntax_err$15$();
2333
2388
  if (_bind.$tag === 1) {
2334
2389
  const _ok = _bind;
2335
2390
  rest$3 = _ok._0;
@@ -3935,7 +3990,7 @@ function moonbitlang$core$strconv$$Decimal$to_double_priv(self) {
3935
3990
  return new Result$Ok$4$(moonbitlang$core$int64$$Int64$reinterpret_as_double(bits));
3936
3991
  }
3937
3992
  if (self.decimal_point > 310) {
3938
- const _bind = moonbitlang$core$strconv$$range_err$4$();
3993
+ const _bind = moonbitlang$core$strconv$$range_err$3$();
3939
3994
  if (_bind.$tag === 1) {
3940
3995
  const _ok = _bind;
3941
3996
  _ok._0;
@@ -3998,7 +4053,7 @@ function moonbitlang$core$strconv$$Decimal$to_double_priv(self) {
3998
4053
  exponent = exponent + n | 0;
3999
4054
  }
4000
4055
  if ((exponent - moonbitlang$core$strconv$$double_info.bias | 0) >= ((1 << moonbitlang$core$strconv$$double_info.exponent_bits) - 1 | 0)) {
4001
- const _bind = moonbitlang$core$strconv$$range_err$4$();
4056
+ const _bind = moonbitlang$core$strconv$$range_err$3$();
4002
4057
  if (_bind.$tag === 1) {
4003
4058
  const _ok = _bind;
4004
4059
  _ok._0;
@@ -4012,7 +4067,7 @@ function moonbitlang$core$strconv$$Decimal$to_double_priv(self) {
4012
4067
  mantissa = moonbitlang$core$builtin$$Shr$shr$22$(mantissa, 1);
4013
4068
  exponent = exponent + 1 | 0;
4014
4069
  if ((exponent - moonbitlang$core$strconv$$double_info.bias | 0) >= ((1 << moonbitlang$core$strconv$$double_info.exponent_bits) - 1 | 0)) {
4015
- const _bind = moonbitlang$core$strconv$$range_err$4$();
4070
+ const _bind = moonbitlang$core$strconv$$range_err$3$();
4016
4071
  if (_bind.$tag === 1) {
4017
4072
  const _ok = _bind;
4018
4073
  _ok._0;
@@ -4155,7 +4210,7 @@ function moonbitlang$core$json$$ParseContext$invalid_char$46$inner$14$(ctx, shif
4155
4210
  const _p$2 = 65533;
4156
4211
  return new Result$Err$9$(new Error$moonbitlang$47$core$47$json$46$ParseError$46$InvalidChar(moonbitlang$core$json$$offset_to_position(ctx.input, offset), _p === -1 ? _p$2 : _p));
4157
4212
  }
4158
- function moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, shift) {
4213
+ function moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, shift) {
4159
4214
  const offset = ctx.offset + shift | 0;
4160
4215
  const _p = moonbitlang$core$string$$StringView$get_char(ctx.input, offset);
4161
4216
  const _p$2 = 65533;
@@ -4205,7 +4260,7 @@ function moonbitlang$core$builtin$$Show$output$14$(self, logger) {
4205
4260
  const _String = self;
4206
4261
  const _s = _String._0;
4207
4262
  logger.method_0(logger.self, "String(");
4208
- moonbitlang$core$builtin$$Show$output$8$(_s, logger);
4263
+ moonbitlang$core$builtin$$Show$output$7$(_s, logger);
4209
4264
  logger.method_0(logger.self, ")");
4210
4265
  return;
4211
4266
  }
@@ -4331,7 +4386,7 @@ function moonbitlang$core$json$$ParseContext$expect_ascii_char(ctx, c) {
4331
4386
  const _tmp$2 = _p.start + _p$2 | 0;
4332
4387
  const c1 = _tmp.charCodeAt(_tmp$2);
4333
4388
  ctx.offset = ctx.offset + 1 | 0;
4334
- return c !== c1 ? moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1) : new Result$Ok$10$(undefined);
4389
+ return c !== c1 ? moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1) : new Result$Ok$10$(undefined);
4335
4390
  } else {
4336
4391
  return new Result$Err$10$(Error$moonbitlang$47$core$47$json$46$ParseError$46$InvalidEof);
4337
4392
  }
@@ -4611,7 +4666,7 @@ function moonbitlang$core$json$$ParseContext$lex_hex_digits(ctx, n) {
4611
4666
  if (_c >= 65) {
4612
4667
  const d = ((_c & ~32) - 65 | 0) + 10 | 0;
4613
4668
  if (d > 15) {
4614
- const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
4669
+ const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
4615
4670
  if (_bind$2.$tag === 1) {
4616
4671
  const _ok = _bind$2;
4617
4672
  _ok._0;
@@ -4624,7 +4679,7 @@ function moonbitlang$core$json$$ParseContext$lex_hex_digits(ctx, n) {
4624
4679
  if (_c >= 48) {
4625
4680
  const d = _c - 48 | 0;
4626
4681
  if (d > 9) {
4627
- const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
4682
+ const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
4628
4683
  if (_bind$2.$tag === 1) {
4629
4684
  const _ok = _bind$2;
4630
4685
  _ok._0;
@@ -4634,7 +4689,7 @@ function moonbitlang$core$json$$ParseContext$lex_hex_digits(ctx, n) {
4634
4689
  }
4635
4690
  r = r << 4 | d;
4636
4691
  } else {
4637
- const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
4692
+ const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
4638
4693
  if (_bind$2.$tag === 1) {
4639
4694
  const _ok = _bind$2;
4640
4695
  _ok._0;
@@ -4746,7 +4801,7 @@ function moonbitlang$core$json$$ParseContext$lex_string(ctx) {
4746
4801
  break;
4747
4802
  }
4748
4803
  default: {
4749
- const _bind$4 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
4804
+ const _bind$4 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
4750
4805
  if (_bind$4.$tag === 1) {
4751
4806
  const _ok = _bind$4;
4752
4807
  _ok._0;
@@ -4761,7 +4816,7 @@ function moonbitlang$core$json$$ParseContext$lex_string(ctx) {
4761
4816
  }
4762
4817
  default: {
4763
4818
  if (_x < 32) {
4764
- const _bind$3 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
4819
+ const _bind$3 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
4765
4820
  if (_bind$3.$tag === 1) {
4766
4821
  const _ok = _bind$3;
4767
4822
  _ok._0;
@@ -4776,7 +4831,7 @@ function moonbitlang$core$json$$ParseContext$lex_string(ctx) {
4776
4831
  }
4777
4832
  break _L$3;
4778
4833
  }
4779
- const _bind = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
4834
+ const _bind = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
4780
4835
  if (_bind.$tag === 1) {
4781
4836
  const _ok = _bind;
4782
4837
  _ok._0;
@@ -4811,7 +4866,7 @@ function moonbitlang$core$json$$ParseContext$lex_zero(ctx, start) {
4811
4866
  default: {
4812
4867
  if (_x >= 48 && _x <= 57) {
4813
4868
  ctx.offset = ctx.offset - 1 | 0;
4814
- const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, 0);
4869
+ const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, 0);
4815
4870
  if (_bind$2.$tag === 1) {
4816
4871
  const _ok = _bind$2;
4817
4872
  _ok._0;
@@ -4860,7 +4915,7 @@ function moonbitlang$core$json$$ParseContext$lex_value(ctx, allow_rbracket) {
4860
4915
  if (allow_rbracket) {
4861
4916
  return new Result$Ok$12$($64$moonbitlang$47$core$47$json$46$Token$RBracket);
4862
4917
  } else {
4863
- const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
4918
+ const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
4864
4919
  if (_bind$2.$tag === 1) {
4865
4920
  const _ok = _bind$2;
4866
4921
  _ok._0;
@@ -4966,7 +5021,7 @@ function moonbitlang$core$json$$ParseContext$lex_value(ctx, allow_rbracket) {
4966
5021
  }
4967
5022
  const _n = _bind$4._0;
4968
5023
  const _repr = _bind$4._1;
4969
- return new Result$Ok$12$(new $64$moonbitlang$47$core$47$json$46$Token$Number(_n, moonbitlang$core$option$$Option$map$36$(_repr, (_hole203) => moonbitlang$core$builtin$$Show$to_string$16$(_hole203))));
5024
+ return new Result$Ok$12$(new $64$moonbitlang$47$core$47$json$46$Token$Number(_n, moonbitlang$core$option$$Option$map$36$(_repr, (_hole203) => moonbitlang$core$builtin$$Show$to_string$15$(_hole203))));
4970
5025
  } else {
4971
5026
  if (_x$2 >= 49 && _x$2 <= 57) {
4972
5027
  const _bind$3 = moonbitlang$core$json$$ParseContext$lex_decimal_integer(ctx, ctx.offset - 2 | 0);
@@ -4979,9 +5034,9 @@ function moonbitlang$core$json$$ParseContext$lex_value(ctx, allow_rbracket) {
4979
5034
  }
4980
5035
  const _n = _bind$4._0;
4981
5036
  const _repr = _bind$4._1;
4982
- return new Result$Ok$12$(new $64$moonbitlang$47$core$47$json$46$Token$Number(_n, moonbitlang$core$option$$Option$map$36$(_repr, (_hole208) => moonbitlang$core$builtin$$Show$to_string$16$(_hole208))));
5037
+ return new Result$Ok$12$(new $64$moonbitlang$47$core$47$json$46$Token$Number(_n, moonbitlang$core$option$$Option$map$36$(_repr, (_hole208) => moonbitlang$core$builtin$$Show$to_string$15$(_hole208))));
4983
5038
  }
4984
- const _bind$3 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
5039
+ const _bind$3 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
4985
5040
  if (_bind$3.$tag === 1) {
4986
5041
  const _ok = _bind$3;
4987
5042
  _ok._0;
@@ -5002,7 +5057,7 @@ function moonbitlang$core$json$$ParseContext$lex_value(ctx, allow_rbracket) {
5002
5057
  }
5003
5058
  const _n = _bind$3._0;
5004
5059
  const _repr = _bind$3._1;
5005
- return new Result$Ok$12$(new $64$moonbitlang$47$core$47$json$46$Token$Number(_n, moonbitlang$core$option$$Option$map$36$(_repr, (_hole212) => moonbitlang$core$builtin$$Show$to_string$16$(_hole212))));
5060
+ return new Result$Ok$12$(new $64$moonbitlang$47$core$47$json$46$Token$Number(_n, moonbitlang$core$option$$Option$map$36$(_repr, (_hole212) => moonbitlang$core$builtin$$Show$to_string$15$(_hole212))));
5006
5061
  } else {
5007
5062
  if (_x >= 49 && _x <= 57) {
5008
5063
  const _bind$2 = moonbitlang$core$json$$ParseContext$lex_decimal_integer(ctx, ctx.offset - 1 | 0);
@@ -5015,7 +5070,7 @@ function moonbitlang$core$json$$ParseContext$lex_value(ctx, allow_rbracket) {
5015
5070
  }
5016
5071
  const _n = _bind$3._0;
5017
5072
  const _repr = _bind$3._1;
5018
- return new Result$Ok$12$(new $64$moonbitlang$47$core$47$json$46$Token$Number(_n, moonbitlang$core$option$$Option$map$36$(_repr, (_hole216) => moonbitlang$core$builtin$$Show$to_string$16$(_hole216))));
5073
+ return new Result$Ok$12$(new $64$moonbitlang$47$core$47$json$46$Token$Number(_n, moonbitlang$core$option$$Option$map$36$(_repr, (_hole216) => moonbitlang$core$builtin$$Show$to_string$15$(_hole216))));
5019
5074
  } else {
5020
5075
  if (_x === 34) {
5021
5076
  const _bind$2 = moonbitlang$core$json$$ParseContext$lex_string(ctx);
@@ -5033,7 +5088,7 @@ function moonbitlang$core$json$$ParseContext$lex_value(ctx, allow_rbracket) {
5033
5088
  }
5034
5089
  const _p = _x;
5035
5090
  const shift = -(_p <= 65535 ? 1 : 2) | 0;
5036
- const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, shift);
5091
+ const _bind$2 = moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, shift);
5037
5092
  if (_bind$2.$tag === 1) {
5038
5093
  const _ok = _bind$2;
5039
5094
  _ok._0;
@@ -5117,7 +5172,7 @@ function moonbitlang$core$json$$ParseContext$lex_after_property_name(ctx) {
5117
5172
  if (_x === 58) {
5118
5173
  return new Result$Ok$10$(undefined);
5119
5174
  } else {
5120
- return moonbitlang$core$json$$ParseContext$invalid_char$46$inner$4$(ctx, -1);
5175
+ return moonbitlang$core$json$$ParseContext$invalid_char$46$inner$3$(ctx, -1);
5121
5176
  }
5122
5177
  }
5123
5178
  }
@@ -5649,7 +5704,7 @@ function moonbitlang$core$json$$Json$as_number(self) {
5649
5704
  return Option$None$8$;
5650
5705
  }
5651
5706
  }
5652
- function moonbitlang$core$array$$ArrayView$join$8$(self, separator) {
5707
+ function moonbitlang$core$array$$ArrayView$join$7$(self, separator) {
5653
5708
  if ((self.end - self.start | 0) === 0) {
5654
5709
  return "";
5655
5710
  } else {
@@ -5658,7 +5713,7 @@ function moonbitlang$core$array$$ArrayView$join$8$(self, separator) {
5658
5713
  const _bind$2 = 1 + self.start | 0;
5659
5714
  const _bind$3 = self.end;
5660
5715
  const _x = { buf: _bind, start: _bind$2, end: _bind$3 };
5661
- const hd = moonbitlang$core$string$$ToStringView$to_string_view$8$(_hd);
5716
+ const hd = moonbitlang$core$string$$ToStringView$to_string_view$7$(_hd);
5662
5717
  let size_hint = hd.end - hd.start | 0;
5663
5718
  const _len = _x.end - _x.start | 0;
5664
5719
  let _tmp = 0;
@@ -5667,7 +5722,7 @@ function moonbitlang$core$array$$ArrayView$join$8$(self, separator) {
5667
5722
  if (_i < _len) {
5668
5723
  const s = _bind[_bind$2 + _i | 0];
5669
5724
  const _tmp$2 = size_hint;
5670
- const _p = moonbitlang$core$string$$ToStringView$to_string_view$8$(s);
5725
+ const _p = moonbitlang$core$string$$ToStringView$to_string_view$7$(s);
5671
5726
  size_hint = _tmp$2 + ((_p.end - _p.start | 0) + (separator.end - separator.start | 0) | 0) | 0;
5672
5727
  _tmp = _i + 1 | 0;
5673
5728
  continue;
@@ -5685,7 +5740,7 @@ function moonbitlang$core$array$$ArrayView$join$8$(self, separator) {
5685
5740
  const _i = _tmp$2;
5686
5741
  if (_i < _len$2) {
5687
5742
  const s = _bind[_bind$2 + _i | 0];
5688
- const s$2 = moonbitlang$core$string$$ToStringView$to_string_view$8$(s);
5743
+ const s$2 = moonbitlang$core$string$$ToStringView$to_string_view$7$(s);
5689
5744
  moonbitlang$core$builtin$$Logger$write_substring$35$(buf, s$2.str, s$2.start, s$2.end - s$2.start | 0);
5690
5745
  _tmp$2 = _i + 1 | 0;
5691
5746
  continue;
@@ -5700,7 +5755,7 @@ function moonbitlang$core$array$$ArrayView$join$8$(self, separator) {
5700
5755
  const _i = _tmp$2;
5701
5756
  if (_i < _len$2) {
5702
5757
  const s = _bind[_bind$2 + _i | 0];
5703
- const s$2 = moonbitlang$core$string$$ToStringView$to_string_view$8$(s);
5758
+ const s$2 = moonbitlang$core$string$$ToStringView$to_string_view$7$(s);
5704
5759
  moonbitlang$core$builtin$$Logger$write_substring$35$(buf, separator.str, separator.start, separator.end - separator.start | 0);
5705
5760
  moonbitlang$core$builtin$$Logger$write_substring$35$(buf, s$2.str, s$2.start, s$2.end - s$2.start | 0);
5706
5761
  _tmp$2 = _i + 1 | 0;
@@ -5713,7 +5768,7 @@ function moonbitlang$core$array$$ArrayView$join$8$(self, separator) {
5713
5768
  return buf.val;
5714
5769
  }
5715
5770
  }
5716
- function moonbitlang$core$array$$FixedArray$copy$12$(self) {
5771
+ function moonbitlang$core$array$$FixedArray$copy$13$(self) {
5717
5772
  return moonbitlang$core$array$$JSArray$copy(self);
5718
5773
  }
5719
5774
  function moonbitlang$core$array$$Array$copy$14$(self) {
@@ -5733,8 +5788,8 @@ function moonbitlang$core$array$$Array$last$42$(self) {
5733
5788
  return _last;
5734
5789
  }
5735
5790
  }
5736
- function moonbitlang$core$array$$Array$join$8$(self, separator) {
5737
- return moonbitlang$core$array$$ArrayView$join$8$({ buf: self, start: 0, end: self.length }, separator);
5791
+ function moonbitlang$core$array$$Array$join$7$(self, separator) {
5792
+ return moonbitlang$core$array$$ArrayView$join$7$({ buf: self, start: 0, end: self.length }, separator);
5738
5793
  }
5739
5794
  function moonbitlang$core$double$internal$ryu$$string_from_bytes(bytes, from, to) {
5740
5795
  const buf = moonbitlang$core$builtin$$StringBuilder$new$46$inner(bytes.length);
@@ -5795,7 +5850,7 @@ function moonbitlang$core$double$internal$ryu$$pow5Factor(value) {
5795
5850
  break;
5796
5851
  }
5797
5852
  }
5798
- return moonbitlang$core$abort$$abort$13$(`IllegalArgumentException ${moonbitlang$core$builtin$$Show$to_string$28$(value$2)}`);
5853
+ return moonbitlang$core$abort$$abort$12$(`IllegalArgumentException ${moonbitlang$core$builtin$$Show$to_string$28$(value$2)}`);
5799
5854
  }
5800
5855
  function moonbitlang$core$double$internal$ryu$$multipleOfPowerOf5(value, p) {
5801
5856
  return moonbitlang$core$double$internal$ryu$$pow5Factor(value) >= p;
@@ -6386,7 +6441,7 @@ function moonbitlang$core$buffer$$Buffer$grow_if_necessary(self, required) {
6386
6441
  }
6387
6442
  if (enough_space !== self.data.length) {
6388
6443
  const new_data = $makebytes(enough_space, 0);
6389
- moonbitlang$core$array$$FixedArray$unsafe_blit$12$(new_data, 0, self.data, 0, self.len);
6444
+ moonbitlang$core$array$$FixedArray$unsafe_blit$13$(new_data, 0, self.data, 0, self.len);
6390
6445
  self.data = new_data;
6391
6446
  return;
6392
6447
  } else {
@@ -6402,7 +6457,7 @@ function moonbitlang$core$buffer$$Buffer$write_byte(self, value) {
6402
6457
  self.len = self.len + 1 | 0;
6403
6458
  }
6404
6459
  function moonbitlang$core$buffer$$Buffer$contents(self) {
6405
- return moonbitlang$core$bytes$$Bytes$from_array(moonbitlang$core$array$$FixedArray$sub$46$inner$12$(self.data, 0, self.len));
6460
+ return moonbitlang$core$bytes$$Bytes$from_array(moonbitlang$core$array$$FixedArray$sub$46$inner$13$(self.data, 0, self.len));
6406
6461
  }
6407
6462
  function moonbitlang$core$buffer$$new$46$inner(size_hint) {
6408
6463
  const initial = size_hint < 1 ? 1 : size_hint;
@@ -6420,13 +6475,13 @@ function moonbitlang$core$builtin$$Logger$write_char$43$(self, value) {
6420
6475
  const inc = moonbitlang$core$array$$FixedArray$set_utf16le_char(self.data, self.len, value);
6421
6476
  self.len = self.len + inc | 0;
6422
6477
  }
6423
- function moonbitlang$core$builtin$$Logger$write_object$8$(self, obj) {
6424
- moonbitlang$core$builtin$$Show$output$8$(obj, self);
6478
+ function moonbitlang$core$builtin$$Logger$write_object$7$(self, obj) {
6479
+ moonbitlang$core$builtin$$Show$output$7$(obj, self);
6425
6480
  }
6426
6481
  function moonbitlang$core$builtin$$Logger$write_object$14$(self, obj) {
6427
6482
  moonbitlang$core$builtin$$Show$output$14$(obj, self);
6428
6483
  }
6429
- function moonbitlang$core$array$$FixedArray$unsafe_blit$12$(dst, dst_offset, src, src_offset, len) {
6484
+ function moonbitlang$core$array$$FixedArray$unsafe_blit$13$(dst, dst_offset, src, src_offset, len) {
6430
6485
  if (dst === src && dst_offset < src_offset) {
6431
6486
  let _tmp = 0;
6432
6487
  while (true) {
@@ -6481,8 +6536,8 @@ function moonbitlang$core$string$$String$unsafe_char_at(self, index) {
6481
6536
  return c1;
6482
6537
  }
6483
6538
  }
6484
- function moonbitlang$core$builtin$$op_notequal$7$(x, y) {
6485
- return !moonbitlang$core$builtin$$Eq$equal$7$(x, y);
6539
+ function moonbitlang$core$builtin$$op_notequal$6$(x, y) {
6540
+ return !moonbitlang$core$builtin$$Eq$equal$6$(x, y);
6486
6541
  }
6487
6542
  function moonbitlang$core$builtin$$op_notequal$44$(x, y) {
6488
6543
  return !moonbitlang$core$builtin$$Eq$equal$45$(x, y);
@@ -6499,10 +6554,10 @@ function moonbitlang$core$builtin$$op_notequal$48$(x, y) {
6499
6554
  function moonbitlang$core$builtin$$op_notequal$0$(x, y) {
6500
6555
  return !moonbitlang$core$builtin$$Eq$equal$0$(x, y);
6501
6556
  }
6502
- function moonbitlang$core$builtin$$op_notequal$16$(x, y) {
6503
- return !moonbitlang$core$builtin$$Eq$equal$16$(x, y);
6557
+ function moonbitlang$core$builtin$$op_notequal$15$(x, y) {
6558
+ return !moonbitlang$core$builtin$$Eq$equal$15$(x, y);
6504
6559
  }
6505
- function moonbitlang$core$array$$Array$at$42$(self, index) {
6560
+ function moonbitlang$core$array$$Array$at$50$(self, index) {
6506
6561
  const len = self.length;
6507
6562
  if (index >= 0 && index < len) {
6508
6563
  $bound_check(self, index);
@@ -6511,7 +6566,7 @@ function moonbitlang$core$array$$Array$at$42$(self, index) {
6511
6566
  return $panic();
6512
6567
  }
6513
6568
  }
6514
- function moonbitlang$core$array$$Array$at$50$(self, index) {
6569
+ function moonbitlang$core$array$$Array$at$51$(self, index) {
6515
6570
  const len = self.length;
6516
6571
  if (index >= 0 && index < len) {
6517
6572
  $bound_check(self, index);
@@ -6520,7 +6575,7 @@ function moonbitlang$core$array$$Array$at$50$(self, index) {
6520
6575
  return $panic();
6521
6576
  }
6522
6577
  }
6523
- function moonbitlang$core$array$$Array$at$51$(self, index) {
6578
+ function moonbitlang$core$array$$Array$at$42$(self, index) {
6524
6579
  const len = self.length;
6525
6580
  if (index >= 0 && index < len) {
6526
6581
  $bound_check(self, index);
@@ -6556,7 +6611,7 @@ function moonbitlang$core$array$$Array$at$17$(self, index) {
6556
6611
  return $panic();
6557
6612
  }
6558
6613
  }
6559
- function moonbitlang$core$array$$Array$at$12$(self, index) {
6614
+ function moonbitlang$core$array$$Array$at$13$(self, index) {
6560
6615
  const len = self.length;
6561
6616
  if (index >= 0 && index < len) {
6562
6617
  $bound_check(self, index);
@@ -6596,14 +6651,14 @@ function moonbitlang$core$builtin$$Logger$write_string$35$(self, str) {
6596
6651
  const _bind = self;
6597
6652
  _bind.val = `${_bind.val}${str}`;
6598
6653
  }
6599
- function moonbitlang$core$builtin$$Hasher$combine$8$(self, value) {
6600
- moonbitlang$core$builtin$$Hash$hash_combine$8$(value, self);
6601
- }
6602
6654
  function moonbitlang$core$builtin$$Hasher$combine$7$(self, value) {
6603
6655
  moonbitlang$core$builtin$$Hash$hash_combine$7$(value, self);
6604
6656
  }
6605
- function moonbitlang$core$builtin$$Hasher$combine$13$(self, value) {
6606
- moonbitlang$core$builtin$$Hash$hash_combine$13$(value, self);
6657
+ function moonbitlang$core$builtin$$Hasher$combine$6$(self, value) {
6658
+ moonbitlang$core$builtin$$Hash$hash_combine$6$(value, self);
6659
+ }
6660
+ function moonbitlang$core$builtin$$Hasher$combine$12$(self, value) {
6661
+ moonbitlang$core$builtin$$Hash$hash_combine$12$(value, self);
6607
6662
  }
6608
6663
  function moonbitlang$core$builtin$$Hasher$combine$11$(self, value) {
6609
6664
  moonbitlang$core$builtin$$Hash$hash_combine$11$(value, self);
@@ -6615,14 +6670,14 @@ function moonbitlang$core$builtin$$Compare$op_lt$55$(x, y) {
6615
6670
  return moonbitlang$core$builtin$$Compare$compare$56$(x, y) < 0;
6616
6671
  }
6617
6672
  function moonbitlang$core$builtin$$Compare$op_lt$57$(x, y) {
6618
- return moonbitlang$core$builtin$$Compare$compare$7$(x, y) < 0;
6619
- }
6620
- function moonbitlang$core$builtin$$Compare$op_lt$28$(x, y) {
6621
- return moonbitlang$core$builtin$$Compare$compare$0$(x, y) < 0;
6673
+ return moonbitlang$core$builtin$$Compare$compare$6$(x, y) < 0;
6622
6674
  }
6623
6675
  function moonbitlang$core$builtin$$Compare$op_lt$27$(x, y) {
6624
6676
  return moonbitlang$core$builtin$$Compare$compare$22$(x, y) < 0;
6625
6677
  }
6678
+ function moonbitlang$core$builtin$$Compare$op_lt$28$(x, y) {
6679
+ return moonbitlang$core$builtin$$Compare$compare$0$(x, y) < 0;
6680
+ }
6626
6681
  function moonbitlang$core$builtin$$Compare$op_gt$55$(x, y) {
6627
6682
  return moonbitlang$core$builtin$$Compare$compare$56$(x, y) > 0;
6628
6683
  }
@@ -6635,12 +6690,12 @@ function moonbitlang$core$builtin$$Compare$op_gt$28$(x, y) {
6635
6690
  function moonbitlang$core$builtin$$Compare$op_gt$27$(x, y) {
6636
6691
  return moonbitlang$core$builtin$$Compare$compare$22$(x, y) > 0;
6637
6692
  }
6638
- function moonbitlang$core$builtin$$Compare$op_le$28$(x, y) {
6639
- return moonbitlang$core$builtin$$Compare$compare$0$(x, y) <= 0;
6640
- }
6641
6693
  function moonbitlang$core$builtin$$Compare$op_le$27$(x, y) {
6642
6694
  return moonbitlang$core$builtin$$Compare$compare$22$(x, y) <= 0;
6643
6695
  }
6696
+ function moonbitlang$core$builtin$$Compare$op_le$28$(x, y) {
6697
+ return moonbitlang$core$builtin$$Compare$compare$0$(x, y) <= 0;
6698
+ }
6644
6699
  function moonbitlang$core$builtin$$Compare$op_ge$54$(x, y) {
6645
6700
  return (x.physical_time < y.physical_time ? -1 : x.physical_time > y.physical_time ? 1 : $compare_int(x.logical_counter, y.logical_counter)) >= 0;
6646
6701
  }
@@ -6677,17 +6732,17 @@ function moonbitlang$core$builtin$$Hasher$new(seed$46$opt) {
6677
6732
  }
6678
6733
  function moonbitlang$core$builtin$$Hash$hash$59$(self) {
6679
6734
  const _self = moonbitlang$core$builtin$$Hasher$new(undefined);
6680
- moonbitlang$core$builtin$$Hasher$combine$8$(_self, self);
6735
+ moonbitlang$core$builtin$$Hasher$combine$7$(_self, self);
6681
6736
  return moonbitlang$core$builtin$$Hasher$finalize(_self);
6682
6737
  }
6683
6738
  function moonbitlang$core$builtin$$Hash$hash$57$(self) {
6684
6739
  const _self = moonbitlang$core$builtin$$Hasher$new(undefined);
6685
- moonbitlang$core$builtin$$Hasher$combine$7$(_self, self);
6740
+ moonbitlang$core$builtin$$Hasher$combine$6$(_self, self);
6686
6741
  return moonbitlang$core$builtin$$Hasher$finalize(_self);
6687
6742
  }
6688
6743
  function moonbitlang$core$builtin$$Hash$hash$19$(self) {
6689
6744
  const _self = moonbitlang$core$builtin$$Hasher$new(undefined);
6690
- moonbitlang$core$builtin$$Hasher$combine$13$(_self, self);
6745
+ moonbitlang$core$builtin$$Hasher$combine$12$(_self, self);
6691
6746
  return moonbitlang$core$builtin$$Hasher$finalize(_self);
6692
6747
  }
6693
6748
  function moonbitlang$core$builtin$$Show$to_string$60$(self) {
@@ -6697,7 +6752,7 @@ function moonbitlang$core$builtin$$Show$to_string$60$(self) {
6697
6752
  }
6698
6753
  function moonbitlang$core$builtin$$Show$to_string$19$(self) {
6699
6754
  const logger = moonbitlang$core$builtin$$StringBuilder$new$46$inner(0);
6700
- moonbitlang$core$builtin$$Show$output$13$(self, { self: logger, method_0: moonbitlang$core$builtin$$Logger$write_string$35$, method_1: moonbitlang$core$builtin$$Logger$write_substring$35$, method_2: moonbitlang$core$builtin$$Logger$write_char$35$ });
6755
+ moonbitlang$core$builtin$$Show$output$12$(self, { self: logger, method_0: moonbitlang$core$builtin$$Logger$write_string$35$, method_1: moonbitlang$core$builtin$$Logger$write_substring$35$, method_2: moonbitlang$core$builtin$$Logger$write_char$35$ });
6701
6756
  return logger.val;
6702
6757
  }
6703
6758
  function moonbitlang$core$builtin$$Show$to_string$61$(self) {
@@ -6744,7 +6799,7 @@ function moonbitlang$core$string$$StringView$at(self, index) {
6744
6799
  const _tmp$2 = self.start + index | 0;
6745
6800
  return _tmp.charCodeAt(_tmp$2);
6746
6801
  } else {
6747
- return moonbitlang$core$abort$$abort$13$("Index out of bounds");
6802
+ return moonbitlang$core$abort$$abort$12$("Index out of bounds");
6748
6803
  }
6749
6804
  }
6750
6805
  function moonbitlang$core$string$$StringView$view$46$inner(self, start_offset, end_offset) {
@@ -6755,7 +6810,7 @@ function moonbitlang$core$string$$StringView$view$46$inner(self, start_offset, e
6755
6810
  const _Some = end_offset;
6756
6811
  end_offset$2 = _Some;
6757
6812
  }
6758
- return start_offset >= 0 && (start_offset <= end_offset$2 && end_offset$2 <= (self.end - self.start | 0)) ? { str: self.str, start: self.start + start_offset | 0, end: self.start + end_offset$2 | 0 } : moonbitlang$core$abort$$abort$16$("Invalid index for View");
6813
+ return start_offset >= 0 && (start_offset <= end_offset$2 && end_offset$2 <= (self.end - self.start | 0)) ? { str: self.str, start: self.start + start_offset | 0, end: self.start + end_offset$2 | 0 } : moonbitlang$core$abort$$abort$15$("Invalid index for View");
6759
6814
  }
6760
6815
  function moonbitlang$core$builtin$$unsafe_sub_string(_tmp, _tmp$2, _tmp$3) {
6761
6816
  return $unsafe_bytes_sub_string(_tmp, _tmp$2, _tmp$3);
@@ -6803,7 +6858,7 @@ function moonbitlang$core$builtin$$output$46$flush_segment$124$2622(_env, seg, i
6803
6858
  return;
6804
6859
  }
6805
6860
  }
6806
- function moonbitlang$core$builtin$$Show$output$8$(self, logger) {
6861
+ function moonbitlang$core$builtin$$Show$output$7$(self, logger) {
6807
6862
  logger.method_2(logger.self, 34);
6808
6863
  const _env = { _0: self, _1: logger };
6809
6864
  const len = self.length;
@@ -6881,7 +6936,7 @@ function moonbitlang$core$builtin$$Show$output$8$(self, logger) {
6881
6936
  }
6882
6937
  logger.method_2(logger.self, 34);
6883
6938
  }
6884
- function moonbitlang$core$builtin$$Show$to_string$16$(self) {
6939
+ function moonbitlang$core$builtin$$Show$to_string$15$(self) {
6885
6940
  return self.str.substring(self.start, self.end);
6886
6941
  }
6887
6942
  function moonbitlang$core$string$$StringView$iter(self) {
@@ -6923,7 +6978,7 @@ function moonbitlang$core$string$$StringView$iter(self) {
6923
6978
  };
6924
6979
  return _p;
6925
6980
  }
6926
- function moonbitlang$core$builtin$$Eq$equal$16$(self, other) {
6981
+ function moonbitlang$core$builtin$$Eq$equal$15$(self, other) {
6927
6982
  const len = self.end - self.start | 0;
6928
6983
  if (len === (other.end - other.start | 0)) {
6929
6984
  if (self.str === other.str && self.start === other.start) {
@@ -6961,7 +7016,7 @@ function moonbitlang$core$string$$String$view$46$inner(self, start_offset, end_o
6961
7016
  const _Some = end_offset;
6962
7017
  end_offset$2 = _Some;
6963
7018
  }
6964
- return start_offset >= 0 && (start_offset <= end_offset$2 && end_offset$2 <= self.length) ? { str: self, start: start_offset, end: end_offset$2 } : moonbitlang$core$abort$$abort$16$("Invalid index for View");
7019
+ return start_offset >= 0 && (start_offset <= end_offset$2 && end_offset$2 <= self.length) ? { str: self, start: start_offset, end: end_offset$2 } : moonbitlang$core$abort$$abort$15$("Invalid index for View");
6965
7020
  }
6966
7021
  function moonbitlang$core$string$$String$char_length_eq$46$inner(self, len, start_offset, end_offset) {
6967
7022
  let end_offset$2;
@@ -6986,7 +7041,7 @@ function moonbitlang$core$string$$String$char_length_eq$46$inner(self, len, star
6986
7041
  _tmp$2 = count + 1 | 0;
6987
7042
  continue;
6988
7043
  } else {
6989
- moonbitlang$core$abort$$abort$4$("invalid surrogate pair");
7044
+ moonbitlang$core$abort$$abort$3$("invalid surrogate pair");
6990
7045
  }
6991
7046
  }
6992
7047
  _tmp = index + 1 | 0;
@@ -7020,7 +7075,7 @@ function moonbitlang$core$string$$String$char_length_ge$46$inner(self, len, star
7020
7075
  _tmp$2 = count + 1 | 0;
7021
7076
  continue;
7022
7077
  } else {
7023
- moonbitlang$core$abort$$abort$4$("invalid surrogate pair");
7078
+ moonbitlang$core$abort$$abort$3$("invalid surrogate pair");
7024
7079
  }
7025
7080
  }
7026
7081
  _tmp = index + 1 | 0;
@@ -7273,7 +7328,7 @@ function moonbitlang$core$array$$Array$new$46$inner$50$(capacity) {
7273
7328
  function moonbitlang$core$array$$Array$new$46$inner$52$(capacity) {
7274
7329
  return [];
7275
7330
  }
7276
- function moonbitlang$core$array$$Array$new$46$inner$12$(capacity) {
7331
+ function moonbitlang$core$array$$Array$new$46$inner$13$(capacity) {
7277
7332
  return [];
7278
7333
  }
7279
7334
  function moonbitlang$core$array$$Array$new$46$inner$62$(capacity) {
@@ -7285,22 +7340,22 @@ function moonbitlang$core$array$$Array$new$46$inner$40$(capacity) {
7285
7340
  function moonbitlang$core$array$$Array$push$14$(self, value) {
7286
7341
  moonbitlang$core$builtin$$JSArray$push(self, value);
7287
7342
  }
7288
- function moonbitlang$core$array$$Array$push$39$(self, value) {
7289
- moonbitlang$core$builtin$$JSArray$push(self, value);
7290
- }
7291
7343
  function moonbitlang$core$array$$Array$push$50$(self, value) {
7292
7344
  moonbitlang$core$builtin$$JSArray$push(self, value);
7293
7345
  }
7294
7346
  function moonbitlang$core$array$$Array$push$51$(self, value) {
7295
7347
  moonbitlang$core$builtin$$JSArray$push(self, value);
7296
7348
  }
7349
+ function moonbitlang$core$array$$Array$push$39$(self, value) {
7350
+ moonbitlang$core$builtin$$JSArray$push(self, value);
7351
+ }
7297
7352
  function moonbitlang$core$array$$Array$push$62$(self, value) {
7298
7353
  moonbitlang$core$builtin$$JSArray$push(self, value);
7299
7354
  }
7300
7355
  function moonbitlang$core$array$$Array$push$42$(self, value) {
7301
7356
  moonbitlang$core$builtin$$JSArray$push(self, value);
7302
7357
  }
7303
- function moonbitlang$core$array$$Array$push$12$(self, value) {
7358
+ function moonbitlang$core$array$$Array$push$13$(self, value) {
7304
7359
  moonbitlang$core$builtin$$JSArray$push(self, value);
7305
7360
  }
7306
7361
  function moonbitlang$core$array$$Array$push$52$(self, value) {
@@ -7309,13 +7364,13 @@ function moonbitlang$core$array$$Array$push$52$(self, value) {
7309
7364
  function moonbitlang$core$array$$Array$push$17$(self, value) {
7310
7365
  moonbitlang$core$builtin$$JSArray$push(self, value);
7311
7366
  }
7312
- function moonbitlang$core$array$$Array$push$16$(self, value) {
7367
+ function moonbitlang$core$array$$Array$push$15$(self, value) {
7313
7368
  moonbitlang$core$builtin$$JSArray$push(self, value);
7314
7369
  }
7315
7370
  function moonbitlang$core$array$$Array$push$40$(self, value) {
7316
7371
  moonbitlang$core$builtin$$JSArray$push(self, value);
7317
7372
  }
7318
- function moonbitlang$core$array$$Array$push$8$(self, value) {
7373
+ function moonbitlang$core$array$$Array$push$7$(self, value) {
7319
7374
  moonbitlang$core$builtin$$JSArray$push(self, value);
7320
7375
  }
7321
7376
  function moonbitlang$core$array$$Array$push$41$(self, value) {
@@ -7418,17 +7473,17 @@ function moonbitlang$core$builtin$$Iter$each$64$(self, f) {
7418
7473
  }
7419
7474
  }
7420
7475
  }
7421
- function moonbitlang$core$builtin$$Iter$collect$12$(self) {
7476
+ function moonbitlang$core$builtin$$Iter$collect$15$(self) {
7422
7477
  const result = [];
7423
7478
  moonbitlang$core$builtin$$Iter$each$63$(self, (e) => {
7424
- moonbitlang$core$array$$Array$push$12$(result, e);
7479
+ moonbitlang$core$array$$Array$push$15$(result, e);
7425
7480
  });
7426
7481
  return result;
7427
7482
  }
7428
- function moonbitlang$core$builtin$$Iter$collect$16$(self) {
7483
+ function moonbitlang$core$builtin$$Iter$collect$13$(self) {
7429
7484
  const result = [];
7430
7485
  moonbitlang$core$builtin$$Iter$each$64$(self, (e) => {
7431
- moonbitlang$core$array$$Array$push$16$(result, e);
7486
+ moonbitlang$core$array$$Array$push$13$(result, e);
7432
7487
  });
7433
7488
  return result;
7434
7489
  }
@@ -7486,11 +7541,11 @@ function moonbitlang$core$builtin$$Iterator$next$38$(self) {
7486
7541
  const _func = self;
7487
7542
  return _func();
7488
7543
  }
7489
- function moonbitlang$core$builtin$$Iterator$next$12$(self) {
7544
+ function moonbitlang$core$builtin$$Iterator$next$13$(self) {
7490
7545
  const _func = self;
7491
7546
  return _func();
7492
7547
  }
7493
- function moonbitlang$core$builtin$$Show$output$13$(self, logger) {
7548
+ function moonbitlang$core$builtin$$Show$output$12$(self, logger) {
7494
7549
  logger.method_0(logger.self, moonbitlang$core$int$$Int$to_string$46$inner(self, 10));
7495
7550
  }
7496
7551
  function moonbitlang$core$builtin$$Show$output$0$(self, logger) {
@@ -7504,7 +7559,7 @@ function moonbitlang$core$builtin$$Show$output$31$(self, logger) {
7504
7559
  const _Some = self;
7505
7560
  const _arg = _Some;
7506
7561
  logger.method_0(logger.self, "Some(");
7507
- moonbitlang$core$builtin$$Logger$write_object$8$(logger, _arg);
7562
+ moonbitlang$core$builtin$$Logger$write_object$7$(logger, _arg);
7508
7563
  logger.method_0(logger.self, ")");
7509
7564
  return;
7510
7565
  }
@@ -7578,7 +7633,7 @@ function moonbitlang$core$array$$FixedArray$from_array$53$(array) {
7578
7633
  return _p$3;
7579
7634
  }
7580
7635
  }
7581
- function moonbitlang$core$array$$FixedArray$sub$46$inner$12$(self, start, end) {
7636
+ function moonbitlang$core$array$$FixedArray$sub$46$inner$13$(self, start, end) {
7582
7637
  const len = self.length;
7583
7638
  let end$2;
7584
7639
  if (end === undefined) {
@@ -7589,7 +7644,7 @@ function moonbitlang$core$array$$FixedArray$sub$46$inner$12$(self, start, end) {
7589
7644
  end$2 = _end < 0 ? len + _end | 0 : _end;
7590
7645
  }
7591
7646
  const start$2 = start < 0 ? len + start | 0 : start;
7592
- return start$2 >= 0 && (start$2 <= end$2 && end$2 <= len) ? { buf: self, start: start$2, end: end$2 } : moonbitlang$core$abort$$abort$15$("View index out of bounds");
7647
+ return start$2 >= 0 && (start$2 <= end$2 && end$2 <= len) ? { buf: self, start: start$2, end: end$2 } : moonbitlang$core$abort$$abort$16$("View index out of bounds");
7593
7648
  }
7594
7649
  function moonbitlang$core$builtin$$Eq$equal$45$(self, other) {
7595
7650
  if (self === undefined) {
@@ -7708,7 +7763,7 @@ function moonbitlang$core$int$$Int$next_power_of_two(self) {
7708
7763
  return $panic();
7709
7764
  }
7710
7765
  }
7711
- function moonbitlang$core$builtin$$Map$new$46$inner$37$(capacity) {
7766
+ function moonbitlang$core$builtin$$Map$new$46$inner$71$(capacity) {
7712
7767
  const capacity$2 = moonbitlang$core$int$$Int$next_power_of_two(capacity);
7713
7768
  const _bind = capacity$2 - 1 | 0;
7714
7769
  const _bind$2 = (Math.imul(capacity$2, 13) | 0) / 16 | 0;
@@ -7716,7 +7771,7 @@ function moonbitlang$core$builtin$$Map$new$46$inner$37$(capacity) {
7716
7771
  const _bind$4 = undefined;
7717
7772
  return { entries: _bind$3, size: 0, capacity: capacity$2, capacity_mask: _bind, grow_at: _bind$2, head: _bind$4, tail: -1 };
7718
7773
  }
7719
- function moonbitlang$core$builtin$$Map$new$46$inner$71$(capacity) {
7774
+ function moonbitlang$core$builtin$$Map$new$46$inner$37$(capacity) {
7720
7775
  const capacity$2 = moonbitlang$core$int$$Int$next_power_of_two(capacity);
7721
7776
  const _bind = capacity$2 - 1 | 0;
7722
7777
  const _bind$2 = (Math.imul(capacity$2, 13) | 0) / 16 | 0;
@@ -8004,7 +8059,7 @@ function moonbitlang$core$builtin$$Map$set_with_hash$71$(self, key, value, hash)
8004
8059
  } else {
8005
8060
  const _Some = _bind$2;
8006
8061
  const _curr_entry = _Some;
8007
- if (_curr_entry.hash === hash && moonbitlang$core$builtin$$Eq$equal$7$(_curr_entry.key, key)) {
8062
+ if (_curr_entry.hash === hash && moonbitlang$core$builtin$$Eq$equal$6$(_curr_entry.key, key)) {
8008
8063
  _curr_entry.value = value;
8009
8064
  return undefined;
8010
8065
  }
@@ -8176,7 +8231,7 @@ function moonbitlang$core$builtin$$Map$get$71$(self, key) {
8176
8231
  } else {
8177
8232
  const _Some = _bind;
8178
8233
  const _entry = _Some;
8179
- if (_entry.hash === hash && moonbitlang$core$builtin$$Eq$equal$7$(_entry.key, key)) {
8234
+ if (_entry.hash === hash && moonbitlang$core$builtin$$Eq$equal$6$(_entry.key, key)) {
8180
8235
  return _entry.value;
8181
8236
  }
8182
8237
  if (i > _entry.psl) {
@@ -8353,7 +8408,7 @@ function moonbitlang$core$builtin$$Show$output$33$(self, logger) {
8353
8408
  if (_param_0 > 0) {
8354
8409
  logger.method_0(logger.self, ", ");
8355
8410
  }
8356
- moonbitlang$core$builtin$$Logger$write_object$8$(logger, _key);
8411
+ moonbitlang$core$builtin$$Logger$write_object$7$(logger, _key);
8357
8412
  logger.method_0(logger.self, ": ");
8358
8413
  moonbitlang$core$builtin$$Logger$write_object$14$(logger, _value);
8359
8414
  _tmp = _param_0 + 1 | 0;
@@ -8583,7 +8638,7 @@ function moonbitlang$core$builtin$$Eq$equal$14$(a, b) {
8583
8638
  }
8584
8639
  }
8585
8640
  }
8586
- function moonbitlang$core$builtin$$ToJson$to_json$13$(self) {
8641
+ function moonbitlang$core$builtin$$ToJson$to_json$12$(self) {
8587
8642
  const _p = self + 0;
8588
8643
  const _p$2 = undefined;
8589
8644
  return new $64$moonbitlang$47$core$47$builtin$46$Json$Number(_p, _p$2);
@@ -8967,10 +9022,10 @@ function moonbitlang$core$builtin$$Hasher$combine_string(self, value) {
8967
9022
  }
8968
9023
  }
8969
9024
  }
8970
- function moonbitlang$core$builtin$$Hash$hash_combine$8$(self, hasher) {
9025
+ function moonbitlang$core$builtin$$Hash$hash_combine$7$(self, hasher) {
8971
9026
  moonbitlang$core$builtin$$Hasher$combine_string(hasher, self);
8972
9027
  }
8973
- function moonbitlang$core$builtin$$Hash$hash_combine$13$(self, hasher) {
9028
+ function moonbitlang$core$builtin$$Hash$hash_combine$12$(self, hasher) {
8974
9029
  moonbitlang$core$builtin$$Hasher$combine_int(hasher, self);
8975
9030
  }
8976
9031
  function moonbitlang$core$builtin$$Hash$hash_combine$11$(self, hasher) {
@@ -9034,7 +9089,7 @@ function moonbitlang$core$bytes$$Bytes$makei$20$(length, value) {
9034
9089
  }
9035
9090
  return arr;
9036
9091
  }
9037
- function moonbitlang$core$builtin$$println$8$(input) {
9092
+ function moonbitlang$core$builtin$$println$7$(input) {
9038
9093
  console.log(input);
9039
9094
  }
9040
9095
  function moonbitlang$core$array$$FixedArray$blit_from_bytes(self, bytes_offset, src, src_offset, length) {
@@ -9043,7 +9098,7 @@ function moonbitlang$core$array$$FixedArray$blit_from_bytes(self, bytes_offset,
9043
9098
  const len1 = self.length;
9044
9099
  const len2 = src.length;
9045
9100
  if (length >= 0 && (bytes_offset >= 0 && (e1 < len1 && (src_offset >= 0 && e2 < len2)))) {
9046
- moonbitlang$core$array$$FixedArray$unsafe_blit$12$(self, bytes_offset, src, src_offset, length);
9101
+ moonbitlang$core$array$$FixedArray$unsafe_blit$13$(self, bytes_offset, src, src_offset, length);
9047
9102
  return;
9048
9103
  } else {
9049
9104
  $panic();
@@ -9083,11 +9138,11 @@ function moonbitlang$core$array$$FixedArray$set_utf16le_char(self, offset, value
9083
9138
  self[_tmp$3] = _p$4 & 255;
9084
9139
  return 4;
9085
9140
  } else {
9086
- return moonbitlang$core$abort$$abort$13$("Char out of range");
9141
+ return moonbitlang$core$abort$$abort$12$("Char out of range");
9087
9142
  }
9088
9143
  }
9089
9144
  }
9090
- function moonbitlang$core$builtin$$Eq$equal$3$(self, other) {
9145
+ function moonbitlang$core$builtin$$Eq$equal$2$(self, other) {
9091
9146
  if (self.length !== other.length) {
9092
9147
  return false;
9093
9148
  } else {
@@ -9110,17 +9165,17 @@ function moonbitlang$core$builtin$$Eq$equal$3$(self, other) {
9110
9165
  }
9111
9166
  }
9112
9167
  }
9113
- function moonbitlang$core$builtin$$Shr$shr$12$(self, count) {
9168
+ function moonbitlang$core$builtin$$Shr$shr$13$(self, count) {
9114
9169
  return (self >>> count | 0) & 255;
9115
9170
  }
9116
- function moonbitlang$core$array$$ArrayView$at$12$(self, index) {
9171
+ function moonbitlang$core$array$$ArrayView$at$13$(self, index) {
9117
9172
  if (index >= 0 && index < (self.end - self.start | 0)) {
9118
9173
  const _tmp = self.buf;
9119
9174
  const _tmp$2 = self.start + index | 0;
9120
9175
  $bound_check(_tmp, _tmp$2);
9121
9176
  return _tmp[_tmp$2];
9122
9177
  } else {
9123
- return moonbitlang$core$abort$$abort$12$(`index out of bounds: the len is from 0 to ${moonbitlang$core$builtin$$Show$to_string$19$(self.end - self.start | 0)} but the index is ${moonbitlang$core$builtin$$Show$to_string$19$(index)}`);
9178
+ return moonbitlang$core$abort$$abort$13$(`index out of bounds: the len is from 0 to ${moonbitlang$core$builtin$$Show$to_string$19$(self.end - self.start | 0)} but the index is ${moonbitlang$core$builtin$$Show$to_string$19$(index)}`);
9124
9179
  }
9125
9180
  }
9126
9181
  function moonbitlang$core$array$$Array$unsafe_pop$39$(self) {
@@ -9139,11 +9194,11 @@ function moonbitlang$core$array$$Array$insert$42$(self, index, value) {
9139
9194
  moonbitlang$core$builtin$$JSArray$splice1(self, index, 0, value);
9140
9195
  return;
9141
9196
  } else {
9142
- moonbitlang$core$abort$$abort$4$(`index out of bounds: the len is from 0 to ${moonbitlang$core$builtin$$Show$to_string$19$(self.length)} but the index is ${moonbitlang$core$builtin$$Show$to_string$19$(index)}`);
9197
+ moonbitlang$core$abort$$abort$3$(`index out of bounds: the len is from 0 to ${moonbitlang$core$builtin$$Show$to_string$19$(self.length)} but the index is ${moonbitlang$core$builtin$$Show$to_string$19$(index)}`);
9143
9198
  return;
9144
9199
  }
9145
9200
  }
9146
- function moonbitlang$core$array$$Array$set$12$(self, index, value) {
9201
+ function moonbitlang$core$array$$Array$set$13$(self, index, value) {
9147
9202
  const len = self.length;
9148
9203
  if (index >= 0 && index < len) {
9149
9204
  $bound_check(self, index);
@@ -9187,7 +9242,7 @@ function moonbitlang$core$builtin$$Eq$equal$32$(self, other) {
9187
9242
  return false;
9188
9243
  }
9189
9244
  }
9190
- function moonbitlang$core$array$$Array$rev$12$(self) {
9245
+ function moonbitlang$core$array$$Array$rev$13$(self) {
9191
9246
  const len = self.length;
9192
9247
  const arr = new Array(len);
9193
9248
  let _tmp = 0;
@@ -9619,7 +9674,7 @@ function zxch3n$flock$leb128$$encode_uint64(value) {
9619
9674
  const _p$2 = 128;
9620
9675
  byte = (_p | _p$2) & 255;
9621
9676
  }
9622
- moonbitlang$core$array$$Array$push$12$(result, byte);
9677
+ moonbitlang$core$array$$Array$push$13$(result, byte);
9623
9678
  if (moonbitlang$core$builtin$$Eq$equal$0$(val, $0L)) {
9624
9679
  break;
9625
9680
  }
@@ -9664,7 +9719,7 @@ function zxch3n$flock$leb128$$encode_int64(value) {
9664
9719
  byte = (_p | _p$2) & 255;
9665
9720
  }
9666
9721
  }
9667
- moonbitlang$core$array$$Array$push$12$(result, byte);
9722
+ moonbitlang$core$array$$Array$push$13$(result, byte);
9668
9723
  continue;
9669
9724
  } else {
9670
9725
  break;
@@ -9741,14 +9796,14 @@ function zxch3n$expect$$Formated$to_string(self) {
9741
9796
  } else {
9742
9797
  const _Some = _bind;
9743
9798
  const _color = _Some;
9744
- moonbitlang$core$array$$Array$push$8$(styles, zxch3n$expect$$Color$to_color_code(_color));
9799
+ moonbitlang$core$array$$Array$push$7$(styles, zxch3n$expect$$Color$to_color_code(_color));
9745
9800
  }
9746
9801
  const _bind$2 = self.bg_color;
9747
9802
  if (_bind$2 === undefined) {
9748
9803
  } else {
9749
9804
  const _Some = _bind$2;
9750
9805
  const _bg_color = _Some;
9751
- moonbitlang$core$array$$Array$push$8$(styles, zxch3n$expect$$Color$to_bg_color_code(_bg_color));
9806
+ moonbitlang$core$array$$Array$push$7$(styles, zxch3n$expect$$Color$to_bg_color_code(_bg_color));
9752
9807
  }
9753
9808
  const _arr = self.formats;
9754
9809
  const _len = _arr.length;
@@ -9759,31 +9814,31 @@ function zxch3n$expect$$Formated$to_string(self) {
9759
9814
  const format = _arr[_i];
9760
9815
  switch (format) {
9761
9816
  case 0: {
9762
- moonbitlang$core$array$$Array$push$8$(styles, "1");
9817
+ moonbitlang$core$array$$Array$push$7$(styles, "1");
9763
9818
  break;
9764
9819
  }
9765
9820
  case 1: {
9766
- moonbitlang$core$array$$Array$push$8$(styles, "4");
9821
+ moonbitlang$core$array$$Array$push$7$(styles, "4");
9767
9822
  break;
9768
9823
  }
9769
9824
  case 2: {
9770
- moonbitlang$core$array$$Array$push$8$(styles, "5");
9825
+ moonbitlang$core$array$$Array$push$7$(styles, "5");
9771
9826
  break;
9772
9827
  }
9773
9828
  case 3: {
9774
- moonbitlang$core$array$$Array$push$8$(styles, "7");
9829
+ moonbitlang$core$array$$Array$push$7$(styles, "7");
9775
9830
  break;
9776
9831
  }
9777
9832
  case 4: {
9778
- moonbitlang$core$array$$Array$push$8$(styles, "8");
9833
+ moonbitlang$core$array$$Array$push$7$(styles, "8");
9779
9834
  break;
9780
9835
  }
9781
9836
  case 5: {
9782
- moonbitlang$core$array$$Array$push$8$(styles, "9");
9837
+ moonbitlang$core$array$$Array$push$7$(styles, "9");
9783
9838
  break;
9784
9839
  }
9785
9840
  default: {
9786
- moonbitlang$core$array$$Array$push$8$(styles, "3");
9841
+ moonbitlang$core$array$$Array$push$7$(styles, "3");
9787
9842
  }
9788
9843
  }
9789
9844
  _tmp = _i + 1 | 0;
@@ -9793,7 +9848,7 @@ function zxch3n$expect$$Formated$to_string(self) {
9793
9848
  }
9794
9849
  }
9795
9850
  if (styles.length > 0) {
9796
- const style_string = moonbitlang$core$array$$Array$join$8$(styles, { str: zxch3n$expect$$to_string$46$42$bind$124$178, start: 0, end: zxch3n$expect$$to_string$46$42$bind$124$178.length });
9851
+ const style_string = moonbitlang$core$array$$Array$join$7$(styles, { str: zxch3n$expect$$to_string$46$42$bind$124$178, start: 0, end: zxch3n$expect$$to_string$46$42$bind$124$178.length });
9797
9852
  return `[${style_string}m${self.str}[0m`;
9798
9853
  } else {
9799
9854
  return self.str;
@@ -9820,19 +9875,19 @@ function zxch3n$expect$$Formated$bold(self) {
9820
9875
  moonbitlang$core$array$$Array$push_iter$41$(_self, moonbitlang$core$array$$Array$iter$41$(self.formats));
9821
9876
  return { str: _tmp, bg_color: _tmp$2, color: _tmp$3, formats: _self };
9822
9877
  }
9823
- function zxch3n$expect$$panic$46$inner$4$(reason, loc) {
9878
+ function zxch3n$expect$$panic$46$inner$3$(reason, loc) {
9824
9879
  const msg = `${zxch3n$expect$$Formated$to_string(zxch3n$expect$$Formated$red(zxch3n$expect$$Formated$bold(zxch3n$expect$$Formated$format("Panic: "))))}${zxch3n$expect$$Formated$to_string(zxch3n$expect$$Formated$yellow(zxch3n$expect$$Formated$format(reason)))} at ${zxch3n$expect$$Formated$to_string(zxch3n$expect$$Formated$blue(zxch3n$expect$$Formated$format(loc)))}`;
9825
- moonbitlang$core$builtin$$println$8$(msg);
9826
- moonbitlang$core$abort$$abort$4$(msg);
9880
+ moonbitlang$core$builtin$$println$7$(msg);
9881
+ moonbitlang$core$abort$$abort$3$(msg);
9827
9882
  }
9828
- function moonbitlang$core$builtin$$Eq$equal$7$(_x_165, _x_166) {
9829
- return moonbitlang$core$builtin$$Eq$equal$3$(_x_165, _x_166);
9883
+ function moonbitlang$core$builtin$$Eq$equal$6$(_x_165, _x_166) {
9884
+ return moonbitlang$core$builtin$$Eq$equal$2$(_x_165, _x_166);
9830
9885
  }
9831
- function moonbitlang$core$builtin$$Hash$hash_combine$7$(_x_157, _x_158) {
9832
- moonbitlang$core$builtin$$Hash$hash_combine$3$(_x_157, _x_158);
9886
+ function moonbitlang$core$builtin$$Hash$hash_combine$6$(_x_157, _x_158) {
9887
+ moonbitlang$core$builtin$$Hash$hash_combine$2$(_x_157, _x_158);
9833
9888
  }
9834
9889
  function zxch3n$flock$types$$string_to_utf8(str) {
9835
- const bytes = moonbitlang$core$array$$Array$new$46$inner$12$(0);
9890
+ const bytes = moonbitlang$core$array$$Array$new$46$inner$13$(0);
9836
9891
  let i = 0;
9837
9892
  while (true) {
9838
9893
  if (i < str.length) {
@@ -9845,27 +9900,27 @@ function zxch3n$flock$types$$string_to_utf8(str) {
9845
9900
  const low = str.charCodeAt(_tmp$2);
9846
9901
  if (low >= 56320 && low <= 57343) {
9847
9902
  const code_point = (65536 + (code - 55296 << 10) | 0) + (low - 56320 | 0) | 0;
9848
- moonbitlang$core$array$$Array$push$12$(bytes, (240 | code_point >> 18) & 255);
9849
- moonbitlang$core$array$$Array$push$12$(bytes, (128 | code_point >> 12 & 63) & 255);
9850
- moonbitlang$core$array$$Array$push$12$(bytes, (128 | code_point >> 6 & 63) & 255);
9851
- moonbitlang$core$array$$Array$push$12$(bytes, (128 | code_point & 63) & 255);
9903
+ moonbitlang$core$array$$Array$push$13$(bytes, (240 | code_point >> 18) & 255);
9904
+ moonbitlang$core$array$$Array$push$13$(bytes, (128 | code_point >> 12 & 63) & 255);
9905
+ moonbitlang$core$array$$Array$push$13$(bytes, (128 | code_point >> 6 & 63) & 255);
9906
+ moonbitlang$core$array$$Array$push$13$(bytes, (128 | code_point & 63) & 255);
9852
9907
  i = i + 1 | 0;
9853
9908
  } else {
9854
- moonbitlang$core$array$$Array$push$12$(bytes, (224 | code >> 12) & 255);
9855
- moonbitlang$core$array$$Array$push$12$(bytes, (128 | code >> 6 & 63) & 255);
9856
- moonbitlang$core$array$$Array$push$12$(bytes, (128 | code & 63) & 255);
9909
+ moonbitlang$core$array$$Array$push$13$(bytes, (224 | code >> 12) & 255);
9910
+ moonbitlang$core$array$$Array$push$13$(bytes, (128 | code >> 6 & 63) & 255);
9911
+ moonbitlang$core$array$$Array$push$13$(bytes, (128 | code & 63) & 255);
9857
9912
  }
9858
9913
  } else {
9859
9914
  if (code < 128) {
9860
- moonbitlang$core$array$$Array$push$12$(bytes, code & 255);
9915
+ moonbitlang$core$array$$Array$push$13$(bytes, code & 255);
9861
9916
  } else {
9862
9917
  if (code < 2048) {
9863
- moonbitlang$core$array$$Array$push$12$(bytes, (192 | code >> 6) & 255);
9864
- moonbitlang$core$array$$Array$push$12$(bytes, (128 | code & 63) & 255);
9918
+ moonbitlang$core$array$$Array$push$13$(bytes, (192 | code >> 6) & 255);
9919
+ moonbitlang$core$array$$Array$push$13$(bytes, (128 | code & 63) & 255);
9865
9920
  } else {
9866
- moonbitlang$core$array$$Array$push$12$(bytes, (224 | code >> 12) & 255);
9867
- moonbitlang$core$array$$Array$push$12$(bytes, (128 | code >> 6 & 63) & 255);
9868
- moonbitlang$core$array$$Array$push$12$(bytes, (128 | code & 63) & 255);
9921
+ moonbitlang$core$array$$Array$push$13$(bytes, (224 | code >> 12) & 255);
9922
+ moonbitlang$core$array$$Array$push$13$(bytes, (128 | code >> 6 & 63) & 255);
9923
+ moonbitlang$core$array$$Array$push$13$(bytes, (128 | code & 63) & 255);
9869
9924
  }
9870
9925
  }
9871
9926
  }
@@ -10131,7 +10186,7 @@ function zxch3n$flock$types$$compare_bytes(b1, b2) {
10131
10186
  }
10132
10187
  return $compare_int(n1, n2);
10133
10188
  }
10134
- function moonbitlang$core$builtin$$Compare$compare$7$(self, other) {
10189
+ function moonbitlang$core$builtin$$Compare$compare$6$(self, other) {
10135
10190
  const _bind = self;
10136
10191
  const _tmp = moonbitlang$core$bytes$$Bytes$sub$46$inner(_bind, 0, _bind.length);
10137
10192
  const _bind$2 = other;
@@ -10144,20 +10199,20 @@ function zxch3n$flock$memcomparable$$double_from_bits(bits) {
10144
10199
  return moonbitlang$core$uint64$$UInt64$reinterpret_as_double(bits);
10145
10200
  }
10146
10201
  function zxch3n$flock$memcomparable$$uint64_to_be_bytes(n) {
10147
- const bytes = moonbitlang$core$array$$Array$new$46$inner$12$(0);
10148
- moonbitlang$core$array$$Array$push$12$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 56), $255L)));
10149
- moonbitlang$core$array$$Array$push$12$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 48), $255L)));
10150
- moonbitlang$core$array$$Array$push$12$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 40), $255L)));
10151
- moonbitlang$core$array$$Array$push$12$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 32), $255L)));
10152
- moonbitlang$core$array$$Array$push$12$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 24), $255L)));
10153
- moonbitlang$core$array$$Array$push$12$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 16), $255L)));
10154
- moonbitlang$core$array$$Array$push$12$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 8), $255L)));
10155
- moonbitlang$core$array$$Array$push$12$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(n, $255L)));
10202
+ const bytes = moonbitlang$core$array$$Array$new$46$inner$13$(0);
10203
+ moonbitlang$core$array$$Array$push$13$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 56), $255L)));
10204
+ moonbitlang$core$array$$Array$push$13$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 48), $255L)));
10205
+ moonbitlang$core$array$$Array$push$13$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 40), $255L)));
10206
+ moonbitlang$core$array$$Array$push$13$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 32), $255L)));
10207
+ moonbitlang$core$array$$Array$push$13$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 24), $255L)));
10208
+ moonbitlang$core$array$$Array$push$13$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 16), $255L)));
10209
+ moonbitlang$core$array$$Array$push$13$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(moonbitlang$core$builtin$$Shr$shr$0$(n, 8), $255L)));
10210
+ moonbitlang$core$array$$Array$push$13$(bytes, moonbitlang$core$uint64$$UInt64$to_byte(moonbitlang$core$builtin$$BitAnd$land$0$(n, $255L)));
10156
10211
  return moonbitlang$core$bytes$$Bytes$from_array({ buf: bytes, start: 0, end: bytes.length });
10157
10212
  }
10158
10213
  function zxch3n$flock$memcomparable$$uint64_from_be_bytes(bytes) {
10159
10214
  if (bytes.length !== 8) {
10160
- zxch3n$expect$$panic$46$inner$4$("Invalid byte array length", "/home/runner/work/flock/flock/moon/memcomparable/utils.mbt:28:5-28:54");
10215
+ zxch3n$expect$$panic$46$inner$3$("Invalid byte array length", "/home/runner/work/flock/flock/moon/memcomparable/utils.mbt:28:5-28:54");
10161
10216
  }
10162
10217
  let result = $0L;
10163
10218
  const _tmp = result;
@@ -10221,7 +10276,7 @@ function zxch3n$flock$memcomparable$$encode_bytes(bytes, output) {
10221
10276
  moonbitlang$core$buffer$$Buffer$write_byte(output, 1);
10222
10277
  const _it = moonbitlang$core$bytes$$BytesView$iterator(bytes);
10223
10278
  while (true) {
10224
- const _bind = moonbitlang$core$builtin$$Iterator$next$12$(_it);
10279
+ const _bind = moonbitlang$core$builtin$$Iterator$next$13$(_it);
10225
10280
  if (_bind === -1) {
10226
10281
  break;
10227
10282
  } else {
@@ -10284,14 +10339,14 @@ function zxch3n$flock$memcomparable$$biguint_to_be_bytes(n) {
10284
10339
  while (true) {
10285
10340
  if (moonbitlang$core$builtin$$Compare$op_gt$58$(x, 0n)) {
10286
10341
  const byte = moonbitlang$core$bigint$$BigInt$to_int(moonbitlang$core$builtin$$Mod$mod$21$(x, 256n));
10287
- moonbitlang$core$array$$Array$push$12$(bytes, byte & 255);
10342
+ moonbitlang$core$array$$Array$push$13$(bytes, byte & 255);
10288
10343
  x = moonbitlang$core$builtin$$Div$div$21$(x, 256n);
10289
10344
  continue;
10290
10345
  } else {
10291
10346
  break;
10292
10347
  }
10293
10348
  }
10294
- const _bind = moonbitlang$core$array$$Array$rev$12$(bytes);
10349
+ const _bind = moonbitlang$core$array$$Array$rev$13$(bytes);
10295
10350
  return moonbitlang$core$bytes$$Bytes$from_array({ buf: _bind, start: 0, end: _bind.length });
10296
10351
  }
10297
10352
  function zxch3n$flock$memcomparable$$bigint_to_be_bytes(n, output) {
@@ -10310,7 +10365,7 @@ function zxch3n$flock$memcomparable$$bigint_to_be_bytes(n, output) {
10310
10365
  } else {
10311
10366
  moonbitlang$core$buffer$$Buffer$write_byte(output, 11);
10312
10367
  if (n$2 > 255) {
10313
- moonbitlang$core$abort$$abort$4$("n is too large");
10368
+ moonbitlang$core$abort$$abort$3$("n is too large");
10314
10369
  }
10315
10370
  const _p = n$2 & 255;
10316
10371
  const _p$2 = 255;
@@ -10341,7 +10396,7 @@ function zxch3n$flock$memcomparable$$bigint_to_be_bytes(n, output) {
10341
10396
  } else {
10342
10397
  moonbitlang$core$buffer$$Buffer$write_byte(output, 29);
10343
10398
  if (n$2 > 255) {
10344
- moonbitlang$core$abort$$abort$4$("n is too large");
10399
+ moonbitlang$core$abort$$abort$3$("n is too large");
10345
10400
  }
10346
10401
  moonbitlang$core$buffer$$Buffer$write_byte(output, n$2 & 255);
10347
10402
  }
@@ -10562,12 +10617,12 @@ function zxch3n$flock$memcomparable$$decode_float(bytes, start) {
10562
10617
  if ((start + 8 | 0) > (bytes.end - bytes.start | 0)) {
10563
10618
  return new Result$Err$27$(Error$zxch3n$47$flock$47$memcomparable$46$KeyError$46$UnexpectedEOF);
10564
10619
  }
10565
- const data = moonbitlang$core$array$$Array$new$46$inner$12$(0);
10620
+ const data = moonbitlang$core$array$$Array$new$46$inner$13$(0);
10566
10621
  let _tmp = 0;
10567
10622
  while (true) {
10568
10623
  const i = _tmp;
10569
10624
  if (i < 8) {
10570
- moonbitlang$core$array$$Array$push$12$(data, moonbitlang$core$bytes$$BytesView$at(bytes, start + i | 0));
10625
+ moonbitlang$core$array$$Array$push$13$(data, moonbitlang$core$bytes$$BytesView$at(bytes, start + i | 0));
10571
10626
  _tmp = i + 1 | 0;
10572
10627
  continue;
10573
10628
  } else {
@@ -10771,7 +10826,7 @@ function zxch3n$flock$memcomparable$$decode_key_to_json(bytes) {
10771
10826
  }
10772
10827
  break _L;
10773
10828
  }
10774
- key = moonbitlang$core$abort$$abort$2$("Failed to decode key");
10829
+ key = moonbitlang$core$abort$$abort$10$("Failed to decode key");
10775
10830
  }
10776
10831
  const parts = moonbitlang$core$array$$Array$new$46$inner$14$(0);
10777
10832
  const _arr = key.parts;
@@ -11126,7 +11181,7 @@ function zxch3n$flock$sorted_map$$add_node$80$(root, key, value) {
11126
11181
  } else {
11127
11182
  const _Some = root;
11128
11183
  const _n = _Some;
11129
- if (moonbitlang$core$builtin$$Eq$equal$7$(key, _n.key)) {
11184
+ if (moonbitlang$core$builtin$$Eq$equal$6$(key, _n.key)) {
11130
11185
  _n.value = value;
11131
11186
  return { _0: _n, _1: false };
11132
11187
  } else {
@@ -11154,7 +11209,7 @@ function zxch3n$flock$sorted_map$$add_node$74$(root, key, value) {
11154
11209
  } else {
11155
11210
  const _Some = root;
11156
11211
  const _n = _Some;
11157
- if (moonbitlang$core$builtin$$Eq$equal$7$(key, _n.key)) {
11212
+ if (moonbitlang$core$builtin$$Eq$equal$6$(key, _n.key)) {
11158
11213
  _n.value = value;
11159
11214
  return { _0: _n, _1: false };
11160
11215
  } else {
@@ -11213,7 +11268,7 @@ function zxch3n$flock$sorted_map$$SortedMap$get$80$(self, key) {
11213
11268
  } else {
11214
11269
  const _Some = _param;
11215
11270
  const _node = _Some;
11216
- const cmp = moonbitlang$core$builtin$$Compare$compare$7$(key, _node.key);
11271
+ const cmp = moonbitlang$core$builtin$$Compare$compare$6$(key, _node.key);
11217
11272
  if (cmp === 0) {
11218
11273
  return new Option$Some$31$(_node.value);
11219
11274
  } else {
@@ -11237,7 +11292,7 @@ function zxch3n$flock$sorted_map$$SortedMap$get$74$(self, key) {
11237
11292
  } else {
11238
11293
  const _Some = _param;
11239
11294
  const _node = _Some;
11240
- const cmp = moonbitlang$core$builtin$$Compare$compare$7$(key, _node.key);
11295
+ const cmp = moonbitlang$core$builtin$$Compare$compare$6$(key, _node.key);
11241
11296
  if (cmp === 0) {
11242
11297
  return _node.value;
11243
11298
  } else {
@@ -11263,7 +11318,7 @@ function zxch3n$flock$sorted_map$$SortedMap$entry$74$(self, key) {
11263
11318
  } else {
11264
11319
  const _Some = _param;
11265
11320
  const _node = _Some;
11266
- const cmp = moonbitlang$core$builtin$$Compare$compare$7$(key, _node.key);
11321
+ const cmp = moonbitlang$core$builtin$$Compare$compare$6$(key, _node.key);
11267
11322
  if (cmp === 0) {
11268
11323
  return { _0: _node.value, _1: (v) => {
11269
11324
  _node.value = v;
@@ -11289,7 +11344,7 @@ function zxch3n$flock$sorted_map$$SortedMap$at$80$(self, key) {
11289
11344
  } else {
11290
11345
  const _Some = _param;
11291
11346
  const _node = _Some;
11292
- const cmp = moonbitlang$core$builtin$$Compare$compare$7$(key, _node.key);
11347
+ const cmp = moonbitlang$core$builtin$$Compare$compare$6$(key, _node.key);
11293
11348
  if (cmp === 0) {
11294
11349
  return _node.value;
11295
11350
  } else {
@@ -11371,14 +11426,14 @@ function zxch3n$flock$sorted_map$$range$46$go$47$2970(_env, x) {
11371
11426
  case 0: {
11372
11427
  const _Inclusive = low;
11373
11428
  const _lo = _Inclusive._0;
11374
- const cmp = moonbitlang$core$builtin$$Compare$compare$7$(_key, _lo);
11429
+ const cmp = moonbitlang$core$builtin$$Compare$compare$6$(_key, _lo);
11375
11430
  _bind = { _0: cmp > 0, _1: cmp >= 0 };
11376
11431
  break;
11377
11432
  }
11378
11433
  default: {
11379
11434
  const _Exclusive = low;
11380
11435
  const _lo$2 = _Exclusive._0;
11381
- const cmp$2 = moonbitlang$core$builtin$$Compare$compare$7$(_key, _lo$2);
11436
+ const cmp$2 = moonbitlang$core$builtin$$Compare$compare$6$(_key, _lo$2);
11382
11437
  _bind = { _0: cmp$2 > 0, _1: cmp$2 > 0 };
11383
11438
  }
11384
11439
  }
@@ -11393,14 +11448,14 @@ function zxch3n$flock$sorted_map$$range$46$go$47$2970(_env, x) {
11393
11448
  case 0: {
11394
11449
  const _Inclusive$2 = high;
11395
11450
  const _hi = _Inclusive$2._0;
11396
- const cmp$3 = moonbitlang$core$builtin$$Compare$compare$7$(_key, _hi);
11451
+ const cmp$3 = moonbitlang$core$builtin$$Compare$compare$6$(_key, _hi);
11397
11452
  _bind$2 = { _0: cmp$3 < 0, _1: cmp$3 <= 0 };
11398
11453
  break;
11399
11454
  }
11400
11455
  default: {
11401
11456
  const _Exclusive$2 = high;
11402
11457
  const _hi$2 = _Exclusive$2._0;
11403
- const cmp$4 = moonbitlang$core$builtin$$Compare$compare$7$(_key, _hi$2);
11458
+ const cmp$4 = moonbitlang$core$builtin$$Compare$compare$6$(_key, _hi$2);
11404
11459
  _bind$2 = { _0: cmp$4 < 0, _1: cmp$4 < 0 };
11405
11460
  }
11406
11461
  }
@@ -11451,10 +11506,10 @@ function zxch3n$flock$sorted_map$$SortedMap$range$74$(self, low, high) {
11451
11506
  return _p;
11452
11507
  }
11453
11508
  function moonbitlang$core$builtin$$Eq$equal$66$(self, other) {
11454
- return moonbitlang$core$builtin$$Eq$equal$7$(self.key, other.key);
11509
+ return moonbitlang$core$builtin$$Eq$equal$6$(self.key, other.key);
11455
11510
  }
11456
11511
  function moonbitlang$core$builtin$$Eq$equal$67$(self, other) {
11457
- return moonbitlang$core$builtin$$Eq$equal$7$(self.key, other.key);
11512
+ return moonbitlang$core$builtin$$Eq$equal$6$(self.key, other.key);
11458
11513
  }
11459
11514
  function zxch3n$flock$flock$$SubscriberSet$new$81$() {
11460
11515
  return { seq: 0, subscribers: moonbitlang$core$builtin$$Map$new$46$inner$72$(8) };
@@ -11498,7 +11553,7 @@ function zxch3n$flock$flock$$bytes_to_hex(bytes) {
11498
11553
  if (i < bytes.length) {
11499
11554
  $bound_check(bytes, i);
11500
11555
  const byte = bytes[i];
11501
- const _p = moonbitlang$core$builtin$$Shr$shr$12$(byte, 4);
11556
+ const _p = moonbitlang$core$builtin$$Shr$shr$13$(byte, 4);
11502
11557
  const _p$2 = 15;
11503
11558
  const hi = _p & _p$2 & 255;
11504
11559
  const _p$3 = 15;
@@ -11517,7 +11572,7 @@ function zxch3n$flock$flock$$bytes_to_hex(bytes) {
11517
11572
  }
11518
11573
  function zxch3n$flock$flock$$bytes_from_hex(hex) {
11519
11574
  if (((hex.end - hex.start | 0) % 2 | 0) !== 0) {
11520
- moonbitlang$core$builtin$$println$8$(`Invalid hex length: ${moonbitlang$core$builtin$$Show$to_string$19$(hex.end - hex.start | 0)}`);
11575
+ moonbitlang$core$builtin$$println$7$(`Invalid hex length: ${moonbitlang$core$builtin$$Show$to_string$19$(hex.end - hex.start | 0)}`);
11521
11576
  return undefined;
11522
11577
  }
11523
11578
  const bytes = [];
@@ -11537,7 +11592,7 @@ function zxch3n$flock$flock$$bytes_from_hex(hex) {
11537
11592
  if (first >= 65 && first <= 70) {
11538
11593
  value = value + (Math.imul((first - 65 | 0) + 10 | 0, 16) | 0) | 0;
11539
11594
  } else {
11540
- moonbitlang$core$builtin$$println$8$(`Invalid hex character: ${moonbitlang$core$builtin$$Show$to_string$19$(first)}`);
11595
+ moonbitlang$core$builtin$$println$7$(`Invalid hex character: ${moonbitlang$core$builtin$$Show$to_string$19$(first)}`);
11541
11596
  return undefined;
11542
11597
  }
11543
11598
  }
@@ -11551,12 +11606,12 @@ function zxch3n$flock$flock$$bytes_from_hex(hex) {
11551
11606
  if (second >= 65 && second <= 70) {
11552
11607
  value = value + ((second - 65 | 0) + 10 | 0) | 0;
11553
11608
  } else {
11554
- moonbitlang$core$builtin$$println$8$(`Invalid hex character: ${moonbitlang$core$builtin$$Show$to_string$19$(second)}`);
11609
+ moonbitlang$core$builtin$$println$7$(`Invalid hex character: ${moonbitlang$core$builtin$$Show$to_string$19$(second)}`);
11555
11610
  return undefined;
11556
11611
  }
11557
11612
  }
11558
11613
  }
11559
- moonbitlang$core$array$$Array$push$12$(bytes, value & 255);
11614
+ moonbitlang$core$array$$Array$push$13$(bytes, value & 255);
11560
11615
  _tmp = i + 2 | 0;
11561
11616
  continue;
11562
11617
  } else {
@@ -11572,7 +11627,7 @@ function moonbitlang$core$builtin$$Compare$compare$56$(a, b) {
11572
11627
  if (ans !== 0) {
11573
11628
  return ans;
11574
11629
  }
11575
- return moonbitlang$core$builtin$$Compare$compare$7$(a.peer, b.peer);
11630
+ return moonbitlang$core$builtin$$Compare$compare$6$(a.peer, b.peer);
11576
11631
  }
11577
11632
  function zxch3n$flock$flock$$Hlc$to_string(self) {
11578
11633
  return `${moonbitlang$core$builtin$$Show$to_string$61$(self.physical_time)},${moonbitlang$core$builtin$$Show$to_string$19$(self.logical_counter)}`;
@@ -11581,7 +11636,7 @@ function zxch3n$flock$flock$$HlcWithPeer$to_string(self) {
11581
11636
  return `${zxch3n$flock$flock$$Hlc$to_string(self.hlc)},${zxch3n$flock$flock$$bytes_to_hex(self.peer)}`;
11582
11637
  }
11583
11638
  function zxch3n$flock$flock$$HlcWithPeer$from_string(s) {
11584
- const _bind = moonbitlang$core$builtin$$Iter$collect$16$(moonbitlang$core$string$$StringView$split(s, { str: zxch3n$flock$flock$$from_string$46$42$bind$124$593, start: 0, end: zxch3n$flock$flock$$from_string$46$42$bind$124$593.length }));
11639
+ const _bind = moonbitlang$core$builtin$$Iter$collect$15$(moonbitlang$core$string$$StringView$split(s, { str: zxch3n$flock$flock$$from_string$46$42$bind$124$598, start: 0, end: zxch3n$flock$flock$$from_string$46$42$bind$124$598.length }));
11585
11640
  if (_bind.length === 3) {
11586
11641
  const _a = _bind[0];
11587
11642
  const _b = _bind[1];
@@ -11590,7 +11645,7 @@ function zxch3n$flock$flock$$HlcWithPeer$from_string(s) {
11590
11645
  let _try_err;
11591
11646
  _L: {
11592
11647
  _L$2: {
11593
- const _bind$2 = moonbitlang$core$builtin$$Show$to_string$16$(_a);
11648
+ const _bind$2 = moonbitlang$core$builtin$$Show$to_string$15$(_a);
11594
11649
  const _bind$3 = moonbitlang$core$json$$parse$46$inner({ str: _bind$2, start: 0, end: _bind$2.length }, 1024);
11595
11650
  let _tmp$2;
11596
11651
  if (_bind$3.$tag === 1) {
@@ -11612,7 +11667,7 @@ function zxch3n$flock$flock$$HlcWithPeer$from_string(s) {
11612
11667
  let _try_err$2;
11613
11668
  _L$2: {
11614
11669
  _L$3: {
11615
- const _bind$2 = moonbitlang$core$builtin$$Show$to_string$16$(_b);
11670
+ const _bind$2 = moonbitlang$core$builtin$$Show$to_string$15$(_b);
11616
11671
  const _bind$3 = moonbitlang$core$json$$parse$46$inner({ str: _bind$2, start: 0, end: _bind$2.length }, 1024);
11617
11672
  let _tmp$4;
11618
11673
  if (_bind$3.$tag === 1) {
@@ -11946,13 +12001,13 @@ function zxch3n$flock$flock$$make_entry(key, value) {
11946
12001
  return { key: key, value: value, overridden: false };
11947
12002
  }
11948
12003
  function zxch3n$flock$flock$$entries_equal(a, b) {
11949
- if (moonbitlang$core$builtin$$Eq$equal$7$(a.key, b.key)) {
12004
+ if (moonbitlang$core$builtin$$Eq$equal$6$(a.key, b.key)) {
11950
12005
  let _tmp;
11951
12006
  if (moonbitlang$core$builtin$$Eq$equal$45$(a.value.data, b.value.data)) {
11952
12007
  let _tmp$2;
11953
12008
  if (moonbitlang$core$builtin$$Eq$equal$65$(a.value.metadata, b.value.metadata)) {
11954
12009
  let _tmp$3;
11955
- if (moonbitlang$core$builtin$$Eq$equal$7$(a.value.clock.peer, b.value.clock.peer)) {
12010
+ if (moonbitlang$core$builtin$$Eq$equal$6$(a.value.clock.peer, b.value.clock.peer)) {
11956
12011
  const _p = a.value.clock.hlc;
11957
12012
  const _p$2 = b.value.clock.hlc;
11958
12013
  _tmp$3 = _p.physical_time === _p$2.physical_time && _p.logical_counter === _p$2.logical_counter;
@@ -12197,7 +12252,7 @@ function zxch3n$flock$flock$$Flock$check_consistency(a, b) {
12197
12252
  const _bind$2 = moonbitlang$core$array$$Array$at$52$(entries_b, i);
12198
12253
  const _key_b = _bind$2._0;
12199
12254
  const _entry_b = _bind$2._1;
12200
- if (moonbitlang$core$builtin$$op_notequal$7$(_key_a, _key_b)) {
12255
+ if (moonbitlang$core$builtin$$op_notequal$6$(_key_a, _key_b)) {
12201
12256
  return false;
12202
12257
  }
12203
12258
  if (!zxch3n$flock$flock$$entries_equal(_entry_a, _entry_b)) {
@@ -12344,12 +12399,12 @@ function zxch3n$flock$flock$$prefix_upper_bound_bytes(bytes) {
12344
12399
  if ((bytes.end - bytes.start | 0) === 0) {
12345
12400
  return undefined;
12346
12401
  }
12347
- const data = moonbitlang$core$array$$Array$new$46$inner$12$(bytes.end - bytes.start | 0);
12402
+ const data = moonbitlang$core$array$$Array$new$46$inner$13$(bytes.end - bytes.start | 0);
12348
12403
  let _tmp = 0;
12349
12404
  while (true) {
12350
12405
  const i = _tmp;
12351
12406
  if (i < (bytes.end - bytes.start | 0)) {
12352
- moonbitlang$core$array$$Array$push$12$(data, moonbitlang$core$bytes$$BytesView$at(bytes, i));
12407
+ moonbitlang$core$array$$Array$push$13$(data, moonbitlang$core$bytes$$BytesView$at(bytes, i));
12353
12408
  _tmp = i + 1 | 0;
12354
12409
  continue;
12355
12410
  } else {
@@ -12360,15 +12415,15 @@ function zxch3n$flock$flock$$prefix_upper_bound_bytes(bytes) {
12360
12415
  while (true) {
12361
12416
  const i = _tmp$2;
12362
12417
  if (i >= 0) {
12363
- const current = moonbitlang$core$array$$Array$at$12$(data, i);
12418
+ const current = moonbitlang$core$array$$Array$at$13$(data, i);
12364
12419
  if (current < 255) {
12365
- moonbitlang$core$array$$Array$set$12$(data, i, (current + 1 | 0) & 255);
12366
- const truncated = moonbitlang$core$array$$Array$new$46$inner$12$(i + 1 | 0);
12420
+ moonbitlang$core$array$$Array$set$13$(data, i, (current + 1 | 0) & 255);
12421
+ const truncated = moonbitlang$core$array$$Array$new$46$inner$13$(i + 1 | 0);
12367
12422
  let _tmp$3 = 0;
12368
12423
  while (true) {
12369
12424
  const j = _tmp$3;
12370
12425
  if (j <= i) {
12371
- moonbitlang$core$array$$Array$push$12$(truncated, moonbitlang$core$array$$Array$at$12$(data, j));
12426
+ moonbitlang$core$array$$Array$push$13$(truncated, moonbitlang$core$array$$Array$at$13$(data, j));
12372
12427
  _tmp$3 = j + 1 | 0;
12373
12428
  continue;
12374
12429
  } else {
@@ -12385,7 +12440,7 @@ function zxch3n$flock$flock$$prefix_upper_bound_bytes(bytes) {
12385
12440
  }
12386
12441
  return undefined;
12387
12442
  }
12388
- function zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$375(_env, bytes, inclusive) {
12443
+ function zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$380(_env, bytes, inclusive) {
12389
12444
  const lower_inclusive = _env._1;
12390
12445
  const lower_bytes = _env._0;
12391
12446
  const _bind = lower_bytes.val;
@@ -12411,7 +12466,7 @@ function zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$375(_env, bytes, i
12411
12466
  }
12412
12467
  }
12413
12468
  }
12414
- function zxch3n$flock$flock$$scan$46$inner$46$apply_upper$124$387(_env, bytes, inclusive) {
12469
+ function zxch3n$flock$flock$$scan$46$inner$46$apply_upper$124$392(_env, bytes, inclusive) {
12415
12470
  const upper_inclusive = _env._1;
12416
12471
  const upper_bytes = _env._0;
12417
12472
  const _bind = upper_bytes.val;
@@ -12529,19 +12584,19 @@ function zxch3n$flock$flock$$Flock$scan$46$inner(self, start, end, prefix) {
12529
12584
  } else {
12530
12585
  const _Some = _bind$5;
12531
12586
  const _prefix_key = _Some;
12532
- zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$375(_env, _prefix_key, true);
12587
+ zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$380(_env, _prefix_key, true);
12533
12588
  }
12534
12589
  switch (start_bound_bytes.$tag) {
12535
12590
  case 0: {
12536
12591
  const _Inclusive$3 = start_bound_bytes;
12537
12592
  const _start_key = _Inclusive$3._0;
12538
- zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$375(_env, _start_key, true);
12593
+ zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$380(_env, _start_key, true);
12539
12594
  break;
12540
12595
  }
12541
12596
  case 1: {
12542
12597
  const _Exclusive$3 = start_bound_bytes;
12543
12598
  const _start_key$2 = _Exclusive$3._0;
12544
- zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$375(_env, _start_key$2, false);
12599
+ zxch3n$flock$flock$$scan$46$inner$46$apply_lower$124$380(_env, _start_key$2, false);
12545
12600
  break;
12546
12601
  }
12547
12602
  }
@@ -12562,19 +12617,19 @@ function zxch3n$flock$flock$$Flock$scan$46$inner(self, start, end, prefix) {
12562
12617
  } else {
12563
12618
  const _Some = _bind$7;
12564
12619
  const _prefix_upper = _Some;
12565
- zxch3n$flock$flock$$scan$46$inner$46$apply_upper$124$387(_env$2, _prefix_upper, false);
12620
+ zxch3n$flock$flock$$scan$46$inner$46$apply_upper$124$392(_env$2, _prefix_upper, false);
12566
12621
  }
12567
12622
  switch (end_bound_bytes.$tag) {
12568
12623
  case 0: {
12569
12624
  const _Inclusive$4 = end_bound_bytes;
12570
12625
  const _end_key = _Inclusive$4._0;
12571
- zxch3n$flock$flock$$scan$46$inner$46$apply_upper$124$387(_env$2, _end_key, true);
12626
+ zxch3n$flock$flock$$scan$46$inner$46$apply_upper$124$392(_env$2, _end_key, true);
12572
12627
  break;
12573
12628
  }
12574
12629
  case 1: {
12575
12630
  const _Exclusive$4 = end_bound_bytes;
12576
12631
  const _end_key$2 = _Exclusive$4._0;
12577
- zxch3n$flock$flock$$scan$46$inner$46$apply_upper$124$387(_env$2, _end_key$2, false);
12632
+ zxch3n$flock$flock$$scan$46$inner$46$apply_upper$124$392(_env$2, _end_key$2, false);
12578
12633
  break;
12579
12634
  }
12580
12635
  }
@@ -12645,7 +12700,7 @@ function zxch3n$flock$flock$$Flock$subscribe(self, listener) {
12645
12700
  function zxch3n$flock$flock$$Flock$version(self) {
12646
12701
  return moonbitlang$core$builtin$$Map$copy$71$(self.vv);
12647
12702
  }
12648
- function zxch3n$flock$flock$$Flock$export_json(self, from) {
12703
+ function zxch3n$flock$flock$$Flock$export_json$46$inner(self, from, prune_tombstones_before) {
12649
12704
  const ans = moonbitlang$core$builtin$$Map$new$46$inner$37$(8);
12650
12705
  const _p = 0;
12651
12706
  const _p$2 = undefined;
@@ -12698,6 +12753,16 @@ function zxch3n$flock$flock$$Flock$export_json(self, from) {
12698
12753
  if (update.overridden) {
12699
12754
  break _L$3;
12700
12755
  }
12756
+ if (prune_tombstones_before.$tag === 1) {
12757
+ const _Some$3 = prune_tombstones_before;
12758
+ const _before = _Some$3._0;
12759
+ const _bind$4 = update.value.data;
12760
+ if (_bind$4 === undefined) {
12761
+ if (update.value.clock.hlc.physical_time < _before) {
12762
+ break _L$3;
12763
+ }
12764
+ }
12765
+ }
12701
12766
  const key = zxch3n$flock$memcomparable$$decode_key_to_json(update.key);
12702
12767
  const exported_value = update.value;
12703
12768
  moonbitlang$core$builtin$$Map$set$37$(entries, moonbitlang$core$json$$Json$stringify$46$inner(moonbitlang$core$builtin$$ToJson$to_json$32$(key), false, 0, undefined), zxch3n$flock$flock$$RawValue$to_json(exported_value));
@@ -12751,6 +12816,16 @@ function zxch3n$flock$flock$$Flock$export_json(self, from) {
12751
12816
  moonbitlang$core$builtin$$Map$set$37$(ans, "entries", new $64$moonbitlang$47$core$47$builtin$46$Json$Object(entries));
12752
12817
  return new $64$moonbitlang$47$core$47$builtin$46$Json$Object(ans);
12753
12818
  }
12819
+ function zxch3n$flock$flock$$Flock$export_json(self, from, prune_tombstones_before$46$opt) {
12820
+ let prune_tombstones_before;
12821
+ if (prune_tombstones_before$46$opt === undefined) {
12822
+ prune_tombstones_before = Option$None$8$;
12823
+ } else {
12824
+ const _Some = prune_tombstones_before$46$opt;
12825
+ prune_tombstones_before = _Some;
12826
+ }
12827
+ return zxch3n$flock$flock$$Flock$export_json$46$inner(self, from, prune_tombstones_before);
12828
+ }
12754
12829
  function zxch3n$flock$flock$$Flock$import_json$46$inner(self, json, hooks) {
12755
12830
  if (json.$tag === 6) {
12756
12831
  const _Object = json;
@@ -12902,9 +12977,9 @@ function zxch3n$flock$flock$$Flock$import_json$46$inner(self, json, hooks) {
12902
12977
  const _bind$5 = events.val;
12903
12978
  if (_bind$5.$tag === 1) {
12904
12979
  const _Some$2 = _bind$5;
12905
- const _evts = _Some$2._0;
12980
+ const _events_ = _Some$2._0;
12906
12981
  const event_key = zxch3n$flock$memcomparable$$decode_key_to_json(final_entry.key);
12907
- moonbitlang$core$array$$Array$push$51$(_evts, { _0: event_key, _1: zxch3n$flock$flock$$clone_raw_value(final_entry.value) });
12982
+ moonbitlang$core$array$$Array$push$51$(_events_, { _0: event_key, _1: zxch3n$flock$flock$$clone_raw_value(final_entry.value) });
12908
12983
  }
12909
12984
  }
12910
12985
  }
@@ -12945,7 +13020,7 @@ function zxch3n$flock$flock$$Flock$import_json$46$inner(self, json, hooks) {
12945
13020
  const _Some = _bind$2;
12946
13021
  const _events = _Some._0;
12947
13022
  if (_events.length > 0) {
12948
- zxch3n$flock$flock$$SubscriberSet$notify$81$(self.subscribers, { by: zxch3n$flock$flock$$import_json$46$inner$46$constr$47$3475, events: _events });
13023
+ zxch3n$flock$flock$$SubscriberSet$notify$81$(self.subscribers, { by: zxch3n$flock$flock$$import_json$46$inner$46$constr$47$3484, events: _events });
12949
13024
  }
12950
13025
  }
12951
13026
  return new Result$Ok$37$({ accepted: accepted.val, skipped: skipped_entries });
@@ -12967,7 +13042,7 @@ function zxch3n$flock$flock$$Flock$merge(self, other) {
12967
13042
  let _try_err;
12968
13043
  _L: {
12969
13044
  _L$2: {
12970
- const _bind = zxch3n$flock$flock$$Flock$import_json(self, zxch3n$flock$flock$$Flock$export_json(other, zxch3n$flock$flock$$Flock$version(self)), Option$None$40$);
13045
+ const _bind = zxch3n$flock$flock$$Flock$import_json(self, zxch3n$flock$flock$$Flock$export_json(other, zxch3n$flock$flock$$Flock$version(self), undefined), Option$None$40$);
12971
13046
  if (_bind.$tag === 1) {
12972
13047
  const _ok = _bind;
12973
13048
  _ok._0;
@@ -12995,7 +13070,7 @@ function zxch3n$flock$flock$$Flock$from_json(json, peer_id) {
12995
13070
  return new Result$Ok$41$(flock);
12996
13071
  }
12997
13072
  function zxch3n$flock$flock$$Flock$kv_to_json(self) {
12998
- return zxch3n$flock$flock$$Flock$export_json(self, undefined);
13073
+ return zxch3n$flock$flock$$Flock$export_json(self, undefined, undefined);
12999
13074
  }
13000
13075
  function zxch3n$flock$flock$$Flock$put_mvr$46$inner(self, key, value, now) {
13001
13076
  const _foreach_result = { val: $64$moonbitlang$47$core$47$builtin$46$ForeachResult$Continue$42$ };
@@ -13117,7 +13192,7 @@ function zxch3n$flock$flock$$Flock$newFlock(peer_id) {
13117
13192
  const _bind$3 = zxch3n$flock$sorted_map$$SortedMap$new$80$();
13118
13193
  const _bind$4 = zxch3n$flock$flock$$SubscriberSet$new$81$();
13119
13194
  const _bind$5 = undefined;
13120
- return { peer_id: peer_id, max_hlc: zxch3n$flock$flock$$newFlock$46$42$bind$47$3584, vv: _bind, kv: _bind$2, updates: _bind$3, subscribers: _bind$4, digest: _bind$5 };
13195
+ return { peer_id: peer_id, max_hlc: zxch3n$flock$flock$$newFlock$46$42$bind$47$3593, vv: _bind, kv: _bind$2, updates: _bind$3, subscribers: _bind$4, digest: _bind$5 };
13121
13196
  }
13122
13197
  function zxch3n$flock$flock$$json_stringify_value(value) {
13123
13198
  return zxch3n$flock$flock$$ffi_json_stringify_value(value);
@@ -13240,7 +13315,7 @@ function zxch3n$flock$flock$$json_to_metadata(json) {
13240
13315
  return undefined;
13241
13316
  }
13242
13317
  default: {
13243
- return moonbitlang$core$abort$$abort$6$("metadata must be an object or null");
13318
+ return moonbitlang$core$abort$$abort$5$("metadata must be an object or null");
13244
13319
  }
13245
13320
  }
13246
13321
  }
@@ -13313,7 +13388,7 @@ function zxch3n$flock$flock$$json_to_version_vector(json) {
13313
13388
  const _bind$2 = zxch3n$flock$flock$$bytes_from_hex({ str: peer_hex, start: 0, end: peer_hex.length });
13314
13389
  let bytes;
13315
13390
  if (_bind$2 === undefined) {
13316
- bytes = moonbitlang$core$abort$$abort$3$("invalid peer id in version vector");
13391
+ bytes = moonbitlang$core$abort$$abort$2$("invalid peer id in version vector");
13317
13392
  } else {
13318
13393
  const _Some = _bind$2;
13319
13394
  bytes = _Some;
@@ -13336,23 +13411,23 @@ function zxch3n$flock$flock$$json_to_version_vector(json) {
13336
13411
  }
13337
13412
  break _L;
13338
13413
  }
13339
- moonbitlang$core$abort$$abort$4$("version vector entry must be [physical_time, logical_counter]");
13414
+ moonbitlang$core$abort$$abort$3$("version vector entry must be [physical_time, logical_counter]");
13340
13415
  }
13341
13416
  return 1;
13342
13417
  });
13343
13418
  return vv;
13344
13419
  } else {
13345
- return moonbitlang$core$abort$$abort$5$("version vector must be an object");
13420
+ return moonbitlang$core$abort$$abort$4$("version vector must be an object");
13346
13421
  }
13347
13422
  }
13348
- function zxch3n$flock$flock$$Flock$export_json_ffi(self, from) {
13423
+ function zxch3n$flock$flock$$Flock$export_json_ffi(self, from, prune_tombstones_before) {
13349
13424
  let _try_err;
13350
13425
  _L: {
13351
13426
  let export_from;
13352
13427
  if (zxch3n$flock$flock$$any_is_undefined(from) || zxch3n$flock$flock$$any_is_null(from)) {
13353
13428
  export_from = undefined;
13354
13429
  } else {
13355
- const _bind = Yoorkin$jmop$$Any$unwrap_value(from, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:78:32-78:51");
13430
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(from, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:82:32-82:51");
13356
13431
  let _tmp;
13357
13432
  if (_bind.$tag === 1) {
13358
13433
  const _ok = _bind;
@@ -13366,13 +13441,41 @@ function zxch3n$flock$flock$$Flock$export_json_ffi(self, from) {
13366
13441
  const json = zxch3n$flock$flock$$value_to_json(_tmp);
13367
13442
  export_from = zxch3n$flock$flock$$json_to_version_vector(json);
13368
13443
  }
13444
+ let prune_before;
13445
+ if (zxch3n$flock$flock$$any_is_undefined(prune_tombstones_before) || zxch3n$flock$flock$$any_is_null(prune_tombstones_before)) {
13446
+ prune_before = Option$None$8$;
13447
+ } else {
13448
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(prune_tombstones_before, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:89:12-89:50");
13449
+ let _tmp;
13450
+ if (_bind.$tag === 1) {
13451
+ const _ok = _bind;
13452
+ _tmp = _ok._0;
13453
+ } else {
13454
+ const _err = _bind;
13455
+ const _tmp$2 = _err._0;
13456
+ _try_err = _tmp$2;
13457
+ break _L;
13458
+ }
13459
+ const _bind$2 = Yoorkin$jmop$$Value$to_number(_tmp, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:89:12-89:62");
13460
+ let _tmp$2;
13461
+ if (_bind$2.$tag === 1) {
13462
+ const _ok = _bind$2;
13463
+ _tmp$2 = _ok._0;
13464
+ } else {
13465
+ const _err = _bind$2;
13466
+ const _tmp$3 = _err._0;
13467
+ _try_err = _tmp$3;
13468
+ break _L;
13469
+ }
13470
+ prune_before = new Option$Some$8$(_tmp$2);
13471
+ }
13369
13472
  let exported;
13370
13473
  if (export_from === undefined) {
13371
- exported = zxch3n$flock$flock$$Flock$export_json(self, undefined);
13474
+ exported = zxch3n$flock$flock$$Flock$export_json$46$inner(self, undefined, prune_before);
13372
13475
  } else {
13373
13476
  const _Some = export_from;
13374
13477
  const _vv = _Some;
13375
- exported = zxch3n$flock$flock$$Flock$export_json(self, _vv);
13478
+ exported = zxch3n$flock$flock$$Flock$export_json$46$inner(self, _vv, prune_before);
13376
13479
  }
13377
13480
  const _p = zxch3n$flock$flock$$json_to_value(exported);
13378
13481
  return _p;
@@ -13383,7 +13486,7 @@ function zxch3n$flock$flock$$Flock$import_json_ffi(self, json) {
13383
13486
  let _try_err;
13384
13487
  _L: {
13385
13488
  if (!(zxch3n$flock$flock$$any_is_undefined(json) || zxch3n$flock$flock$$any_is_null(json))) {
13386
- const _bind = Yoorkin$jmop$$Any$unwrap_value(json, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:95:32-95:51");
13489
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(json, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:109:32-109:51");
13387
13490
  let _tmp;
13388
13491
  if (_bind.$tag === 1) {
13389
13492
  const _ok = _bind;
@@ -13431,7 +13534,7 @@ function zxch3n$flock$flock$$Flock$import_json_ffi(self, json) {
13431
13534
  }
13432
13535
  }
13433
13536
  const report_obj = moonbitlang$core$builtin$$Map$new$46$inner$37$(8);
13434
- moonbitlang$core$builtin$$Map$set$37$(report_obj, "accepted", moonbitlang$core$builtin$$ToJson$to_json$13$(report.accepted));
13537
+ moonbitlang$core$builtin$$Map$set$37$(report_obj, "accepted", moonbitlang$core$builtin$$ToJson$to_json$12$(report.accepted));
13435
13538
  moonbitlang$core$builtin$$Map$set$37$(report_obj, "skipped", moonbitlang$core$builtin$$ToJson$to_json$32$(skipped_rows));
13436
13539
  const _p = zxch3n$flock$flock$$json_to_value(moonbitlang$core$builtin$$ToJson$to_json$33$(report_obj));
13437
13540
  return _p;
@@ -13445,7 +13548,7 @@ function zxch3n$flock$flock$$version_vector_to_json(vv) {
13445
13548
  const result = moonbitlang$core$builtin$$Map$new$46$inner$37$(8);
13446
13549
  const _bind = moonbitlang$core$builtin$$Map$iter2$71$(vv);
13447
13550
  _bind((peer, clock) => {
13448
- const entry = [moonbitlang$core$builtin$$ToJson$to_json$24$(clock.physical_time), moonbitlang$core$builtin$$ToJson$to_json$13$(clock.logical_counter)];
13551
+ const entry = [moonbitlang$core$builtin$$ToJson$to_json$24$(clock.physical_time), moonbitlang$core$builtin$$ToJson$to_json$12$(clock.logical_counter)];
13449
13552
  moonbitlang$core$builtin$$Map$set$37$(result, zxch3n$flock$flock$$bytes_to_hex(peer), moonbitlang$core$builtin$$ToJson$to_json$32$(entry));
13450
13553
  return 1;
13451
13554
  });
@@ -13462,7 +13565,7 @@ function zxch3n$flock$flock$$peer_id_to_hex(peer) {
13462
13565
  function zxch3n$flock$flock$$hex_to_peer_id(hex) {
13463
13566
  const _bind = zxch3n$flock$flock$$bytes_from_hex({ str: hex, start: 0, end: hex.length });
13464
13567
  if (_bind === undefined) {
13465
- return moonbitlang$core$abort$$abort$7$("invalid peer id hex");
13568
+ return moonbitlang$core$abort$$abort$6$("invalid peer id hex");
13466
13569
  } else {
13467
13570
  const _Some = _bind;
13468
13571
  const _bytes = _Some;
@@ -13491,7 +13594,7 @@ function zxch3n$flock$flock$$bound_from_json(json) {
13491
13594
  }
13492
13595
  break _L;
13493
13596
  }
13494
- kind = moonbitlang$core$abort$$abort$8$("bound.kind must be a string");
13597
+ kind = moonbitlang$core$abort$$abort$7$("bound.kind must be a string");
13495
13598
  }
13496
13599
  let key;
13497
13600
  _L$2: {
@@ -13512,11 +13615,11 @@ function zxch3n$flock$flock$$bound_from_json(json) {
13512
13615
  }
13513
13616
  break _L$2;
13514
13617
  }
13515
- key = moonbitlang$core$abort$$abort$9$("bound.key must be an array");
13618
+ key = moonbitlang$core$abort$$abort$8$("bound.key must be an array");
13516
13619
  }
13517
- return kind === "inclusive" ? new $64$zxch3n$47$flock$47$sorted_map$46$Bound$Inclusive$29$(key) : kind === "exclusive" ? new $64$zxch3n$47$flock$47$sorted_map$46$Bound$Exclusive$29$(key) : kind === "unbounded" ? $64$zxch3n$47$flock$47$sorted_map$46$Bound$Unbounded$29$ : moonbitlang$core$abort$$abort$10$("unexpected bound.kind");
13620
+ return kind === "inclusive" ? new $64$zxch3n$47$flock$47$sorted_map$46$Bound$Inclusive$29$(key) : kind === "exclusive" ? new $64$zxch3n$47$flock$47$sorted_map$46$Bound$Exclusive$29$(key) : kind === "unbounded" ? $64$zxch3n$47$flock$47$sorted_map$46$Bound$Unbounded$29$ : moonbitlang$core$abort$$abort$9$("unexpected bound.kind");
13518
13621
  } else {
13519
- return moonbitlang$core$abort$$abort$10$("bound must be an object");
13622
+ return moonbitlang$core$abort$$abort$9$("bound must be an object");
13520
13623
  }
13521
13624
  }
13522
13625
  function zxch3n$flock$flock$$check_consistency_ffi(a, b) {
@@ -13528,7 +13631,7 @@ function zxch3n$flock$flock$$Flock$check_invariants_ffi(self) {
13528
13631
  function zxch3n$flock$flock$$Flock$put_json_ffi(self, key, value, now) {
13529
13632
  let _try_err;
13530
13633
  _L: {
13531
- const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:210:21-210:39");
13634
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:224:21-224:39");
13532
13635
  let key_value;
13533
13636
  if (_bind.$tag === 1) {
13534
13637
  const _ok = _bind;
@@ -13539,7 +13642,7 @@ function zxch3n$flock$flock$$Flock$put_json_ffi(self, key, value, now) {
13539
13642
  _try_err = _tmp;
13540
13643
  break _L;
13541
13644
  }
13542
- const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:211:40-211:60");
13645
+ const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:225:40-225:60");
13543
13646
  let key_arr;
13544
13647
  if (_bind$2.$tag === 1) {
13545
13648
  const _ok = _bind$2;
@@ -13565,7 +13668,7 @@ function zxch3n$flock$flock$$Flock$put_json_ffi(self, key, value, now) {
13565
13668
  }
13566
13669
  }
13567
13670
  const key_json = _p;
13568
- const _bind$3 = Yoorkin$jmop$$Any$unwrap_value(value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:213:36-213:56");
13671
+ const _bind$3 = Yoorkin$jmop$$Any$unwrap_value(value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:227:36-227:56");
13569
13672
  let _tmp$2;
13570
13673
  if (_bind$3.$tag === 1) {
13571
13674
  const _ok = _bind$3;
@@ -13581,7 +13684,7 @@ function zxch3n$flock$flock$$Flock$put_json_ffi(self, key, value, now) {
13581
13684
  if (zxch3n$flock$flock$$any_is_undefined(now) || zxch3n$flock$flock$$any_is_null(now)) {
13582
13685
  now_value = Option$None$8$;
13583
13686
  } else {
13584
- const _bind$4 = Yoorkin$jmop$$Any$unwrap_value(now, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:217:12-217:30");
13687
+ const _bind$4 = Yoorkin$jmop$$Any$unwrap_value(now, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:231:12-231:30");
13585
13688
  let _tmp$3;
13586
13689
  if (_bind$4.$tag === 1) {
13587
13690
  const _ok = _bind$4;
@@ -13592,7 +13695,7 @@ function zxch3n$flock$flock$$Flock$put_json_ffi(self, key, value, now) {
13592
13695
  _try_err = _tmp$4;
13593
13696
  break _L;
13594
13697
  }
13595
- const _bind$5 = Yoorkin$jmop$$Value$to_number(_tmp$3, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:217:12-217:42");
13698
+ const _bind$5 = Yoorkin$jmop$$Value$to_number(_tmp$3, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:231:12-231:42");
13596
13699
  let _tmp$4;
13597
13700
  if (_bind$5.$tag === 1) {
13598
13701
  const _ok = _bind$5;
@@ -13622,7 +13725,7 @@ function zxch3n$flock$flock$$Flock$put_json_ffi(self, key, value, now) {
13622
13725
  function zxch3n$flock$flock$$Flock$put_with_meta_ffi(self, key, value, metadata, now) {
13623
13726
  let _try_err;
13624
13727
  _L: {
13625
- const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:232:21-232:39");
13728
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:246:21-246:39");
13626
13729
  let key_value;
13627
13730
  if (_bind.$tag === 1) {
13628
13731
  const _ok = _bind;
@@ -13633,7 +13736,7 @@ function zxch3n$flock$flock$$Flock$put_with_meta_ffi(self, key, value, metadata,
13633
13736
  _try_err = _tmp;
13634
13737
  break _L;
13635
13738
  }
13636
- const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:233:40-233:60");
13739
+ const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:247:40-247:60");
13637
13740
  let key_arr;
13638
13741
  if (_bind$2.$tag === 1) {
13639
13742
  const _ok = _bind$2;
@@ -13659,7 +13762,7 @@ function zxch3n$flock$flock$$Flock$put_with_meta_ffi(self, key, value, metadata,
13659
13762
  }
13660
13763
  }
13661
13764
  const key_json = _p;
13662
- const _bind$3 = Yoorkin$jmop$$Any$unwrap_value(value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:235:36-235:56");
13765
+ const _bind$3 = Yoorkin$jmop$$Any$unwrap_value(value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:249:36-249:56");
13663
13766
  let _tmp$2;
13664
13767
  if (_bind$3.$tag === 1) {
13665
13768
  const _ok = _bind$3;
@@ -13675,7 +13778,7 @@ function zxch3n$flock$flock$$Flock$put_with_meta_ffi(self, key, value, metadata,
13675
13778
  if (zxch3n$flock$flock$$any_is_undefined(metadata) || zxch3n$flock$flock$$any_is_null(metadata)) {
13676
13779
  metadata_value = undefined;
13677
13780
  } else {
13678
- const _bind$4 = Yoorkin$jmop$$Any$unwrap_value(metadata, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:239:41-239:64");
13781
+ const _bind$4 = Yoorkin$jmop$$Any$unwrap_value(metadata, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:253:41-253:64");
13679
13782
  let _tmp$3;
13680
13783
  if (_bind$4.$tag === 1) {
13681
13784
  const _ok = _bind$4;
@@ -13693,7 +13796,7 @@ function zxch3n$flock$flock$$Flock$put_with_meta_ffi(self, key, value, metadata,
13693
13796
  if (zxch3n$flock$flock$$any_is_undefined(now) || zxch3n$flock$flock$$any_is_null(now)) {
13694
13797
  now_value = Option$None$8$;
13695
13798
  } else {
13696
- const _bind$4 = Yoorkin$jmop$$Any$unwrap_value(now, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:245:12-245:30");
13799
+ const _bind$4 = Yoorkin$jmop$$Any$unwrap_value(now, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:259:12-259:30");
13697
13800
  let _tmp$3;
13698
13801
  if (_bind$4.$tag === 1) {
13699
13802
  const _ok = _bind$4;
@@ -13704,7 +13807,7 @@ function zxch3n$flock$flock$$Flock$put_with_meta_ffi(self, key, value, metadata,
13704
13807
  _try_err = _tmp$4;
13705
13808
  break _L;
13706
13809
  }
13707
- const _bind$5 = Yoorkin$jmop$$Value$to_number(_tmp$3, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:245:12-245:42");
13810
+ const _bind$5 = Yoorkin$jmop$$Value$to_number(_tmp$3, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:259:12-259:42");
13708
13811
  let _tmp$4;
13709
13812
  if (_bind$5.$tag === 1) {
13710
13813
  const _ok = _bind$5;
@@ -13750,7 +13853,7 @@ function zxch3n$flock$flock$$Flock$put_with_meta_ffi(self, key, value, metadata,
13750
13853
  function zxch3n$flock$flock$$Flock$delete_ffi(self, key, now) {
13751
13854
  let _try_err;
13752
13855
  _L: {
13753
- const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:267:21-267:39");
13856
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:281:21-281:39");
13754
13857
  let key_value;
13755
13858
  if (_bind.$tag === 1) {
13756
13859
  const _ok = _bind;
@@ -13761,7 +13864,7 @@ function zxch3n$flock$flock$$Flock$delete_ffi(self, key, now) {
13761
13864
  _try_err = _tmp;
13762
13865
  break _L;
13763
13866
  }
13764
- const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:268:40-268:60");
13867
+ const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:282:40-282:60");
13765
13868
  let key_arr;
13766
13869
  if (_bind$2.$tag === 1) {
13767
13870
  const _ok = _bind$2;
@@ -13791,7 +13894,7 @@ function zxch3n$flock$flock$$Flock$delete_ffi(self, key, now) {
13791
13894
  if (zxch3n$flock$flock$$any_is_undefined(now) || zxch3n$flock$flock$$any_is_null(now)) {
13792
13895
  now_value = Option$None$8$;
13793
13896
  } else {
13794
- const _bind$3 = Yoorkin$jmop$$Any$unwrap_value(now, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:273:12-273:30");
13897
+ const _bind$3 = Yoorkin$jmop$$Any$unwrap_value(now, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:287:12-287:30");
13795
13898
  let _tmp$2;
13796
13899
  if (_bind$3.$tag === 1) {
13797
13900
  const _ok = _bind$3;
@@ -13802,7 +13905,7 @@ function zxch3n$flock$flock$$Flock$delete_ffi(self, key, now) {
13802
13905
  _try_err = _tmp$3;
13803
13906
  break _L;
13804
13907
  }
13805
- const _bind$4 = Yoorkin$jmop$$Value$to_number(_tmp$2, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:273:12-273:42");
13908
+ const _bind$4 = Yoorkin$jmop$$Value$to_number(_tmp$2, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:287:12-287:42");
13806
13909
  let _tmp$3;
13807
13910
  if (_bind$4.$tag === 1) {
13808
13911
  const _ok = _bind$4;
@@ -13842,10 +13945,10 @@ function zxch3n$flock$flock$$Flock$kv_to_json_ffi(self) {
13842
13945
  return _p;
13843
13946
  }
13844
13947
  function zxch3n$flock$flock$$FlockDigest$copy(self) {
13845
- return { bytes: moonbitlang$core$array$$FixedArray$copy$12$(self.bytes) };
13948
+ return { bytes: moonbitlang$core$array$$FixedArray$copy$13$(self.bytes) };
13846
13949
  }
13847
13950
  function zxch3n$flock$flock$$FlockDigest$xor(self, digest) {
13848
- const bytes = moonbitlang$core$array$$FixedArray$copy$12$(self.bytes);
13951
+ const bytes = moonbitlang$core$array$$FixedArray$copy$13$(self.bytes);
13849
13952
  const digest_bytes = digest.bytes;
13850
13953
  let _tmp = 0;
13851
13954
  while (true) {
@@ -13968,7 +14071,7 @@ function zxch3n$flock$flock$$Flock$digest_hex_ffi(self) {
13968
14071
  function zxch3n$flock$flock$$Flock$put_mvr_ffi(self, key, value, now) {
13969
14072
  let _try_err;
13970
14073
  _L: {
13971
- const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:307:21-307:39");
14074
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:321:21-321:39");
13972
14075
  let key_value;
13973
14076
  if (_bind.$tag === 1) {
13974
14077
  const _ok = _bind;
@@ -13979,7 +14082,7 @@ function zxch3n$flock$flock$$Flock$put_mvr_ffi(self, key, value, now) {
13979
14082
  _try_err = _tmp;
13980
14083
  break _L;
13981
14084
  }
13982
- const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:308:40-308:60");
14085
+ const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:322:40-322:60");
13983
14086
  let key_arr;
13984
14087
  if (_bind$2.$tag === 1) {
13985
14088
  const _ok = _bind$2;
@@ -14005,7 +14108,7 @@ function zxch3n$flock$flock$$Flock$put_mvr_ffi(self, key, value, now) {
14005
14108
  }
14006
14109
  }
14007
14110
  const key_json = _p;
14008
- const _bind$3 = Yoorkin$jmop$$Any$unwrap_value(value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:310:36-310:56");
14111
+ const _bind$3 = Yoorkin$jmop$$Any$unwrap_value(value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:324:36-324:56");
14009
14112
  let _tmp$2;
14010
14113
  if (_bind$3.$tag === 1) {
14011
14114
  const _ok = _bind$3;
@@ -14021,7 +14124,7 @@ function zxch3n$flock$flock$$Flock$put_mvr_ffi(self, key, value, now) {
14021
14124
  if (zxch3n$flock$flock$$any_is_undefined(now) || zxch3n$flock$flock$$any_is_null(now)) {
14022
14125
  now_value = Option$None$8$;
14023
14126
  } else {
14024
- const _bind$4 = Yoorkin$jmop$$Any$unwrap_value(now, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:314:12-314:30");
14127
+ const _bind$4 = Yoorkin$jmop$$Any$unwrap_value(now, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:328:12-328:30");
14025
14128
  let _tmp$3;
14026
14129
  if (_bind$4.$tag === 1) {
14027
14130
  const _ok = _bind$4;
@@ -14032,7 +14135,7 @@ function zxch3n$flock$flock$$Flock$put_mvr_ffi(self, key, value, now) {
14032
14135
  _try_err = _tmp$4;
14033
14136
  break _L;
14034
14137
  }
14035
- const _bind$5 = Yoorkin$jmop$$Value$to_number(_tmp$3, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:314:12-314:42");
14138
+ const _bind$5 = Yoorkin$jmop$$Value$to_number(_tmp$3, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:328:12-328:42");
14036
14139
  let _tmp$4;
14037
14140
  if (_bind$5.$tag === 1) {
14038
14141
  const _ok = _bind$5;
@@ -14062,7 +14165,7 @@ function zxch3n$flock$flock$$Flock$put_mvr_ffi(self, key, value, now) {
14062
14165
  function zxch3n$flock$flock$$Flock$get_mvr_ffi(self, key) {
14063
14166
  let _try_err;
14064
14167
  _L: {
14065
- const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:323:21-323:39");
14168
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(key, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:337:21-337:39");
14066
14169
  let key_value;
14067
14170
  if (_bind.$tag === 1) {
14068
14171
  const _ok = _bind;
@@ -14073,7 +14176,7 @@ function zxch3n$flock$flock$$Flock$get_mvr_ffi(self, key) {
14073
14176
  _try_err = _tmp;
14074
14177
  break _L;
14075
14178
  }
14076
- const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:324:40-324:60");
14179
+ const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(key_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:338:40-338:60");
14077
14180
  let key_arr;
14078
14181
  if (_bind$2.$tag === 1) {
14079
14182
  const _ok = _bind$2;
@@ -14108,7 +14211,7 @@ function zxch3n$flock$flock$$Flock$get_mvr_ffi(self, key) {
14108
14211
  function zxch3n$flock$flock$$from_json_ffi(json, peer_id) {
14109
14212
  let _try_err;
14110
14213
  _L: {
14111
- const _bind = Yoorkin$jmop$$Any$unwrap_value(json, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:334:22-334:41");
14214
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(json, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:348:22-348:41");
14112
14215
  let json_value;
14113
14216
  if (_bind.$tag === 1) {
14114
14217
  const _ok = _bind;
@@ -14120,7 +14223,7 @@ function zxch3n$flock$flock$$from_json_ffi(json, peer_id) {
14120
14223
  break _L;
14121
14224
  }
14122
14225
  const parsed = zxch3n$flock$flock$$value_to_json(json_value);
14123
- const _bind$2 = Yoorkin$jmop$$Any$unwrap_value(peer_id, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:336:22-336:44");
14226
+ const _bind$2 = Yoorkin$jmop$$Any$unwrap_value(peer_id, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:350:22-350:44");
14124
14227
  let peer_value;
14125
14228
  if (_bind$2.$tag === 1) {
14126
14229
  const _ok = _bind$2;
@@ -14131,7 +14234,7 @@ function zxch3n$flock$flock$$from_json_ffi(json, peer_id) {
14131
14234
  _try_err = _tmp;
14132
14235
  break _L;
14133
14236
  }
14134
- const _bind$3 = Yoorkin$jmop$$Value$to_string(peer_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:337:20-337:42");
14237
+ const _bind$3 = Yoorkin$jmop$$Value$to_string(peer_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:351:20-351:42");
14135
14238
  let peer_hex;
14136
14239
  if (_bind$3.$tag === 1) {
14137
14240
  const _ok = _bind$3;
@@ -14162,7 +14265,7 @@ function zxch3n$flock$flock$$Flock$scan_ffi(self, start, end, prefix) {
14162
14265
  if (zxch3n$flock$flock$$any_is_undefined(start) || zxch3n$flock$flock$$any_is_null(start)) {
14163
14266
  start_bound = $64$zxch3n$47$flock$47$sorted_map$46$Bound$Unbounded$29$;
14164
14267
  } else {
14165
- const _bind = Yoorkin$jmop$$Any$unwrap_value(start, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:353:25-353:45");
14268
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(start, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:367:25-367:45");
14166
14269
  let start_value;
14167
14270
  if (_bind.$tag === 1) {
14168
14271
  const _ok = _bind;
@@ -14179,7 +14282,7 @@ function zxch3n$flock$flock$$Flock$scan_ffi(self, start, end, prefix) {
14179
14282
  if (zxch3n$flock$flock$$any_is_undefined(end) || zxch3n$flock$flock$$any_is_null(end)) {
14180
14283
  end_bound = $64$zxch3n$47$flock$47$sorted_map$46$Bound$Unbounded$29$;
14181
14284
  } else {
14182
- const _bind = Yoorkin$jmop$$Any$unwrap_value(end, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:359:23-359:41");
14285
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(end, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:373:23-373:41");
14183
14286
  let end_value;
14184
14287
  if (_bind.$tag === 1) {
14185
14288
  const _ok = _bind;
@@ -14196,7 +14299,7 @@ function zxch3n$flock$flock$$Flock$scan_ffi(self, start, end, prefix) {
14196
14299
  if (zxch3n$flock$flock$$any_is_undefined(prefix) || zxch3n$flock$flock$$any_is_null(prefix)) {
14197
14300
  prefix_filter = Option$None$29$;
14198
14301
  } else {
14199
- const _bind = Yoorkin$jmop$$Any$unwrap_value(prefix, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:365:26-365:47");
14302
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(prefix, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:379:26-379:47");
14200
14303
  let prefix_value;
14201
14304
  if (_bind.$tag === 1) {
14202
14305
  const _ok = _bind;
@@ -14207,7 +14310,7 @@ function zxch3n$flock$flock$$Flock$scan_ffi(self, start, end, prefix) {
14207
14310
  _try_err = _tmp;
14208
14311
  break _L;
14209
14312
  }
14210
- const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(prefix_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:366:45-366:68");
14313
+ const _bind$2 = Yoorkin$jmop$$Value$to_array$76$(prefix_value, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:380:45-380:68");
14211
14314
  let prefix_arr;
14212
14315
  if (_bind$2.$tag === 1) {
14213
14316
  const _ok = _bind$2;
@@ -14303,7 +14406,7 @@ function zxch3n$flock$flock$$raw_value_payload_to_json(value) {
14303
14406
  function zxch3n$flock$flock$$Flock$subscribe_ffi(self, listener) {
14304
14407
  let _try_err;
14305
14408
  _L: {
14306
- const _bind = Yoorkin$jmop$$Any$unwrap_value(listener, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:415:26-415:49");
14409
+ const _bind = Yoorkin$jmop$$Any$unwrap_value(listener, "/home/runner/work/flock/flock/moon/flock/ffi-js.mbt:429:26-429:49");
14307
14410
  let listener_value;
14308
14411
  if (_bind.$tag === 1) {
14309
14412
  const _ok = _bind;
@@ -14367,4 +14470,4 @@ function zxch3n$flock$flock$$Flock$subscribe_ffi(self, listener) {
14367
14470
  }
14368
14471
  return $panic();
14369
14472
  }
14370
- export { zxch3n$flock$flock$$Flock$set_peer_id as set_peer_id, zxch3n$flock$flock$$Flock$version as version, zxch3n$flock$flock$$Flock$export_json as export_json, zxch3n$flock$flock$$Flock$import_json as import_json, zxch3n$flock$flock$$Flock$merge as merge, zxch3n$flock$flock$$Flock$from_json as from_json, zxch3n$flock$flock$$Flock$newFlock as newFlock, zxch3n$flock$flock$$Flock$put_ffi as put_ffi, zxch3n$flock$flock$$Flock$get_ffi as get_ffi, zxch3n$flock$flock$$Flock$export_json_ffi as export_json_ffi, zxch3n$flock$flock$$Flock$import_json_ffi as import_json_ffi, zxch3n$flock$flock$$Flock$version_ffi as version_ffi, zxch3n$flock$flock$$check_consistency_ffi as check_consistency_ffi, zxch3n$flock$flock$$Flock$check_invariants_ffi as check_invariants_ffi, zxch3n$flock$flock$$Flock$put_json_ffi as put_json_ffi, zxch3n$flock$flock$$Flock$put_with_meta_ffi as put_with_meta_ffi, zxch3n$flock$flock$$Flock$delete_ffi as delete_ffi, zxch3n$flock$flock$$Flock$get_max_physical_time_ffi as get_max_physical_time_ffi, zxch3n$flock$flock$$Flock$peer_id_ffi as peer_id_ffi, zxch3n$flock$flock$$Flock$kv_to_json_ffi as kv_to_json_ffi, zxch3n$flock$flock$$Flock$digest_hex_ffi as digest_hex_ffi, zxch3n$flock$flock$$Flock$put_mvr_ffi as put_mvr_ffi, zxch3n$flock$flock$$Flock$get_mvr_ffi as get_mvr_ffi, zxch3n$flock$flock$$from_json_ffi as from_json_ffi, zxch3n$flock$flock$$Flock$scan_ffi as scan_ffi, zxch3n$flock$flock$$Flock$subscribe_ffi as subscribe_ffi }
14473
+ export { moonbitlang$core$builtin$$get_int64_wasm_helper as _int64_helper_for_test, zxch3n$flock$flock$$Flock$set_peer_id as set_peer_id, zxch3n$flock$flock$$Flock$version as version, zxch3n$flock$flock$$Flock$export_json as export_json, zxch3n$flock$flock$$Flock$import_json as import_json, zxch3n$flock$flock$$Flock$merge as merge, zxch3n$flock$flock$$Flock$from_json as from_json, zxch3n$flock$flock$$Flock$newFlock as newFlock, zxch3n$flock$flock$$Flock$put_ffi as put_ffi, zxch3n$flock$flock$$Flock$get_ffi as get_ffi, zxch3n$flock$flock$$Flock$export_json_ffi as export_json_ffi, zxch3n$flock$flock$$Flock$import_json_ffi as import_json_ffi, zxch3n$flock$flock$$Flock$version_ffi as version_ffi, zxch3n$flock$flock$$check_consistency_ffi as check_consistency_ffi, zxch3n$flock$flock$$Flock$check_invariants_ffi as check_invariants_ffi, zxch3n$flock$flock$$Flock$put_json_ffi as put_json_ffi, zxch3n$flock$flock$$Flock$put_with_meta_ffi as put_with_meta_ffi, zxch3n$flock$flock$$Flock$delete_ffi as delete_ffi, zxch3n$flock$flock$$Flock$get_max_physical_time_ffi as get_max_physical_time_ffi, zxch3n$flock$flock$$Flock$peer_id_ffi as peer_id_ffi, zxch3n$flock$flock$$Flock$kv_to_json_ffi as kv_to_json_ffi, zxch3n$flock$flock$$Flock$digest_hex_ffi as digest_hex_ffi, zxch3n$flock$flock$$Flock$put_mvr_ffi as put_mvr_ffi, zxch3n$flock$flock$$Flock$get_mvr_ffi as get_mvr_ffi, zxch3n$flock$flock$$from_json_ffi as from_json_ffi, zxch3n$flock$flock$$Flock$scan_ffi as scan_ffi, zxch3n$flock$flock$$Flock$subscribe_ffi as subscribe_ffi }