Cargo fmt

This commit is contained in:
losfair 2019-07-04 01:45:54 +08:00
parent f32b22d571
commit 02464991da
4 changed files with 5 additions and 8 deletions

View File

@ -17,7 +17,8 @@ use std::sync::{Arc, RwLock};
use wasmparser::{self, WasmDecoder};
use wasmparser::{Operator, Type as WpType};
pub type BreakpointHandler = Box<Fn(BreakpointInfo) -> Result<(), Box<dyn Any>> + Send + Sync + 'static>;
pub type BreakpointHandler =
Box<Fn(BreakpointInfo) -> Result<(), Box<dyn Any>> + Send + Sync + 'static>;
pub type BreakpointMap = Arc<HashMap<usize, BreakpointHandler>>;
#[derive(Debug)]

View File

@ -359,8 +359,8 @@ impl InstanceImage {
#[cfg(all(unix, target_arch = "x86_64"))]
pub mod x64 {
use super::*;
use crate::fault::{catch_unsafe_unwind, run_on_alternative_stack};
use crate::codegen::BreakpointMap;
use crate::fault::{catch_unsafe_unwind, run_on_alternative_stack};
use crate::structures::TypedIndex;
use crate::types::LocalGlobalIndex;
use crate::vm::Ctx;

View File

@ -11,10 +11,8 @@
//!
use std::any::Any;
use std::cell::Cell;
use wasmer_runtime_core::fault::{
begin_unsafe_unwind, catch_unsafe_unwind, ensure_sighandler,
};
use wasmer_runtime_core::codegen::BreakpointMap;
use wasmer_runtime_core::fault::{begin_unsafe_unwind, catch_unsafe_unwind, ensure_sighandler};
use wasmer_runtime_core::typed_func::WasmTrapInfo;
thread_local! {

View File

@ -514,9 +514,7 @@ fn execute_wasm(options: &Run) -> Result<(), String> {
#[cfg(feature = "backend:singlepass")]
unsafe {
if options.backend == Backend::Singlepass {
use wasmer_runtime_core::fault::{
catch_unsafe_unwind, ensure_sighandler,
};
use wasmer_runtime_core::fault::{catch_unsafe_unwind, ensure_sighandler};
use wasmer_runtime_core::state::{
x64::invoke_call_return_on_stack, InstanceImage,
};