Update cranelift backend to new backend abstraction

This commit is contained in:
Lachlan Sneff
2019-04-12 09:58:29 -07:00
parent d8c6f76846
commit 8b5da1d86e
3 changed files with 20 additions and 100 deletions

View File

@ -357,13 +357,8 @@ pub struct FuncResolver {
pub(crate) memory: Arc<Memory>,
}
// Implements FuncResolver trait.
impl backend::FuncResolver for FuncResolver {
fn get(
&self,
_module: &wasmer_runtime_core::module::ModuleInner,
index: LocalFuncIndex,
) -> Option<NonNull<vm::Func>> {
impl FuncResolver {
pub fn lookup(&self, index: LocalFuncIndex) -> Option<NonNull<vm::Func>> {
lookup_func(&self.map, &self.memory, index)
}
}