summaryrefslogtreecommitdiff
path: root/src/js/binaryen.js-post.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/js/binaryen.js-post.js')
-rw-r--r--src/js/binaryen.js-post.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/js/binaryen.js-post.js b/src/js/binaryen.js-post.js
index 3f8b6545b..ee90aa1fc 100644
--- a/src/js/binaryen.js-post.js
+++ b/src/js/binaryen.js-post.js
@@ -3181,7 +3181,9 @@ Module['getExpressionInfo'] = function(expr) {
// Gets the side effects of the specified expression
Module['getSideEffects'] = function(expr, module) {
- return Module['_BinaryenExpressionGetSideEffects'](expr, module);
+ assert(module); // guard against incorrect old API usage: a module must be
+ // provided here.
+ return Module['_BinaryenExpressionGetSideEffects'](expr, module['ptr']);
};
Module['createType'] = function(types) {