summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/shell-interface.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/shell-interface.h b/src/shell-interface.h
index 076787c9b..ef92f40cd 100644
--- a/src/shell-interface.h
+++ b/src/shell-interface.h
@@ -156,6 +156,9 @@ struct ShellExternalInterface : ModuleInstance::ExternalInterface {
trap("callIndirect: bad argument type");
}
}
+ if (func->result != result) {
+ trap("callIndirect: bad result type");
+ }
return instance.callFunctionInternal(func->name, arguments);
}