aboutsummaryrefslogtreecommitdiff
path: root/ext/wasm/common/whwasmutil.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/wasm/common/whwasmutil.js')
-rw-r--r--ext/wasm/common/whwasmutil.js44
1 files changed, 25 insertions, 19 deletions
diff --git a/ext/wasm/common/whwasmutil.js b/ext/wasm/common/whwasmutil.js
index aea484787..f48e8a7d2 100644
--- a/ext/wasm/common/whwasmutil.js
+++ b/ext/wasm/common/whwasmutil.js
@@ -1656,25 +1656,11 @@ globalThis.WhWasmUtilInstaller = function(target){
? opt.callProxy : undefined;
}
- /** If true, the constructor emits a warning. The intent is that
- this be set to true after bootstrapping of the higher-level
- client library is complete, to warn downstream clients that
- they shouldn't be relying on this implemenation detail which
- does not have a stable interface. */
- static warnOnUse = false;
-
- /** If true, convertArg() will FuncPtrAdapter.debugOut() when it
- (un)installs a function binding to/from WASM. Note that
- deinstallation of bindScope=transient bindings happens
- via scopedAllocPop() so will not be output. */
- static debugFuncInstall = false;
-
- /** Function used for debug output. */
- static debugOut = console.debug.bind(console);
-
- static bindScopes = [
- 'transient', 'context', 'singleton', 'permanent'
- ];
+ /**
+ Note that static class members are defined outside of the class
+ to work around an emcc toolchain build problem: one of the
+ tools in emsdk v3.1.42 does not support the static keyword.
+ */
/* Dummy impl. Overwritten per-instance as needed. */
contextKey(argv,argIndex){
@@ -1761,6 +1747,26 @@ globalThis.WhWasmUtilInstaller = function(target){
}/*convertArg()*/
}/*FuncPtrAdapter*/;
+ /** If true, the constructor emits a warning. The intent is that
+ this be set to true after bootstrapping of the higher-level
+ client library is complete, to warn downstream clients that
+ they shouldn't be relying on this implemenation detail which
+ does not have a stable interface. */
+ xArg.FuncPtrAdapter.warnOnUse = false;
+
+ /** If true, convertArg() will FuncPtrAdapter.debugOut() when it
+ (un)installs a function binding to/from WASM. Note that
+ deinstallation of bindScope=transient bindings happens
+ via scopedAllocPop() so will not be output. */
+ xArg.FuncPtrAdapter.debugFuncInstall = false;
+
+ /** Function used for debug output. */
+ xArg.FuncPtrAdapter.debugOut = console.debug.bind(console);
+
+ xArg.FuncPtrAdapter.bindScopes = [
+ 'transient', 'context', 'singleton', 'permanent'
+ ];
+
const __xArgAdapterCheck =
(t)=>xArg.get(t) || toss("Argument adapter not found:",t);