Skip to content

Commit

Permalink
fix(clif-backend) Module::new does not use its argument.
Browse files Browse the repository at this point in the history
The `Module::new` method requires an argument (`wasm: &[u8]`) that is
never used.

This patch removes the argument, and updates the code accordingly.
  • Loading branch information
Hywan committed Mar 4, 2019
1 parent 0c62693 commit 5744f68
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/clif-backend/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ impl Compiler for CraneliftCompiler {

let isa = get_isa();

let mut module = module::Module::new(wasm);
let mut module = module::Module::new();
let module_env = module_env::ModuleEnv::new(&mut module, &*isa);

let func_bodies = module_env.translate(wasm)?;
Expand Down
2 changes: 1 addition & 1 deletion lib/clif-backend/src/module.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ pub struct Module {
}

impl Module {
pub fn new(wasm: &[u8]) -> Self {
pub fn new() -> Self {
Self {
info: ModuleInfo {
memories: Map::new(),
Expand Down

0 comments on commit 5744f68

Please sign in to comment.