Fix clippy.toml paths and a few clippy lints.
This commit is contained in:
@@ -93,7 +93,7 @@ impl Context {
|
||||
&mut *self.compiler,
|
||||
&data,
|
||||
&mut self.namespace,
|
||||
Rc::clone(&mut self.global_exports),
|
||||
Rc::clone(&self.global_exports),
|
||||
)
|
||||
}
|
||||
|
||||
@@ -170,11 +170,11 @@ impl Context {
|
||||
instance_name: &str,
|
||||
field: &str,
|
||||
) -> Result<ActionOutcome, ContextError> {
|
||||
let mut instance = self
|
||||
let instance = self
|
||||
.get_instance(&instance_name)
|
||||
.map_err(ContextError::Instance)?
|
||||
.clone();
|
||||
self.get(&mut instance, field).map_err(ContextError::Action)
|
||||
self.get(&instance, field).map_err(ContextError::Action)
|
||||
}
|
||||
|
||||
/// Get the value of an exported global variable from an instance.
|
||||
|
||||
@@ -44,7 +44,7 @@ pub fn link_module(
|
||||
signature, import_signature)
|
||||
));
|
||||
}
|
||||
dependencies.insert(InstanceHandle::from_vmctx(vmctx));
|
||||
dependencies.insert(unsafe { InstanceHandle::from_vmctx(vmctx) });
|
||||
function_imports.push(VMFunctionImport {
|
||||
body: address,
|
||||
vmctx,
|
||||
@@ -82,7 +82,7 @@ pub fn link_module(
|
||||
module_name, field,
|
||||
)));
|
||||
}
|
||||
dependencies.insert(InstanceHandle::from_vmctx(vmctx));
|
||||
dependencies.insert(unsafe { InstanceHandle::from_vmctx(vmctx) });
|
||||
table_imports.push(VMTableImport {
|
||||
from: definition,
|
||||
vmctx,
|
||||
@@ -136,7 +136,7 @@ pub fn link_module(
|
||||
}
|
||||
assert!(memory.offset_guard_size >= import_memory.offset_guard_size);
|
||||
|
||||
dependencies.insert(InstanceHandle::from_vmctx(vmctx));
|
||||
dependencies.insert(unsafe { InstanceHandle::from_vmctx(vmctx) });
|
||||
memory_imports.push(VMMemoryImport {
|
||||
from: definition,
|
||||
vmctx,
|
||||
@@ -180,7 +180,7 @@ pub fn link_module(
|
||||
module_name, field
|
||||
)));
|
||||
}
|
||||
dependencies.insert(InstanceHandle::from_vmctx(vmctx));
|
||||
dependencies.insert(unsafe { InstanceHandle::from_vmctx(vmctx) });
|
||||
global_imports.push(VMGlobalImport { from: definition });
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user