summaryrefslogtreecommitdiff
path: root/src/js/binaryen.js-post.js
diff options
context:
space:
mode:
authorMax Graey <maxgraey@gmail.com>2020-08-28 16:23:32 +0300
committerGitHub <noreply@github.com>2020-08-28 15:23:32 +0200
commitfecfa92d71633f8bb28bb97a60adc9b54998456f (patch)
tree30418c26d7a3aa9aaedb25acc7ce4eca5be25be6 /src/js/binaryen.js-post.js
parent547e2be14d1f8f9b21905baee87b1946045b0fe7 (diff)
downloadbinaryen-fecfa92d71633f8bb28bb97a60adc9b54998456f.tar.gz
binaryen-fecfa92d71633f8bb28bb97a60adc9b54998456f.tar.bz2
binaryen-fecfa92d71633f8bb28bb97a60adc9b54998456f.zip
Add Binaryen(Get|Set)AllowHeavyweight to binaryen-c.h (#3082)
These declarations were previously missing causing the respective APIs to be not exposed. Also makes sure that a Boolean is returned by the JS API and adds a test to verify that it is working now.
Diffstat (limited to 'src/js/binaryen.js-post.js')
-rw-r--r--src/js/binaryen.js-post.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/js/binaryen.js-post.js b/src/js/binaryen.js-post.js
index f8a0b8590..057252f78 100644
--- a/src/js/binaryen.js-post.js
+++ b/src/js/binaryen.js-post.js
@@ -3032,7 +3032,7 @@ Module['setOneCallerInlineMaxSize'] = function(size) {
// Gets the value which allow inline functions that are not "lightweight".
Module['getAllowHeavyweight'] = function() {
- return Module['_BinaryenGetAllowHeavyweight']();
+ return Boolean(Module['_BinaryenGetAllowHeavyweight']());
};
// Sets the value which allow inline functions that are not "lightweight".