@swc/wasm 1.3.18 → 1.3.20

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.
Files changed (4) hide show
  1. package/package.json +1 -1
  2. package/wasm.d.ts +47 -42
  3. package/wasm.js +370 -70
  4. package/wasm_bg.wasm +0 -0
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.18",
7
+ "version": "1.3.20",
8
8
  "license": "Apache-2.0",
9
9
  "repository": {
10
10
  "type": "git",
package/wasm.d.ts CHANGED
@@ -1,6 +1,42 @@
1
1
  /* tslint:disable */
2
2
  /* eslint-disable */
3
3
 
4
+ export function minify(src: string, opts?: JsMinifyOptions): Promise<Output>;
5
+ export function minifySync(code: string, opts?: JsMinifyOptions): Output;
6
+
7
+ export function parse(src: string, options: ParseOptions & {
8
+ isModule: false;
9
+ }): Promise<Script>;
10
+ export function parse(src: string, options?: ParseOptions): Promise<Module>;
11
+ export function parseSync(src: string, options: ParseOptions & {
12
+ isModule: false;
13
+ }): Script;
14
+ export function parseSync(src: string, options?: ParseOptions): Module;
15
+
16
+ export function print(m: Program, options?: Options): Promise<Output>;
17
+ export function printSync(m: Program, options?: Options): Output
18
+
19
+ /**
20
+ * Note: this interface currently does not do _actual_ async work, only provides
21
+ * a corresponding async interfaces to the `@swc/core`'s interface.
22
+ */
23
+ export function transform(
24
+ code: string | Program,
25
+ options?: Options,
26
+ experimental_plugin_bytes_resolver?: any
27
+ ): Promise<Output>;
28
+ /**
29
+ * @param {string} code
30
+ * @param {Options} opts
31
+ * @param {Record<string, ArrayBuffer>} experimental_plugin_bytes_resolver An object contains bytes array for the plugin
32
+ * specified in config. Key of record represents the name of the plugin specified in config. Note this is an experimental
33
+ * interface, likely will change.
34
+ * @returns {Output}
35
+ */
36
+ export function transformSync(code: string | Program, opts?: Options, experimental_plugin_bytes_resolver?: any): Output;
37
+
38
+
39
+
4
40
  export interface Plugin {
5
41
  (module: Program): Program;
6
42
  }
@@ -353,11 +389,11 @@ export interface TerserCompressOptions {
353
389
  export interface TerserMangleOptions {
354
390
  props?: TerserManglePropertiesOptions,
355
391
 
356
- top_level?: boolean,
392
+ toplevel?: boolean,
357
393
 
358
- keep_class_names?: boolean,
394
+ keep_classnames?: boolean,
359
395
 
360
- keep_fn_names?: boolean,
396
+ keep_fnames?: boolean,
361
397
 
362
398
  keep_private_props?: boolean,
363
399
 
@@ -667,7 +703,7 @@ export interface JscConfig {
667
703
  baseUrl?: string
668
704
 
669
705
  paths?: {
670
- [from: string]: [string]
706
+ [from: string]: string[]
671
707
  }
672
708
 
673
709
  minify?: JsMinifyOptions;
@@ -896,7 +932,7 @@ export interface GlobalPassOption {
896
932
  envs?: string[];
897
933
  }
898
934
 
899
- export type ModuleConfig = Es6Config | CommonJsConfig | UmdConfig | AmdConfig | NodeNextConfig;
935
+ export type ModuleConfig = Es6Config | CommonJsConfig | UmdConfig | AmdConfig | NodeNextConfig | SystemjsConfig;
900
936
 
901
937
  export interface BaseModuleConfig {
902
938
  /**
@@ -1057,6 +1093,8 @@ export interface BaseModuleConfig {
1057
1093
  * If set to true, dynamic imports will be preserved.
1058
1094
  */
1059
1095
  ignoreDynamic?: boolean;
1096
+ allowTopLevelThis?: boolean;
1097
+ preserveImportMeta?: boolean;
1060
1098
  }
1061
1099
 
1062
1100
  export interface Es6Config extends BaseModuleConfig {
@@ -1080,7 +1118,10 @@ export interface AmdConfig extends BaseModuleConfig {
1080
1118
  type: "amd";
1081
1119
  moduleId?: string;
1082
1120
  }
1083
-
1121
+ export interface SystemjsConfig {
1122
+ type: "systemjs";
1123
+ allowTopLevelThis?: boolean;
1124
+ }
1084
1125
  export interface Output {
1085
1126
  /**
1086
1127
  * Transformed code
@@ -2789,39 +2830,3 @@ export interface Invalid extends Node, HasSpan {
2789
2830
  }
2790
2831
 
2791
2832
 
2792
-
2793
- export function minify(src: string, opts?: JsMinifyOptions): Promise<Output>;
2794
- export function minifySync(code: string, opts?: JsMinifyOptions): Output;
2795
-
2796
- export function parse(src: string, options: ParseOptions & {
2797
- isModule: false;
2798
- }): Promise<Script>;
2799
- export function parse(src: string, options?: ParseOptions): Promise<Module>;
2800
- export function parseSync(src: string, options: ParseOptions & {
2801
- isModule: false;
2802
- }): Script;
2803
- export function parseSync(src: string, options?: ParseOptions): Module;
2804
-
2805
- export function print(m: Program, options?: Options): Promise<Output>;
2806
- export function printSync(m: Program, options?: Options): Output
2807
-
2808
- /**
2809
- * Note: this interface currently does not do _actual_ async work, only provides
2810
- * a corresponding async interfaces to the `@swc/core`'s interface.
2811
- */
2812
- export function transform(
2813
- code: string | Program,
2814
- options?: Options,
2815
- experimental_plugin_bytes_resolver?: any
2816
- ): Promise<Output>;
2817
- /**
2818
- * @param {string} code
2819
- * @param {Options} opts
2820
- * @param {Record<string, ArrayBuffer>} experimental_plugin_bytes_resolver An object contains bytes array for the plugin
2821
- * specified in config. Key of record represents the name of the plugin specified in config. Note this is an experimental
2822
- * interface, likely will change.
2823
- * @returns {Output}
2824
- */
2825
- export function transformSync(code: string | Program, opts?: Options, experimental_plugin_bytes_resolver?: any): Output;
2826
-
2827
-
package/wasm.js CHANGED
@@ -1,16 +1,42 @@
1
1
  let imports = {};
2
2
  imports['__wbindgen_placeholder__'] = module.exports;
3
3
  let wasm;
4
- const { TextEncoder, TextDecoder } = require(`util`);
4
+ const { TextDecoder, TextEncoder } = require(`util`);
5
+
6
+ let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
7
+
8
+ cachedTextDecoder.decode();
9
+
10
+ let cachedUint8Memory0 = new Uint8Array();
11
+
12
+ function getUint8Memory0() {
13
+ if (cachedUint8Memory0.byteLength === 0) {
14
+ cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);
15
+ }
16
+ return cachedUint8Memory0;
17
+ }
18
+
19
+ function getStringFromWasm0(ptr, len) {
20
+ return cachedTextDecoder.decode(getUint8Memory0().subarray(ptr, ptr + len));
21
+ }
5
22
 
6
23
  const heap = new Array(32).fill(undefined);
7
24
 
8
25
  heap.push(undefined, null, true, false);
9
26
 
10
- function getObject(idx) { return heap[idx]; }
11
-
12
27
  let heap_next = heap.length;
13
28
 
29
+ function addHeapObject(obj) {
30
+ if (heap_next === heap.length) heap.push(heap.length + 1);
31
+ const idx = heap_next;
32
+ heap_next = heap[idx];
33
+
34
+ heap[idx] = obj;
35
+ return idx;
36
+ }
37
+
38
+ function getObject(idx) { return heap[idx]; }
39
+
14
40
  function dropObject(idx) {
15
41
  if (idx < 36) return;
16
42
  heap[idx] = heap_next;
@@ -25,15 +51,6 @@ function takeObject(idx) {
25
51
 
26
52
  let WASM_VECTOR_LEN = 0;
27
53
 
28
- let cachedUint8Memory0 = new Uint8Array();
29
-
30
- function getUint8Memory0() {
31
- if (cachedUint8Memory0.byteLength === 0) {
32
- cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);
33
- }
34
- return cachedUint8Memory0;
35
- }
36
-
37
54
  let cachedTextEncoder = new TextEncoder('utf-8');
38
55
 
39
56
  const encodeString = (typeof cachedTextEncoder.encodeInto === 'function'
@@ -100,21 +117,87 @@ function getInt32Memory0() {
100
117
  return cachedInt32Memory0;
101
118
  }
102
119
 
103
- let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
104
-
105
- cachedTextDecoder.decode();
120
+ let cachedBigInt64Memory0 = new BigInt64Array();
106
121
 
107
- function getStringFromWasm0(ptr, len) {
108
- return cachedTextDecoder.decode(getUint8Memory0().subarray(ptr, ptr + len));
122
+ function getBigInt64Memory0() {
123
+ if (cachedBigInt64Memory0.byteLength === 0) {
124
+ cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);
125
+ }
126
+ return cachedBigInt64Memory0;
109
127
  }
110
128
 
111
- function addHeapObject(obj) {
112
- if (heap_next === heap.length) heap.push(heap.length + 1);
113
- const idx = heap_next;
114
- heap_next = heap[idx];
129
+ let cachedFloat64Memory0 = new Float64Array();
115
130
 
116
- heap[idx] = obj;
117
- return idx;
131
+ function getFloat64Memory0() {
132
+ if (cachedFloat64Memory0.byteLength === 0) {
133
+ cachedFloat64Memory0 = new Float64Array(wasm.memory.buffer);
134
+ }
135
+ return cachedFloat64Memory0;
136
+ }
137
+
138
+ function debugString(val) {
139
+ // primitive types
140
+ const type = typeof val;
141
+ if (type == 'number' || type == 'boolean' || val == null) {
142
+ return `${val}`;
143
+ }
144
+ if (type == 'string') {
145
+ return `"${val}"`;
146
+ }
147
+ if (type == 'symbol') {
148
+ const description = val.description;
149
+ if (description == null) {
150
+ return 'Symbol';
151
+ } else {
152
+ return `Symbol(${description})`;
153
+ }
154
+ }
155
+ if (type == 'function') {
156
+ const name = val.name;
157
+ if (typeof name == 'string' && name.length > 0) {
158
+ return `Function(${name})`;
159
+ } else {
160
+ return 'Function';
161
+ }
162
+ }
163
+ // objects
164
+ if (Array.isArray(val)) {
165
+ const length = val.length;
166
+ let debug = '[';
167
+ if (length > 0) {
168
+ debug += debugString(val[0]);
169
+ }
170
+ for(let i = 1; i < length; i++) {
171
+ debug += ', ' + debugString(val[i]);
172
+ }
173
+ debug += ']';
174
+ return debug;
175
+ }
176
+ // Test for built-in
177
+ const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
178
+ let className;
179
+ if (builtInMatches.length > 1) {
180
+ className = builtInMatches[1];
181
+ } else {
182
+ // Failed to match the standard '[object ClassName]'
183
+ return toString.call(val);
184
+ }
185
+ if (className == 'Object') {
186
+ // we're a user defined class or Object
187
+ // JSON.stringify avoids problems with cycles, and is generally much
188
+ // easier than looping through ownProperties of `val`.
189
+ try {
190
+ return 'Object(' + JSON.stringify(val) + ')';
191
+ } catch (_) {
192
+ return 'Object';
193
+ }
194
+ }
195
+ // errors
196
+ if (val instanceof Error) {
197
+ return `${val.name}: ${val.message}\n${val.stack}`;
198
+ }
199
+ // TODO we could test for more things here, like `Set`s and `Map`s.
200
+ return className;
118
201
  }
119
202
 
120
203
  function makeMutClosure(arg0, arg1, dtor, f) {
@@ -141,7 +224,7 @@ function makeMutClosure(arg0, arg1, dtor, f) {
141
224
 
142
225
  return real;
143
226
  }
144
- function __wbg_adapter_22(arg0, arg1, arg2) {
227
+ function __wbg_adapter_50(arg0, arg1, arg2) {
145
228
  wasm.__wbindgen_export_3(arg0, arg1, addHeapObject(arg2));
146
229
  }
147
230
 
@@ -210,13 +293,12 @@ module.exports.parse = function(s, opts) {
210
293
  /**
211
294
  * @param {any} s
212
295
  * @param {any} opts
213
- * @param {any} experimental_plugin_bytes_resolver
214
296
  * @returns {any}
215
297
  */
216
- module.exports.transformSync = function(s, opts, experimental_plugin_bytes_resolver) {
298
+ module.exports.printSync = function(s, opts) {
217
299
  try {
218
300
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
219
- wasm.transformSync(retptr, addHeapObject(s), addHeapObject(opts), addHeapObject(experimental_plugin_bytes_resolver));
301
+ wasm.printSync(retptr, addHeapObject(s), addHeapObject(opts));
220
302
  var r0 = getInt32Memory0()[retptr / 4 + 0];
221
303
  var r1 = getInt32Memory0()[retptr / 4 + 1];
222
304
  var r2 = getInt32Memory0()[retptr / 4 + 2];
@@ -232,23 +314,23 @@ module.exports.transformSync = function(s, opts, experimental_plugin_bytes_resol
232
314
  /**
233
315
  * @param {any} s
234
316
  * @param {any} opts
235
- * @param {any} experimental_plugin_bytes_resolver
236
317
  * @returns {Promise<any>}
237
318
  */
238
- module.exports.transform = function(s, opts, experimental_plugin_bytes_resolver) {
239
- const ret = wasm.transform(addHeapObject(s), addHeapObject(opts), addHeapObject(experimental_plugin_bytes_resolver));
319
+ module.exports.print = function(s, opts) {
320
+ const ret = wasm.print(addHeapObject(s), addHeapObject(opts));
240
321
  return takeObject(ret);
241
322
  };
242
323
 
243
324
  /**
244
325
  * @param {any} s
245
326
  * @param {any} opts
327
+ * @param {any} experimental_plugin_bytes_resolver
246
328
  * @returns {any}
247
329
  */
248
- module.exports.printSync = function(s, opts) {
330
+ module.exports.transformSync = function(s, opts, experimental_plugin_bytes_resolver) {
249
331
  try {
250
332
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
251
- wasm.printSync(retptr, addHeapObject(s), addHeapObject(opts));
333
+ wasm.transformSync(retptr, addHeapObject(s), addHeapObject(opts), addHeapObject(experimental_plugin_bytes_resolver));
252
334
  var r0 = getInt32Memory0()[retptr / 4 + 0];
253
335
  var r1 = getInt32Memory0()[retptr / 4 + 1];
254
336
  var r2 = getInt32Memory0()[retptr / 4 + 2];
@@ -264,10 +346,11 @@ module.exports.printSync = function(s, opts) {
264
346
  /**
265
347
  * @param {any} s
266
348
  * @param {any} opts
349
+ * @param {any} experimental_plugin_bytes_resolver
267
350
  * @returns {Promise<any>}
268
351
  */
269
- module.exports.print = function(s, opts) {
270
- const ret = wasm.print(addHeapObject(s), addHeapObject(opts));
352
+ module.exports.transform = function(s, opts, experimental_plugin_bytes_resolver) {
353
+ const ret = wasm.transform(addHeapObject(s), addHeapObject(opts), addHeapObject(experimental_plugin_bytes_resolver));
271
354
  return takeObject(ret);
272
355
  };
273
356
 
@@ -286,41 +369,45 @@ function handleError(f, args) {
286
369
  wasm.__wbindgen_export_5(addHeapObject(e));
287
370
  }
288
371
  }
289
- function __wbg_adapter_45(arg0, arg1, arg2, arg3) {
372
+ function __wbg_adapter_107(arg0, arg1, arg2, arg3) {
290
373
  wasm.__wbindgen_export_6(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
291
374
  }
292
375
 
376
+ module.exports.__wbg_new_0b9bfdd97583284e = function() {
377
+ const ret = new Object();
378
+ return addHeapObject(ret);
379
+ };
380
+
381
+ module.exports.__wbindgen_string_new = function(arg0, arg1) {
382
+ const ret = getStringFromWasm0(arg0, arg1);
383
+ return addHeapObject(ret);
384
+ };
385
+
386
+ module.exports.__wbg_set_20cbc34131e76824 = function(arg0, arg1, arg2) {
387
+ getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
388
+ };
389
+
293
390
  module.exports.__wbindgen_object_drop_ref = function(arg0) {
294
391
  takeObject(arg0);
295
392
  };
296
393
 
297
- module.exports.__wbg_new_9962f939219f1820 = function(arg0, arg1) {
298
- try {
299
- var state0 = {a: arg0, b: arg1};
300
- var cb0 = (arg0, arg1) => {
301
- const a = state0.a;
302
- state0.a = 0;
303
- try {
304
- return __wbg_adapter_45(a, state0.b, arg0, arg1);
305
- } finally {
306
- state0.a = a;
307
- }
308
- };
309
- const ret = new Promise(cb0);
310
- return addHeapObject(ret);
311
- } finally {
312
- state0.a = state0.b = 0;
313
- }
394
+ module.exports.__wbindgen_number_new = function(arg0) {
395
+ const ret = arg0;
396
+ return addHeapObject(ret);
314
397
  };
315
398
 
316
- module.exports.__wbindgen_is_null = function(arg0) {
317
- const ret = getObject(arg0) === null;
318
- return ret;
399
+ module.exports.__wbg_new_1d9a920c6bfc44a8 = function() {
400
+ const ret = new Array();
401
+ return addHeapObject(ret);
319
402
  };
320
403
 
321
- module.exports.__wbindgen_is_undefined = function(arg0) {
322
- const ret = getObject(arg0) === undefined;
323
- return ret;
404
+ module.exports.__wbg_set_a68214f35c417fa9 = function(arg0, arg1, arg2) {
405
+ getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
406
+ };
407
+
408
+ module.exports.__wbg_set_933729cf5b66ac11 = function(arg0, arg1, arg2) {
409
+ const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
410
+ return addHeapObject(ret);
324
411
  };
325
412
 
326
413
  module.exports.__wbindgen_is_string = function(arg0) {
@@ -328,6 +415,16 @@ module.exports.__wbindgen_is_string = function(arg0) {
328
415
  return ret;
329
416
  };
330
417
 
418
+ module.exports.__wbindgen_error_new = function(arg0, arg1) {
419
+ const ret = new Error(getStringFromWasm0(arg0, arg1));
420
+ return addHeapObject(ret);
421
+ };
422
+
423
+ module.exports.__wbg_new_268f7b7dd3430798 = function() {
424
+ const ret = new Map();
425
+ return addHeapObject(ret);
426
+ };
427
+
331
428
  module.exports.__wbindgen_string_get = function(arg0, arg1) {
332
429
  const obj = getObject(arg1);
333
430
  const ret = typeof(obj) === 'string' ? obj : undefined;
@@ -337,17 +434,99 @@ module.exports.__wbindgen_string_get = function(arg0, arg1) {
337
434
  getInt32Memory0()[arg0 / 4 + 0] = ptr0;
338
435
  };
339
436
 
340
- module.exports.__wbindgen_json_serialize = function(arg0, arg1) {
437
+ module.exports.__wbindgen_jsval_loose_eq = function(arg0, arg1) {
438
+ const ret = getObject(arg0) == getObject(arg1);
439
+ return ret;
440
+ };
441
+
442
+ module.exports.__wbindgen_is_object = function(arg0) {
443
+ const val = getObject(arg0);
444
+ const ret = typeof(val) === 'object' && val !== null;
445
+ return ret;
446
+ };
447
+
448
+ module.exports.__wbg_entries_65a76a413fc91037 = function(arg0) {
449
+ const ret = Object.entries(getObject(arg0));
450
+ return addHeapObject(ret);
451
+ };
452
+
453
+ module.exports.__wbg_length_6e3bbe7c8bd4dbd8 = function(arg0) {
454
+ const ret = getObject(arg0).length;
455
+ return ret;
456
+ };
457
+
458
+ module.exports.__wbg_get_57245cc7d7c7619d = function(arg0, arg1) {
459
+ const ret = getObject(arg0)[arg1 >>> 0];
460
+ return addHeapObject(ret);
461
+ };
462
+
463
+ module.exports.__wbg_getwithrefkey_15c62c2b8546208d = function(arg0, arg1) {
464
+ const ret = getObject(arg0)[getObject(arg1)];
465
+ return addHeapObject(ret);
466
+ };
467
+
468
+ module.exports.__wbindgen_is_undefined = function(arg0) {
469
+ const ret = getObject(arg0) === undefined;
470
+ return ret;
471
+ };
472
+
473
+ module.exports.__wbindgen_in = function(arg0, arg1) {
474
+ const ret = getObject(arg0) in getObject(arg1);
475
+ return ret;
476
+ };
477
+
478
+ module.exports.__wbindgen_boolean_get = function(arg0) {
479
+ const v = getObject(arg0);
480
+ const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
481
+ return ret;
482
+ };
483
+
484
+ module.exports.__wbindgen_is_bigint = function(arg0) {
485
+ const ret = typeof(getObject(arg0)) === 'bigint';
486
+ return ret;
487
+ };
488
+
489
+ module.exports.__wbindgen_bigint_get_as_i64 = function(arg0, arg1) {
490
+ const v = getObject(arg1);
491
+ const ret = typeof(v) === 'bigint' ? v : undefined;
492
+ getBigInt64Memory0()[arg0 / 8 + 1] = isLikeNone(ret) ? 0n : ret;
493
+ getInt32Memory0()[arg0 / 4 + 0] = !isLikeNone(ret);
494
+ };
495
+
496
+ module.exports.__wbindgen_bigint_from_i64 = function(arg0) {
497
+ const ret = arg0;
498
+ return addHeapObject(ret);
499
+ };
500
+
501
+ module.exports.__wbindgen_jsval_eq = function(arg0, arg1) {
502
+ const ret = getObject(arg0) === getObject(arg1);
503
+ return ret;
504
+ };
505
+
506
+ module.exports.__wbindgen_number_get = function(arg0, arg1) {
341
507
  const obj = getObject(arg1);
342
- const ret = JSON.stringify(obj === undefined ? null : obj);
343
- const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
344
- const len0 = WASM_VECTOR_LEN;
345
- getInt32Memory0()[arg0 / 4 + 1] = len0;
346
- getInt32Memory0()[arg0 / 4 + 0] = ptr0;
508
+ const ret = typeof(obj) === 'number' ? obj : undefined;
509
+ getFloat64Memory0()[arg0 / 8 + 1] = isLikeNone(ret) ? 0 : ret;
510
+ getInt32Memory0()[arg0 / 4 + 0] = !isLikeNone(ret);
511
+ };
512
+
513
+ module.exports.__wbg_isSafeInteger_dfa0593e8d7ac35a = function(arg0) {
514
+ const ret = Number.isSafeInteger(getObject(arg0));
515
+ return ret;
516
+ };
517
+
518
+ module.exports.__wbg_isArray_27c46c67f498e15d = function(arg0) {
519
+ const ret = Array.isArray(getObject(arg0));
520
+ return ret;
521
+ };
522
+
523
+ module.exports.__wbg_iterator_6f9d4f28845f426c = function() {
524
+ const ret = Symbol.iterator;
525
+ return addHeapObject(ret);
347
526
  };
348
527
 
349
- module.exports.__wbindgen_json_parse = function(arg0, arg1) {
350
- const ret = JSON.parse(getStringFromWasm0(arg0, arg1));
528
+ module.exports.__wbindgen_bigint_from_u64 = function(arg0) {
529
+ const ret = BigInt.asUintN(64, arg0);
351
530
  return addHeapObject(ret);
352
531
  };
353
532
 
@@ -356,11 +535,45 @@ module.exports.__wbg_call_168da88779e35f61 = function() { return handleError(fun
356
535
  return addHeapObject(ret);
357
536
  }, arguments) };
358
537
 
359
- module.exports.__wbindgen_string_new = function(arg0, arg1) {
360
- const ret = getStringFromWasm0(arg0, arg1);
538
+ module.exports.__wbindgen_is_null = function(arg0) {
539
+ const ret = getObject(arg0) === null;
540
+ return ret;
541
+ };
542
+
543
+ module.exports.__wbg_next_aaef7c8aa5e212ac = function() { return handleError(function (arg0) {
544
+ const ret = getObject(arg0).next();
545
+ return addHeapObject(ret);
546
+ }, arguments) };
547
+
548
+ module.exports.__wbg_done_1b73b0672e15f234 = function(arg0) {
549
+ const ret = getObject(arg0).done;
550
+ return ret;
551
+ };
552
+
553
+ module.exports.__wbg_value_1ccc36bc03462d71 = function(arg0) {
554
+ const ret = getObject(arg0).value;
361
555
  return addHeapObject(ret);
362
556
  };
363
557
 
558
+ module.exports.__wbg_new_9962f939219f1820 = function(arg0, arg1) {
559
+ try {
560
+ var state0 = {a: arg0, b: arg1};
561
+ var cb0 = (arg0, arg1) => {
562
+ const a = state0.a;
563
+ state0.a = 0;
564
+ try {
565
+ return __wbg_adapter_107(a, state0.b, arg0, arg1);
566
+ } finally {
567
+ state0.a = a;
568
+ }
569
+ };
570
+ const ret = new Promise(cb0);
571
+ return addHeapObject(ret);
572
+ } finally {
573
+ state0.a = state0.b = 0;
574
+ }
575
+ };
576
+
364
577
  module.exports.__wbg_new0_a57059d72c5b7aee = function() {
365
578
  const ret = new Date();
366
579
  return addHeapObject(ret);
@@ -395,6 +608,93 @@ if (arg0 !== 0) { wasm.__wbindgen_export_4(arg0, arg1); }
395
608
  console.error(v0);
396
609
  };
397
610
 
611
+ module.exports.__wbg_get_765201544a2b6869 = function() { return handleError(function (arg0, arg1) {
612
+ const ret = Reflect.get(getObject(arg0), getObject(arg1));
613
+ return addHeapObject(ret);
614
+ }, arguments) };
615
+
616
+ module.exports.__wbindgen_is_function = function(arg0) {
617
+ const ret = typeof(getObject(arg0)) === 'function';
618
+ return ret;
619
+ };
620
+
621
+ module.exports.__wbg_call_97ae9d8645dc388b = function() { return handleError(function (arg0, arg1) {
622
+ const ret = getObject(arg0).call(getObject(arg1));
623
+ return addHeapObject(ret);
624
+ }, arguments) };
625
+
626
+ module.exports.__wbg_next_579e583d33566a86 = function(arg0) {
627
+ const ret = getObject(arg0).next;
628
+ return addHeapObject(ret);
629
+ };
630
+
631
+ module.exports.__wbg_length_9e1ae1900cb0fbd5 = function(arg0) {
632
+ const ret = getObject(arg0).length;
633
+ return ret;
634
+ };
635
+
636
+ module.exports.__wbindgen_memory = function() {
637
+ const ret = wasm.memory;
638
+ return addHeapObject(ret);
639
+ };
640
+
641
+ module.exports.__wbg_buffer_3f3d764d4747d564 = function(arg0) {
642
+ const ret = getObject(arg0).buffer;
643
+ return addHeapObject(ret);
644
+ };
645
+
646
+ module.exports.__wbg_new_8c3f0052272a457a = function(arg0) {
647
+ const ret = new Uint8Array(getObject(arg0));
648
+ return addHeapObject(ret);
649
+ };
650
+
651
+ module.exports.__wbg_set_83db9690f9353e79 = function(arg0, arg1, arg2) {
652
+ getObject(arg0).set(getObject(arg1), arg2 >>> 0);
653
+ };
654
+
655
+ module.exports.__wbg_instanceof_Uint8Array_971eeda69eb75003 = function(arg0) {
656
+ let result;
657
+ try {
658
+ result = getObject(arg0) instanceof Uint8Array;
659
+ } catch {
660
+ result = false;
661
+ }
662
+ const ret = result;
663
+ return ret;
664
+ };
665
+
666
+ module.exports.__wbg_instanceof_ArrayBuffer_e5e48f4762c5610b = function(arg0) {
667
+ let result;
668
+ try {
669
+ result = getObject(arg0) instanceof ArrayBuffer;
670
+ } catch {
671
+ result = false;
672
+ }
673
+ const ret = result;
674
+ return ret;
675
+ };
676
+
677
+ module.exports.__wbg_String_91fba7ded13ba54c = function(arg0, arg1) {
678
+ const ret = String(getObject(arg1));
679
+ const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
680
+ const len0 = WASM_VECTOR_LEN;
681
+ getInt32Memory0()[arg0 / 4 + 1] = len0;
682
+ getInt32Memory0()[arg0 / 4 + 0] = ptr0;
683
+ };
684
+
685
+ module.exports.__wbindgen_object_clone_ref = function(arg0) {
686
+ const ret = getObject(arg0);
687
+ return addHeapObject(ret);
688
+ };
689
+
690
+ module.exports.__wbindgen_debug_string = function(arg0, arg1) {
691
+ const ret = debugString(getObject(arg1));
692
+ const ptr0 = passStringToWasm0(ret, wasm.__wbindgen_export_0, wasm.__wbindgen_export_1);
693
+ const len0 = WASM_VECTOR_LEN;
694
+ getInt32Memory0()[arg0 / 4 + 1] = len0;
695
+ getInt32Memory0()[arg0 / 4 + 0] = ptr0;
696
+ };
697
+
398
698
  module.exports.__wbindgen_throw = function(arg0, arg1) {
399
699
  throw new Error(getStringFromWasm0(arg0, arg1));
400
700
  };
@@ -419,8 +719,8 @@ module.exports.__wbg_then_11f7a54d67b4bfad = function(arg0, arg1) {
419
719
  return addHeapObject(ret);
420
720
  };
421
721
 
422
- module.exports.__wbindgen_closure_wrapper18857 = function(arg0, arg1, arg2) {
423
- const ret = makeMutClosure(arg0, arg1, 223, __wbg_adapter_22);
722
+ module.exports.__wbindgen_closure_wrapper18940 = function(arg0, arg1, arg2) {
723
+ const ret = makeMutClosure(arg0, arg1, 226, __wbg_adapter_50);
424
724
  return addHeapObject(ret);
425
725
  };
426
726
 
package/wasm_bg.wasm CHANGED
Binary file