Skip to content

Commit

Permalink
some cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
axic committed Feb 25, 2021
1 parent d525119 commit 0a9bfce
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/utils/wasm3_engine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ bool Wasm3Engine::instantiate(bytes_view wasm_binary)
return false;
}

auto const ret = m3_LinkRawFunction(module, "env", "adler32", "i(ii)", env_adler32);
const auto ret = m3_LinkRawFunction(module, "env", "adler32", "i(ii)", env_adler32);
if (ret != m3Err_none && ret != m3Err_functionLookupFailed)
return false;

Expand Down Expand Up @@ -150,7 +150,7 @@ WasmEngine::Result Wasm3Engine::execute(

std::vector<const void*> argPtrs;
argPtrs.reserve(args.size());
for (auto const& arg : args)
for (const auto& arg : args)
argPtrs.push_back(&arg);

// This ensures input count/type matches. For the return value we assume find_function did the
Expand All @@ -162,7 +162,7 @@ WasmEngine::Result Wasm3Engine::execute(

uint64_t ret_value = 0;
// This should not fail because we check GetRetCount.
[[maybe_unused]] auto const ret = m3_GetResultsV(function, &ret_value);
[[maybe_unused]] const auto ret = m3_GetResultsV(function, &ret_value);
assert(ret == m3Err_none);
return {false, ret_value};
}
Expand Down

0 comments on commit 0a9bfce

Please sign in to comment.