From d19721bc110f0c4545eeaed825de99f963834a0a Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 3 Oct 2016 16:40:18 -0700 Subject: Refactor Import::Kind and Export::Kind into an ExternalKind enum class (#725) --- src/shell-interface.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/shell-interface.h') diff --git a/src/shell-interface.h b/src/shell-interface.h index b9a90131b..ee7ba4d9c 100644 --- a/src/shell-interface.h +++ b/src/shell-interface.h @@ -114,7 +114,7 @@ struct ShellExternalInterface : ModuleInstance::ExternalInterface { void importGlobals(std::map& globals, Module& wasm) override { // add spectest globals for (auto& import : wasm.imports) { - if (import->kind == Import::Global && import->module == SPECTEST && import->base == GLOBAL) { + if (import->kind == ExternalKind::Global && import->module == SPECTEST && import->base == GLOBAL) { switch (import->globalType) { case i32: globals[import->name] = Literal(int32_t(666)); break; case i64: globals[import->name] = Literal(int64_t(666)); break; @@ -122,7 +122,7 @@ struct ShellExternalInterface : ModuleInstance::ExternalInterface { case f64: globals[import->name] = Literal(double(666.6)); break; default: WASM_UNREACHABLE(); } - } else if (import->kind == Import::Memory && import->module == SPECTEST && import->base == MEMORY) { + } else if (import->kind == ExternalKind::Memory && import->module == SPECTEST && import->base == MEMORY) { // imported memory has initial 1 and max 2 wasm.memory.initial = 1; wasm.memory.max = 2; -- cgit v1.2.3