//! Error types and utilities.
usestd::fmt;/// Either `Ok(T)` or `Err(failure::Error)`.
pubuseanyhow::Result;/// A leaf wasm error type.
////// Just an enum with no further information. Extra diagnostics are attached via
/// failure's `context` method.
#[derive(Copy, Clone, Eq, PartialEq, Debug)]pubenumErrorKind{/// Given invalid input wasm.
InvalidWasm,}implfmt::Display forErrorKind{fnfmt(&self, f:&mutfmt::Formatter)->fmt::Result{matchself{ErrorKind::InvalidWasm =>"The input WebAssembly is invalid".fmt(f),}}}implstd::error::Error forErrorKind{}