@swc/wasm 1.3.43 → 1.3.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "강동윤 <kdy1997.dev@gmail.com>"
5
5
  ],
6
6
  "description": "wasm module for swc",
7
- "version": "1.3.43",
7
+ "version": "1.3.45",
8
8
  "license": "Apache-2.0",
9
9
  "repository": {
10
10
  "type": "git",
package/wasm.d.ts CHANGED
@@ -1032,11 +1032,11 @@ export interface BaseModuleConfig {
1032
1032
  *
1033
1033
  * "use strict";
1034
1034
  *
1035
- * function _interopRequireDefault(obj) {
1035
+ * function _interop_require_default(obj) {
1036
1036
  * return obj && obj.__esModule ? obj : { default: obj };
1037
1037
  * }
1038
1038
  *
1039
- * var _foo = _interopRequireDefault(require("foo"));
1039
+ * var _foo = _interop_require_default(require("foo"));
1040
1040
  * var _bar = require("bar");
1041
1041
  *
1042
1042
  * _foo.default;
@@ -1076,7 +1076,7 @@ export interface BaseModuleConfig {
1076
1076
  * - `none`
1077
1077
  *
1078
1078
  * If you know that the imported file has been transformed with a compiler that stores the `default` export on
1079
- * `exports.default` (such as swc or Babel), you can safely omit the `_interopRequireDefault` helper.
1079
+ * `exports.default` (such as swc or Babel), you can safely omit the `_interop_require_default` helper.
1080
1080
  *
1081
1081
  * ```javascript
1082
1082
  * import foo from "foo";
package/wasm.js CHANGED
@@ -3,6 +3,26 @@ imports['__wbindgen_placeholder__'] = module.exports;
3
3
  let wasm;
4
4
  const { TextDecoder, TextEncoder } = require(`util`);
5
5
 
6
+ const heap = new Array(128).fill(undefined);
7
+
8
+ heap.push(undefined, null, true, false);
9
+
10
+ function getObject(idx) { return heap[idx]; }
11
+
12
+ let heap_next = heap.length;
13
+
14
+ function dropObject(idx) {
15
+ if (idx < 132) return;
16
+ heap[idx] = heap_next;
17
+ heap_next = idx;
18
+ }
19
+
20
+ function takeObject(idx) {
21
+ const ret = getObject(idx);
22
+ dropObject(idx);
23
+ return ret;
24
+ }
25
+
6
26
  let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
7
27
 
8
28
  cachedTextDecoder.decode();
@@ -20,12 +40,6 @@ function getStringFromWasm0(ptr, len) {
20
40
  return cachedTextDecoder.decode(getUint8Memory0().subarray(ptr, ptr + len));
21
41
  }
22
42
 
23
- const heap = new Array(128).fill(undefined);
24
-
25
- heap.push(undefined, null, true, false);
26
-
27
- let heap_next = heap.length;
28
-
29
43
  function addHeapObject(obj) {
30
44
  if (heap_next === heap.length) heap.push(heap.length + 1);
31
45
  const idx = heap_next;
@@ -35,20 +49,6 @@ function addHeapObject(obj) {
35
49
  return idx;
36
50
  }
37
51
 
38
- function getObject(idx) { return heap[idx]; }
39
-
40
- function dropObject(idx) {
41
- if (idx < 132) return;
42
- heap[idx] = heap_next;
43
- heap_next = idx;
44
- }
45
-
46
- function takeObject(idx) {
47
- const ret = getObject(idx);
48
- dropObject(idx);
49
- return ret;
50
- }
51
-
52
52
  let WASM_VECTOR_LEN = 0;
53
53
 
54
54
  let cachedTextEncoder = new TextEncoder('utf-8');
@@ -396,6 +396,15 @@ function __wbg_adapter_110(arg0, arg1, arg2, arg3) {
396
396
  wasm.__wbindgen_export_6(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
397
397
  }
398
398
 
399
+ module.exports.__wbindgen_jsval_loose_eq = function(arg0, arg1) {
400
+ const ret = getObject(arg0) == getObject(arg1);
401
+ return ret;
402
+ };
403
+
404
+ module.exports.__wbindgen_object_drop_ref = function(arg0) {
405
+ takeObject(arg0);
406
+ };
407
+
399
408
  module.exports.__wbg_new_f9876326328f45ed = function() {
400
409
  const ret = new Object();
401
410
  return addHeapObject(ret);
@@ -410,10 +419,6 @@ module.exports.__wbg_set_20cbc34131e76824 = function(arg0, arg1, arg2) {
410
419
  getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
411
420
  };
412
421
 
413
- module.exports.__wbindgen_object_drop_ref = function(arg0) {
414
- takeObject(arg0);
415
- };
416
-
417
422
  module.exports.__wbg_new_b525de17f44a8943 = function() {
418
423
  const ret = new Array();
419
424
  return addHeapObject(ret);
@@ -438,6 +443,33 @@ module.exports.__wbindgen_is_string = function(arg0) {
438
443
  return ret;
439
444
  };
440
445
 
446
+ module.exports.__wbindgen_boolean_get = function(arg0) {
447
+ const v = getObject(arg0);
448
+ const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
449
+ return ret;
450
+ };
451
+
452
+ module.exports.__wbindgen_is_object = function(arg0) {
453
+ const val = getObject(arg0);
454
+ const ret = typeof(val) === 'object' && val !== null;
455
+ return ret;
456
+ };
457
+
458
+ module.exports.__wbg_getwithrefkey_15c62c2b8546208d = function(arg0, arg1) {
459
+ const ret = getObject(arg0)[getObject(arg1)];
460
+ return addHeapObject(ret);
461
+ };
462
+
463
+ module.exports.__wbindgen_is_undefined = function(arg0) {
464
+ const ret = getObject(arg0) === undefined;
465
+ return ret;
466
+ };
467
+
468
+ module.exports.__wbindgen_in = function(arg0, arg1) {
469
+ const ret = getObject(arg0) in getObject(arg1);
470
+ return ret;
471
+ };
472
+
441
473
  module.exports.__wbindgen_string_get = function(arg0, arg1) {
442
474
  const obj = getObject(arg1);
443
475
  const ret = typeof(obj) === 'string' ? obj : undefined;
@@ -447,60 +479,62 @@ module.exports.__wbindgen_string_get = function(arg0, arg1) {
447
479
  getInt32Memory0()[arg0 / 4 + 0] = ptr0;
448
480
  };
449
481
 
450
- module.exports.__wbindgen_error_new = function(arg0, arg1) {
451
- const ret = new Error(getStringFromWasm0(arg0, arg1));
452
- return addHeapObject(ret);
453
- };
454
-
455
482
  module.exports.__wbindgen_number_new = function(arg0) {
456
483
  const ret = arg0;
457
484
  return addHeapObject(ret);
458
485
  };
459
486
 
460
- module.exports.__wbindgen_jsval_loose_eq = function(arg0, arg1) {
461
- const ret = getObject(arg0) == getObject(arg1);
487
+ module.exports.__wbindgen_is_null = function(arg0) {
488
+ const ret = getObject(arg0) === null;
462
489
  return ret;
463
490
  };
464
491
 
465
- module.exports.__wbindgen_is_object = function(arg0) {
466
- const val = getObject(arg0);
467
- const ret = typeof(val) === 'object' && val !== null;
468
- return ret;
492
+ module.exports.__wbg_new_9d3a9ce4282a18a8 = function(arg0, arg1) {
493
+ try {
494
+ var state0 = {a: arg0, b: arg1};
495
+ var cb0 = (arg0, arg1) => {
496
+ const a = state0.a;
497
+ state0.a = 0;
498
+ try {
499
+ return __wbg_adapter_110(a, state0.b, arg0, arg1);
500
+ } finally {
501
+ state0.a = a;
502
+ }
503
+ };
504
+ const ret = new Promise(cb0);
505
+ return addHeapObject(ret);
506
+ } finally {
507
+ state0.a = state0.b = 0;
508
+ }
469
509
  };
470
510
 
471
- module.exports.__wbg_entries_4e1315b774245952 = function(arg0) {
472
- const ret = Object.entries(getObject(arg0));
511
+ module.exports.__wbg_next_88560ec06a094dea = function() { return handleError(function (arg0) {
512
+ const ret = getObject(arg0).next();
473
513
  return addHeapObject(ret);
474
- };
514
+ }, arguments) };
475
515
 
476
- module.exports.__wbg_length_e498fbc24f9c1d4f = function(arg0) {
477
- const ret = getObject(arg0).length;
516
+ module.exports.__wbg_done_1ebec03bbd919843 = function(arg0) {
517
+ const ret = getObject(arg0).done;
478
518
  return ret;
479
519
  };
480
520
 
481
- module.exports.__wbg_get_27fe3dac1c4d0224 = function(arg0, arg1) {
482
- const ret = getObject(arg0)[arg1 >>> 0];
521
+ module.exports.__wbg_value_6ac8da5cc5b3efda = function(arg0) {
522
+ const ret = getObject(arg0).value;
483
523
  return addHeapObject(ret);
484
524
  };
485
525
 
486
- module.exports.__wbg_getwithrefkey_15c62c2b8546208d = function(arg0, arg1) {
487
- const ret = getObject(arg0)[getObject(arg1)];
526
+ module.exports.__wbg_get_27fe3dac1c4d0224 = function(arg0, arg1) {
527
+ const ret = getObject(arg0)[arg1 >>> 0];
488
528
  return addHeapObject(ret);
489
529
  };
490
530
 
491
- module.exports.__wbindgen_is_undefined = function(arg0) {
492
- const ret = getObject(arg0) === undefined;
493
- return ret;
494
- };
495
-
496
- module.exports.__wbindgen_in = function(arg0, arg1) {
497
- const ret = getObject(arg0) in getObject(arg1);
498
- return ret;
531
+ module.exports.__wbg_entries_4e1315b774245952 = function(arg0) {
532
+ const ret = Object.entries(getObject(arg0));
533
+ return addHeapObject(ret);
499
534
  };
500
535
 
501
- module.exports.__wbindgen_boolean_get = function(arg0) {
502
- const v = getObject(arg0);
503
- const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
536
+ module.exports.__wbg_length_e498fbc24f9c1d4f = function(arg0) {
537
+ const ret = getObject(arg0).length;
504
538
  return ret;
505
539
  };
506
540
 
@@ -553,45 +587,11 @@ module.exports.__wbindgen_bigint_from_u64 = function(arg0) {
553
587
  return addHeapObject(ret);
554
588
  };
555
589
 
556
- module.exports.__wbg_next_88560ec06a094dea = function() { return handleError(function (arg0) {
557
- const ret = getObject(arg0).next();
558
- return addHeapObject(ret);
559
- }, arguments) };
560
-
561
- module.exports.__wbg_done_1ebec03bbd919843 = function(arg0) {
562
- const ret = getObject(arg0).done;
563
- return ret;
564
- };
565
-
566
- module.exports.__wbg_value_6ac8da5cc5b3efda = function(arg0) {
567
- const ret = getObject(arg0).value;
590
+ module.exports.__wbindgen_error_new = function(arg0, arg1) {
591
+ const ret = new Error(getStringFromWasm0(arg0, arg1));
568
592
  return addHeapObject(ret);
569
593
  };
570
594
 
571
- module.exports.__wbindgen_is_null = function(arg0) {
572
- const ret = getObject(arg0) === null;
573
- return ret;
574
- };
575
-
576
- module.exports.__wbg_new_9d3a9ce4282a18a8 = function(arg0, arg1) {
577
- try {
578
- var state0 = {a: arg0, b: arg1};
579
- var cb0 = (arg0, arg1) => {
580
- const a = state0.a;
581
- state0.a = 0;
582
- try {
583
- return __wbg_adapter_110(a, state0.b, arg0, arg1);
584
- } finally {
585
- state0.a = a;
586
- }
587
- };
588
- const ret = new Promise(cb0);
589
- return addHeapObject(ret);
590
- } finally {
591
- state0.a = state0.b = 0;
592
- }
593
- };
594
-
595
595
  module.exports.__wbg_call_9495de66fdbe016b = function() { return handleError(function (arg0, arg1, arg2) {
596
596
  const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
597
597
  return addHeapObject(ret);
@@ -706,14 +706,6 @@ module.exports.__wbg_set_17499e8aa4003ebd = function(arg0, arg1, arg2) {
706
706
  getObject(arg0).set(getObject(arg1), arg2 >>> 0);
707
707
  };
708
708
 
709
- module.exports.__wbindgen_debug_string = function(arg0, arg1) {
710
- const ret = debugString(getObject(arg1));
711
- const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
712
- const len0 = WASM_VECTOR_LEN;
713
- getInt32Memory0()[arg0 / 4 + 1] = len0;
714
- getInt32Memory0()[arg0 / 4 + 0] = ptr0;
715
- };
716
-
717
709
  module.exports.__wbg_instanceof_Uint8Array_01cebe79ca606cca = function(arg0) {
718
710
  let result;
719
711
  try {
@@ -744,6 +736,14 @@ module.exports.__wbg_String_91fba7ded13ba54c = function(arg0, arg1) {
744
736
  getInt32Memory0()[arg0 / 4 + 0] = ptr0;
745
737
  };
746
738
 
739
+ module.exports.__wbindgen_debug_string = function(arg0, arg1) {
740
+ const ret = debugString(getObject(arg1));
741
+ const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
742
+ const len0 = WASM_VECTOR_LEN;
743
+ getInt32Memory0()[arg0 / 4 + 1] = len0;
744
+ getInt32Memory0()[arg0 / 4 + 0] = ptr0;
745
+ };
746
+
747
747
  module.exports.__wbindgen_throw = function(arg0, arg1) {
748
748
  throw new Error(getStringFromWasm0(arg0, arg1));
749
749
  };
@@ -768,8 +768,8 @@ module.exports.__wbindgen_cb_drop = function(arg0) {
768
768
  return ret;
769
769
  };
770
770
 
771
- module.exports.__wbindgen_closure_wrapper18848 = function(arg0, arg1, arg2) {
772
- const ret = makeMutClosure(arg0, arg1, 241, __wbg_adapter_50);
771
+ module.exports.__wbindgen_closure_wrapper18920 = function(arg0, arg1, arg2) {
772
+ const ret = makeMutClosure(arg0, arg1, 240, __wbg_adapter_50);
773
773
  return addHeapObject(ret);
774
774
  };
775
775
 
package/wasm_bg.wasm CHANGED
Binary file