pub enum LasmError {
Parse {
message: String,
location: Location,
},
Type(String),
Compile {
message: String,
location: Option<Location>,
},
Runtime(String),
Io(Error),
Module(ModuleError),
}Expand description
Error type for LASM
Variants§
Parse
Errors that occur during parsing, with a message and location.
Type(String)
Errors that occur during type checking, with a message.
Compile
Errors that occur during compilation, with a message and optional location.
Runtime(String)
Errors that occur during runtime, with a message.
Io(Error)
Propagated io errors from file reading/writing.
Module(ModuleError)
Propagated Cranelift errors when the cranelift feature is enabled.
Trait Implementations§
Source§impl Error for LasmError
impl Error for LasmError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<ModuleError> for LasmError
impl From<ModuleError> for LasmError
Source§fn from(source: ModuleError) -> Self
fn from(source: ModuleError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for LasmError
impl !RefUnwindSafe for LasmError
impl Send for LasmError
impl Sync for LasmError
impl Unpin for LasmError
impl UnsafeUnpin for LasmError
impl !UnwindSafe for LasmError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more