From 63bc52d9fdd1bbb3977c91aa8c38ddb0b41c7308 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 3 Aug 2018 12:43:36 -0700 Subject: [PATCH] Eliminate runtime's direct dependeny on wasmparser. --- lib/runtime/Cargo.toml | 1 - lib/runtime/src/lib.rs | 4 +--- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/runtime/Cargo.toml b/lib/runtime/Cargo.toml index fdb224390e..c56d17b656 100644 --- a/lib/runtime/Cargo.toml +++ b/lib/runtime/Cargo.toml @@ -10,5 +10,4 @@ license = "Apache-2.0 WITH LLVM-exception" [dependencies] cranelift-codegen = "0.18.1" cranelift-wasm = "0.18.1" -wasmparser = "0.17.2" target-lexicon = "0.0.3" diff --git a/lib/runtime/src/lib.rs b/lib/runtime/src/lib.rs index 15e479109e..2934b28286 100644 --- a/lib/runtime/src/lib.rs +++ b/lib/runtime/src/lib.rs @@ -8,7 +8,6 @@ extern crate cranelift_codegen; extern crate cranelift_wasm; extern crate target_lexicon; -extern crate wasmparser; pub mod compilation; pub mod instance; @@ -590,9 +589,8 @@ impl<'data, 'module> ModuleTranslation<'data, 'module> { self.module.signatures[self.module.functions[func_index]].clone(); let mut trans = FuncTranslator::new(); - let reader = wasmparser::BinaryReader::new(input); trans - .translate_from_reader(reader, &mut context.func, &mut self.func_env()) + .translate(input, &mut context.func, &mut self.func_env()) .map_err(|e| e.to_string())?; let mut code_buf: Vec = Vec::new();