pub enum ErrorSource {
Lexical(String),
Parsing(String),
Runtime(String),
Type(String),
Music(String),
Argument(String),
Cli(String),
}Expand description
A span-less error representing the source of the problem.
Variants§
Lexical(String)
Parsing(String)
Runtime(String)
Type(String)
Music(String)
Argument(String)
Cli(String)
Implementations§
Trait Implementations§
Source§impl AddSpan for ErrorSource
impl AddSpan for ErrorSource
Source§fn with_span(self, span: Span) -> CarmenError
fn with_span(self, span: Span) -> CarmenError
Converts an
ErrorSource into a CarmenError by adding span information.Source§impl Clone for ErrorSource
impl Clone for ErrorSource
Source§fn clone(&self) -> ErrorSource
fn clone(&self) -> ErrorSource
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ErrorSource
impl Debug for ErrorSource
Source§impl Display for ErrorSource
impl Display for ErrorSource
Source§impl Error for ErrorSource
impl Error for ErrorSource
1.30.0§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§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl PartialEq for ErrorSource
impl PartialEq for ErrorSource
impl StructuralPartialEq for ErrorSource
Auto Trait Implementations§
impl Freeze for ErrorSource
impl RefUnwindSafe for ErrorSource
impl Send for ErrorSource
impl Sync for ErrorSource
impl Unpin for ErrorSource
impl UnwindSafe for ErrorSource
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)