@cartridge/controller-wasm 0.3.7 → 0.3.8
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
|
@@ -218,7 +218,7 @@ state => {
|
|
|
218
218
|
}
|
|
219
219
|
);
|
|
220
220
|
|
|
221
|
-
function
|
|
221
|
+
function makeClosure(arg0, arg1, dtor, f) {
|
|
222
222
|
const state = { a: arg0, b: arg1, cnt: 1, dtor };
|
|
223
223
|
const real = (...args) => {
|
|
224
224
|
|
|
@@ -226,16 +226,12 @@ function makeMutClosure(arg0, arg1, dtor, f) {
|
|
|
226
226
|
// count. This ensures that the Rust closure environment won't
|
|
227
227
|
// be deallocated while we're invoking it.
|
|
228
228
|
state.cnt++;
|
|
229
|
-
const a = state.a;
|
|
230
|
-
state.a = 0;
|
|
231
229
|
try {
|
|
232
|
-
return f(a, state.b, ...args);
|
|
230
|
+
return f(state.a, state.b, ...args);
|
|
233
231
|
} finally {
|
|
234
232
|
if (--state.cnt === 0) {
|
|
235
|
-
wasm.__wbindgen_export_4.get(state.dtor)(a, state.b);
|
|
233
|
+
wasm.__wbindgen_export_4.get(state.dtor)(state.a, state.b); state.a = 0;
|
|
236
234
|
CLOSURE_DTORS.unregister(state);
|
|
237
|
-
} else {
|
|
238
|
-
state.a = a;
|
|
239
235
|
}
|
|
240
236
|
}
|
|
241
237
|
};
|
|
@@ -244,7 +240,7 @@ function makeMutClosure(arg0, arg1, dtor, f) {
|
|
|
244
240
|
return real;
|
|
245
241
|
}
|
|
246
242
|
|
|
247
|
-
function
|
|
243
|
+
function makeMutClosure(arg0, arg1, dtor, f) {
|
|
248
244
|
const state = { a: arg0, b: arg1, cnt: 1, dtor };
|
|
249
245
|
const real = (...args) => {
|
|
250
246
|
|
|
@@ -252,12 +248,16 @@ function makeClosure(arg0, arg1, dtor, f) {
|
|
|
252
248
|
// count. This ensures that the Rust closure environment won't
|
|
253
249
|
// be deallocated while we're invoking it.
|
|
254
250
|
state.cnt++;
|
|
251
|
+
const a = state.a;
|
|
252
|
+
state.a = 0;
|
|
255
253
|
try {
|
|
256
|
-
return f(
|
|
254
|
+
return f(a, state.b, ...args);
|
|
257
255
|
} finally {
|
|
258
256
|
if (--state.cnt === 0) {
|
|
259
|
-
wasm.__wbindgen_export_4.get(state.dtor)(
|
|
257
|
+
wasm.__wbindgen_export_4.get(state.dtor)(a, state.b);
|
|
260
258
|
CLOSURE_DTORS.unregister(state);
|
|
259
|
+
} else {
|
|
260
|
+
state.a = a;
|
|
261
261
|
}
|
|
262
262
|
}
|
|
263
263
|
};
|
|
@@ -336,7 +336,7 @@ function __wbg_adapter_8(arg0, arg1) {
|
|
|
336
336
|
wasm.__wbindgen_export_5(arg0, arg1);
|
|
337
337
|
}
|
|
338
338
|
|
|
339
|
-
function
|
|
339
|
+
function __wbg_adapter_11(arg0, arg1, arg2) {
|
|
340
340
|
wasm.__wbindgen_export_6(arg0, arg1, addHeapObject(arg2));
|
|
341
341
|
}
|
|
342
342
|
|
|
@@ -1917,21 +1917,9 @@ export function __wbindgen_cast_2241b6af4c4b2941(arg0, arg1) {
|
|
|
1917
1917
|
return addHeapObject(ret);
|
|
1918
1918
|
};
|
|
1919
1919
|
|
|
1920
|
-
export function __wbindgen_cast_33d009dfe52396a6(arg0, arg1) {
|
|
1921
|
-
// Cast intrinsic for `Closure(Closure { dtor_idx: 903, function: Function { arguments: [], shim_idx: 904, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1922
|
-
const ret = makeMutClosure(arg0, arg1, 903, __wbg_adapter_8);
|
|
1923
|
-
return addHeapObject(ret);
|
|
1924
|
-
};
|
|
1925
|
-
|
|
1926
1920
|
export function __wbindgen_cast_3ab31798e812bcf8(arg0, arg1) {
|
|
1927
1921
|
// Cast intrinsic for `Closure(Closure { dtor_idx: 13, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx: 14, ret: Unit, inner_ret: Some(Unit) }, mutable: false }) -> Externref`.
|
|
1928
|
-
const ret = makeClosure(arg0, arg1, 13,
|
|
1929
|
-
return addHeapObject(ret);
|
|
1930
|
-
};
|
|
1931
|
-
|
|
1932
|
-
export function __wbindgen_cast_7cf6c7352bd34255(arg0, arg1) {
|
|
1933
|
-
// Cast intrinsic for `Closure(Closure { dtor_idx: 936, function: Function { arguments: [Externref], shim_idx: 937, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1934
|
-
const ret = makeMutClosure(arg0, arg1, 936, __wbg_adapter_13);
|
|
1922
|
+
const ret = makeClosure(arg0, arg1, 13, __wbg_adapter_11);
|
|
1935
1923
|
return addHeapObject(ret);
|
|
1936
1924
|
};
|
|
1937
1925
|
|
|
@@ -1941,6 +1929,12 @@ export function __wbindgen_cast_9ae0607507abb057(arg0) {
|
|
|
1941
1929
|
return addHeapObject(ret);
|
|
1942
1930
|
};
|
|
1943
1931
|
|
|
1932
|
+
export function __wbindgen_cast_a428de4fc2820fa4(arg0, arg1) {
|
|
1933
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 938, function: Function { arguments: [Externref], shim_idx: 939, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1934
|
+
const ret = makeMutClosure(arg0, arg1, 938, __wbg_adapter_16);
|
|
1935
|
+
return addHeapObject(ret);
|
|
1936
|
+
};
|
|
1937
|
+
|
|
1944
1938
|
export function __wbindgen_cast_cb9088102bce6b30(arg0, arg1) {
|
|
1945
1939
|
// Cast intrinsic for `Ref(Slice(U8)) -> NamedExternref("Uint8Array")`.
|
|
1946
1940
|
const ret = getArrayU8FromWasm0(arg0, arg1);
|
|
@@ -1953,6 +1947,12 @@ export function __wbindgen_cast_d6cd19b81560fd6e(arg0) {
|
|
|
1953
1947
|
return addHeapObject(ret);
|
|
1954
1948
|
};
|
|
1955
1949
|
|
|
1950
|
+
export function __wbindgen_cast_ed712f6666cb3532(arg0, arg1) {
|
|
1951
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 904, function: Function { arguments: [], shim_idx: 905, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1952
|
+
const ret = makeMutClosure(arg0, arg1, 904, __wbg_adapter_8);
|
|
1953
|
+
return addHeapObject(ret);
|
|
1954
|
+
};
|
|
1955
|
+
|
|
1956
1956
|
export function __wbindgen_object_clone_ref(arg0) {
|
|
1957
1957
|
const ret = getObject(arg0);
|
|
1958
1958
|
return addHeapObject(ret);
|
|
Binary file
|
|
@@ -277,11 +277,11 @@ export function signerToGuid(signer) {
|
|
|
277
277
|
return takeObject(ret);
|
|
278
278
|
}
|
|
279
279
|
|
|
280
|
-
function
|
|
280
|
+
function __wbg_adapter_4(arg0, arg1) {
|
|
281
281
|
wasm.__wbindgen_export_5(arg0, arg1);
|
|
282
282
|
}
|
|
283
283
|
|
|
284
|
-
function
|
|
284
|
+
function __wbg_adapter_11(arg0, arg1, arg2) {
|
|
285
285
|
wasm.__wbindgen_export_6(arg0, arg1, addHeapObject(arg2));
|
|
286
286
|
}
|
|
287
287
|
|
|
@@ -1164,9 +1164,9 @@ export function __wbindgen_cast_2241b6af4c4b2941(arg0, arg1) {
|
|
|
1164
1164
|
return addHeapObject(ret);
|
|
1165
1165
|
};
|
|
1166
1166
|
|
|
1167
|
-
export function
|
|
1168
|
-
// Cast intrinsic for `Closure(Closure { dtor_idx:
|
|
1169
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1167
|
+
export function __wbindgen_cast_90f1d8883a9ae70e(arg0, arg1) {
|
|
1168
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 499, function: Function { arguments: [Externref], shim_idx: 500, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1169
|
+
const ret = makeMutClosure(arg0, arg1, 499, __wbg_adapter_11);
|
|
1170
1170
|
return addHeapObject(ret);
|
|
1171
1171
|
};
|
|
1172
1172
|
|
|
@@ -1182,9 +1182,9 @@ export function __wbindgen_cast_d6cd19b81560fd6e(arg0) {
|
|
|
1182
1182
|
return addHeapObject(ret);
|
|
1183
1183
|
};
|
|
1184
1184
|
|
|
1185
|
-
export function
|
|
1186
|
-
// Cast intrinsic for `Closure(Closure { dtor_idx:
|
|
1187
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1185
|
+
export function __wbindgen_cast_e585a18257edad45(arg0, arg1) {
|
|
1186
|
+
// Cast intrinsic for `Closure(Closure { dtor_idx: 465, function: Function { arguments: [], shim_idx: 466, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
1187
|
+
const ret = makeMutClosure(arg0, arg1, 465, __wbg_adapter_4);
|
|
1188
1188
|
return addHeapObject(ret);
|
|
1189
1189
|
};
|
|
1190
1190
|
|
|
Binary file
|