pub enum Error {
NotFound(String),
Library(String, Error),
Host {
function: &'static str,
code: u32,
},
Io(Error),
Managed(String),
Other(String),
}Expand description
What went wrong starting a runtime, loading assemblies or calling into them.
Variants§
NotFound(String)
A .NET install, framework, assembly, type or method wasn’t found.
Library(String, Error)
A runtime library (libcoreclr, Mono) or one of its exports couldn’t be
loaded; holds the library or export name and the loader’s error.
Host
A CoreCLR hosting call returned a failure HRESULT.
Fields
Io(Error)
Reading a file, e.g. an assembly, failed.
Managed(String)
Managed code threw; holds the exception’s ToString() where it could be read.
Other(String)
Anything else the runtime reported, e.g. a failed Mono call or an assembly hao couldn’t read or write.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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()
Auto Trait Implementations§
impl !RefUnwindSafe for Error
impl !UnwindSafe for Error
impl Forget for Error
impl Freeze for Error
impl Move for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnsafeUnpin for Errorwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
*const [u8] is !null: UnsafeUnpin,
PhantomData<[u8]>: UnsafeUnpin,
&'static str: UnsafeUnpin,
*const () is !null: UnsafeUnpin,
PhantomData<ErrorData<CustomOwner>>: UnsafeUnpin,
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