diff options
Diffstat (limited to 'src/shell-interface.h')
-rw-r--r-- | src/shell-interface.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/shell-interface.h b/src/shell-interface.h index 963832fed..0667e43a1 100644 --- a/src/shell-interface.h +++ b/src/shell-interface.h @@ -165,12 +165,12 @@ struct ShellExternalInterface : ModuleInstance::ExternalInterface { if (sig != func->sig) { trap("callIndirect: function signatures don't match"); } - const std::vector<Type>& params = func->sig.params.expand(); - if (params.size() != arguments.size()) { + if (func->sig.params.size() != arguments.size()) { trap("callIndirect: bad # of arguments"); } - for (size_t i = 0; i < params.size(); i++) { - if (!Type::isSubType(arguments[i].type, params[i])) { + size_t i = 0; + for (auto& param : func->sig.params) { + if (!Type::isSubType(arguments[i++].type, param)) { trap("callIndirect: bad argument type"); } } |