@acala-network/chopsticks-executor 0.9.2-6 → 0.9.3-1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/chopsticks_executor.js +104 -104
- package/dist/cjs/index.js +5 -61
- package/dist/esm/chopsticks_executor.js +105 -105
- package/dist/esm/index.js +5 -14
- package/package.json +3 -3
|
@@ -164,29 +164,7 @@ heap.push(undefined, null, true, false);
|
|
|
164
164
|
function getObject(idx) {
|
|
165
165
|
return heap[idx];
|
|
166
166
|
}
|
|
167
|
-
var
|
|
168
|
-
function dropObject(idx) {
|
|
169
|
-
if (idx < 132) return;
|
|
170
|
-
heap[idx] = heap_next;
|
|
171
|
-
heap_next = idx;
|
|
172
|
-
}
|
|
173
|
-
function takeObject(idx) {
|
|
174
|
-
var ret = getObject(idx);
|
|
175
|
-
dropObject(idx);
|
|
176
|
-
return ret;
|
|
177
|
-
}
|
|
178
|
-
var cachedTextDecoder = typeof TextDecoder !== "undefined" ? new TextDecoder("utf-8", {
|
|
179
|
-
ignoreBOM: true,
|
|
180
|
-
fatal: true
|
|
181
|
-
}) : {
|
|
182
|
-
decode: function() {
|
|
183
|
-
throw Error("TextDecoder not available");
|
|
184
|
-
}
|
|
185
|
-
};
|
|
186
|
-
if (typeof TextDecoder !== "undefined") {
|
|
187
|
-
cachedTextDecoder.decode();
|
|
188
|
-
}
|
|
189
|
-
;
|
|
167
|
+
var WASM_VECTOR_LEN = 0;
|
|
190
168
|
var cachedUint8Memory0 = null;
|
|
191
169
|
function getUint8Memory0() {
|
|
192
170
|
if (cachedUint8Memory0 === null || cachedUint8Memory0.byteLength === 0) {
|
|
@@ -194,35 +172,6 @@ function getUint8Memory0() {
|
|
|
194
172
|
}
|
|
195
173
|
return cachedUint8Memory0;
|
|
196
174
|
}
|
|
197
|
-
function getStringFromWasm0(ptr, len) {
|
|
198
|
-
ptr = ptr >>> 0;
|
|
199
|
-
return cachedTextDecoder.decode(getUint8Memory0().subarray(ptr, ptr + len));
|
|
200
|
-
}
|
|
201
|
-
function addHeapObject(obj) {
|
|
202
|
-
if (heap_next === heap.length) heap.push(heap.length + 1);
|
|
203
|
-
var idx = heap_next;
|
|
204
|
-
heap_next = heap[idx];
|
|
205
|
-
heap[idx] = obj;
|
|
206
|
-
return idx;
|
|
207
|
-
}
|
|
208
|
-
function isLikeNone(x) {
|
|
209
|
-
return x === undefined || x === null;
|
|
210
|
-
}
|
|
211
|
-
var cachedFloat64Memory0 = null;
|
|
212
|
-
function getFloat64Memory0() {
|
|
213
|
-
if (cachedFloat64Memory0 === null || cachedFloat64Memory0.byteLength === 0) {
|
|
214
|
-
cachedFloat64Memory0 = new Float64Array(wasm.memory.buffer);
|
|
215
|
-
}
|
|
216
|
-
return cachedFloat64Memory0;
|
|
217
|
-
}
|
|
218
|
-
var cachedInt32Memory0 = null;
|
|
219
|
-
function getInt32Memory0() {
|
|
220
|
-
if (cachedInt32Memory0 === null || cachedInt32Memory0.byteLength === 0) {
|
|
221
|
-
cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);
|
|
222
|
-
}
|
|
223
|
-
return cachedInt32Memory0;
|
|
224
|
-
}
|
|
225
|
-
var WASM_VECTOR_LEN = 0;
|
|
226
175
|
var cachedTextEncoder = typeof TextEncoder !== "undefined" ? new TextEncoder("utf-8") : {
|
|
227
176
|
encode: function() {
|
|
228
177
|
throw Error("TextEncoder not available");
|
|
@@ -267,6 +216,57 @@ function passStringToWasm0(arg, malloc, realloc) {
|
|
|
267
216
|
WASM_VECTOR_LEN = offset;
|
|
268
217
|
return ptr1;
|
|
269
218
|
}
|
|
219
|
+
function isLikeNone(x) {
|
|
220
|
+
return x === undefined || x === null;
|
|
221
|
+
}
|
|
222
|
+
var cachedInt32Memory0 = null;
|
|
223
|
+
function getInt32Memory0() {
|
|
224
|
+
if (cachedInt32Memory0 === null || cachedInt32Memory0.byteLength === 0) {
|
|
225
|
+
cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);
|
|
226
|
+
}
|
|
227
|
+
return cachedInt32Memory0;
|
|
228
|
+
}
|
|
229
|
+
var heap_next = heap.length;
|
|
230
|
+
function dropObject(idx) {
|
|
231
|
+
if (idx < 132) return;
|
|
232
|
+
heap[idx] = heap_next;
|
|
233
|
+
heap_next = idx;
|
|
234
|
+
}
|
|
235
|
+
function takeObject(idx) {
|
|
236
|
+
var ret = getObject(idx);
|
|
237
|
+
dropObject(idx);
|
|
238
|
+
return ret;
|
|
239
|
+
}
|
|
240
|
+
var cachedTextDecoder = typeof TextDecoder !== "undefined" ? new TextDecoder("utf-8", {
|
|
241
|
+
ignoreBOM: true,
|
|
242
|
+
fatal: true
|
|
243
|
+
}) : {
|
|
244
|
+
decode: function() {
|
|
245
|
+
throw Error("TextDecoder not available");
|
|
246
|
+
}
|
|
247
|
+
};
|
|
248
|
+
if (typeof TextDecoder !== "undefined") {
|
|
249
|
+
cachedTextDecoder.decode();
|
|
250
|
+
}
|
|
251
|
+
;
|
|
252
|
+
function getStringFromWasm0(ptr, len) {
|
|
253
|
+
ptr = ptr >>> 0;
|
|
254
|
+
return cachedTextDecoder.decode(getUint8Memory0().subarray(ptr, ptr + len));
|
|
255
|
+
}
|
|
256
|
+
function addHeapObject(obj) {
|
|
257
|
+
if (heap_next === heap.length) heap.push(heap.length + 1);
|
|
258
|
+
var idx = heap_next;
|
|
259
|
+
heap_next = heap[idx];
|
|
260
|
+
heap[idx] = obj;
|
|
261
|
+
return idx;
|
|
262
|
+
}
|
|
263
|
+
var cachedFloat64Memory0 = null;
|
|
264
|
+
function getFloat64Memory0() {
|
|
265
|
+
if (cachedFloat64Memory0 === null || cachedFloat64Memory0.byteLength === 0) {
|
|
266
|
+
cachedFloat64Memory0 = new Float64Array(wasm.memory.buffer);
|
|
267
|
+
}
|
|
268
|
+
return cachedFloat64Memory0;
|
|
269
|
+
}
|
|
270
270
|
var cachedBigInt64Memory0 = null;
|
|
271
271
|
function getBigInt64Memory0() {
|
|
272
272
|
if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.byteLength === 0) {
|
|
@@ -522,6 +522,31 @@ function ___wbg_load() {
|
|
|
522
522
|
function __wbg_get_imports() {
|
|
523
523
|
var imports = {};
|
|
524
524
|
imports.wbg = {};
|
|
525
|
+
imports.wbg.__wbindgen_string_get = function(arg0, arg1) {
|
|
526
|
+
var obj = getObject(arg1);
|
|
527
|
+
var ret = typeof obj === "string" ? obj : undefined;
|
|
528
|
+
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
529
|
+
var len1 = WASM_VECTOR_LEN;
|
|
530
|
+
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
531
|
+
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
532
|
+
};
|
|
533
|
+
imports.wbg.__wbindgen_object_drop_ref = function(arg0) {
|
|
534
|
+
takeObject(arg0);
|
|
535
|
+
};
|
|
536
|
+
imports.wbg.__wbindgen_error_new = function(arg0, arg1) {
|
|
537
|
+
var ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
538
|
+
return addHeapObject(ret);
|
|
539
|
+
};
|
|
540
|
+
imports.wbg.__wbindgen_string_new = function(arg0, arg1) {
|
|
541
|
+
var ret = getStringFromWasm0(arg0, arg1);
|
|
542
|
+
return addHeapObject(ret);
|
|
543
|
+
};
|
|
544
|
+
imports.wbg.__wbg_call_53fc3abd42e24ec8 = function() {
|
|
545
|
+
return handleError(function(arg0, arg1, arg2) {
|
|
546
|
+
var ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
|
|
547
|
+
return addHeapObject(ret);
|
|
548
|
+
}, arguments);
|
|
549
|
+
};
|
|
525
550
|
imports.wbg.__wbg_isArray_38525be7442aa21e = function(arg0) {
|
|
526
551
|
var ret = Array.isArray(getObject(arg0));
|
|
527
552
|
return ret;
|
|
@@ -548,26 +573,34 @@ function __wbg_get_imports() {
|
|
|
548
573
|
var ret = getObject(arg0).value;
|
|
549
574
|
return addHeapObject(ret);
|
|
550
575
|
};
|
|
551
|
-
imports.wbg.
|
|
552
|
-
|
|
576
|
+
imports.wbg.__wbindgen_number_get = function(arg0, arg1) {
|
|
577
|
+
var obj = getObject(arg1);
|
|
578
|
+
var ret = typeof obj === "number" ? obj : undefined;
|
|
579
|
+
getFloat64Memory0()[arg0 / 8 + 1] = isLikeNone(ret) ? 0 : ret;
|
|
580
|
+
getInt32Memory0()[arg0 / 4 + 0] = !isLikeNone(ret);
|
|
553
581
|
};
|
|
554
|
-
imports.wbg.
|
|
555
|
-
var ret =
|
|
582
|
+
imports.wbg.__wbg_isSafeInteger_c38b0a16d0c7cef7 = function(arg0) {
|
|
583
|
+
var ret = Number.isSafeInteger(getObject(arg0));
|
|
584
|
+
return ret;
|
|
585
|
+
};
|
|
586
|
+
imports.wbg.__wbg_new_c728d68b8b34487e = function() {
|
|
587
|
+
var ret = new Object();
|
|
556
588
|
return addHeapObject(ret);
|
|
557
589
|
};
|
|
558
|
-
imports.wbg.
|
|
559
|
-
|
|
590
|
+
imports.wbg.__wbg_set_841ac57cff3d672b = function(arg0, arg1, arg2) {
|
|
591
|
+
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
592
|
+
};
|
|
593
|
+
imports.wbg.__wbindgen_number_new = function(arg0) {
|
|
594
|
+
var ret = arg0;
|
|
595
|
+
return addHeapObject(ret);
|
|
596
|
+
};
|
|
597
|
+
imports.wbg.__wbg_new_08236689f0afb357 = function() {
|
|
598
|
+
var ret = new Array();
|
|
560
599
|
return addHeapObject(ret);
|
|
561
600
|
};
|
|
562
601
|
imports.wbg.__wbg_set_0ac78a2bc07da03c = function(arg0, arg1, arg2) {
|
|
563
602
|
getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
|
|
564
603
|
};
|
|
565
|
-
imports.wbg.__wbg_call_53fc3abd42e24ec8 = function() {
|
|
566
|
-
return handleError(function(arg0, arg1, arg2) {
|
|
567
|
-
var ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
|
|
568
|
-
return addHeapObject(ret);
|
|
569
|
-
}, arguments);
|
|
570
|
-
};
|
|
571
604
|
imports.wbg.__wbindgen_is_object = function(arg0) {
|
|
572
605
|
var val = getObject(arg0);
|
|
573
606
|
var ret = typeof val === "object" && val !== null;
|
|
@@ -590,39 +623,6 @@ function __wbg_get_imports() {
|
|
|
590
623
|
var ret = typeof v === "boolean" ? v ? 1 : 0 : 2;
|
|
591
624
|
return ret;
|
|
592
625
|
};
|
|
593
|
-
imports.wbg.__wbindgen_number_get = function(arg0, arg1) {
|
|
594
|
-
var obj = getObject(arg1);
|
|
595
|
-
var ret = typeof obj === "number" ? obj : undefined;
|
|
596
|
-
getFloat64Memory0()[arg0 / 8 + 1] = isLikeNone(ret) ? 0 : ret;
|
|
597
|
-
getInt32Memory0()[arg0 / 4 + 0] = !isLikeNone(ret);
|
|
598
|
-
};
|
|
599
|
-
imports.wbg.__wbg_isSafeInteger_c38b0a16d0c7cef7 = function(arg0) {
|
|
600
|
-
var ret = Number.isSafeInteger(getObject(arg0));
|
|
601
|
-
return ret;
|
|
602
|
-
};
|
|
603
|
-
imports.wbg.__wbg_new_c728d68b8b34487e = function() {
|
|
604
|
-
var ret = new Object();
|
|
605
|
-
return addHeapObject(ret);
|
|
606
|
-
};
|
|
607
|
-
imports.wbg.__wbg_set_841ac57cff3d672b = function(arg0, arg1, arg2) {
|
|
608
|
-
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
609
|
-
};
|
|
610
|
-
imports.wbg.__wbindgen_number_new = function(arg0) {
|
|
611
|
-
var ret = arg0;
|
|
612
|
-
return addHeapObject(ret);
|
|
613
|
-
};
|
|
614
|
-
imports.wbg.__wbindgen_string_get = function(arg0, arg1) {
|
|
615
|
-
var obj = getObject(arg1);
|
|
616
|
-
var ret = typeof obj === "string" ? obj : undefined;
|
|
617
|
-
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
618
|
-
var len1 = WASM_VECTOR_LEN;
|
|
619
|
-
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
620
|
-
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
621
|
-
};
|
|
622
|
-
imports.wbg.__wbindgen_error_new = function(arg0, arg1) {
|
|
623
|
-
var ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
624
|
-
return addHeapObject(ret);
|
|
625
|
-
};
|
|
626
626
|
imports.wbg.__wbindgen_cb_drop = function(arg0) {
|
|
627
627
|
var obj = takeObject(arg0).original;
|
|
628
628
|
if (obj.cnt-- == 1) {
|
|
@@ -647,31 +647,31 @@ function __wbg_get_imports() {
|
|
|
647
647
|
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
648
648
|
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
649
649
|
};
|
|
650
|
-
imports.wbg.
|
|
650
|
+
imports.wbg.__wbg_getStorage_4b146f80f10eb5b3 = function(arg0, arg1) {
|
|
651
651
|
var ret = getObject(arg0).getStorage(takeObject(arg1));
|
|
652
652
|
return addHeapObject(ret);
|
|
653
653
|
};
|
|
654
|
-
imports.wbg.
|
|
654
|
+
imports.wbg.__wbg_getStateRoot_41a6fee856c08fc6 = function(arg0) {
|
|
655
655
|
var ret = getObject(arg0).getStateRoot();
|
|
656
656
|
return addHeapObject(ret);
|
|
657
657
|
};
|
|
658
|
-
imports.wbg.
|
|
658
|
+
imports.wbg.__wbg_getNextKey_622b782ea46d6eb0 = function(arg0, arg1, arg2) {
|
|
659
659
|
var ret = getObject(arg0).getNextKey(takeObject(arg1), takeObject(arg2));
|
|
660
660
|
return addHeapObject(ret);
|
|
661
661
|
};
|
|
662
|
-
imports.wbg.
|
|
662
|
+
imports.wbg.__wbg_offchainGetStorage_612ac42f9df16365 = function(arg0, arg1) {
|
|
663
663
|
var ret = getObject(arg0).offchainGetStorage(takeObject(arg1));
|
|
664
664
|
return addHeapObject(ret);
|
|
665
665
|
};
|
|
666
|
-
imports.wbg.
|
|
666
|
+
imports.wbg.__wbg_offchainTimestamp_c8d5505f997edbf7 = function(arg0) {
|
|
667
667
|
var ret = getObject(arg0).offchainTimestamp();
|
|
668
668
|
return addHeapObject(ret);
|
|
669
669
|
};
|
|
670
|
-
imports.wbg.
|
|
670
|
+
imports.wbg.__wbg_offchainRandomSeed_4a396f6653590eae = function(arg0) {
|
|
671
671
|
var ret = getObject(arg0).offchainRandomSeed();
|
|
672
672
|
return addHeapObject(ret);
|
|
673
673
|
};
|
|
674
|
-
imports.wbg.
|
|
674
|
+
imports.wbg.__wbg_offchainSubmitTransaction_00319bc661f5ef24 = function(arg0, arg1) {
|
|
675
675
|
var ret = getObject(arg0).offchainSubmitTransaction(takeObject(arg1));
|
|
676
676
|
return addHeapObject(ret);
|
|
677
677
|
};
|
|
@@ -875,7 +875,7 @@ function __wbg_get_imports() {
|
|
|
875
875
|
imports.wbg.__wbg_warn_4affe1093892a4ef = function(arg0) {
|
|
876
876
|
console.warn(getObject(arg0));
|
|
877
877
|
};
|
|
878
|
-
imports.wbg.
|
|
878
|
+
imports.wbg.__wbindgen_closure_wrapper1336 = function(arg0, arg1, arg2) {
|
|
879
879
|
var ret = makeMutClosure(arg0, arg1, 122, __wbg_adapter_46);
|
|
880
880
|
return addHeapObject(ret);
|
|
881
881
|
};
|