Enum everscale_asm::ParserError
source · pub enum ParserError {
ExpectedFound {
span: SimpleSpan<usize>,
found: Option<char>,
},
InvalidInt {
span: SimpleSpan<usize>,
inner: ParseBigIntError,
},
InvalidStackRegister {
span: SimpleSpan<usize>,
inner: Error,
},
InvalidControlRegister {
span: SimpleSpan<usize>,
inner: Error,
},
InvalidSlice {
span: SimpleSpan<usize>,
inner: Error,
},
UnknownError,
}Variants§
Implementations§
source§impl ParserError
impl ParserError
pub fn span(&self) -> Option<SimpleSpan<usize>>
Trait Implementations§
source§impl Debug for ParserError
impl Debug for ParserError
source§impl Display for ParserError
impl Display for ParserError
source§impl<'a> Error<'a, &'a str> for ParserError
impl<'a> Error<'a, &'a str> for ParserError
source§fn expected_found<Iter: IntoIterator<Item = Option<MaybeRef<'a, char>>>>(
_: Iter,
found: Option<MaybeRef<'a, char>>,
span: SimpleSpan<usize>
) -> Self
fn expected_found<Iter: IntoIterator<Item = Option<MaybeRef<'a, char>>>>( _: Iter, found: Option<MaybeRef<'a, char>>, span: SimpleSpan<usize> ) -> Self
Create a new error describing a conflict between expected inputs and that which was actually found. Read more
source§fn merge(self, _: Self) -> Self
fn merge(self, _: Self) -> Self
Merge two errors that point to the same input together, combining their information.
source§fn merge_expected_found<E>(
self,
expected: E,
found: Option<Maybe<<I as Input<'a>>::Token, &'a <I as Input<'a>>::Token>>,
span: <I as Input<'a>>::Span
) -> Selfwhere
E: IntoIterator<Item = Option<Maybe<<I as Input<'a>>::Token, &'a <I as Input<'a>>::Token>>>,
fn merge_expected_found<E>( self, expected: E, found: Option<Maybe<<I as Input<'a>>::Token, &'a <I as Input<'a>>::Token>>, span: <I as Input<'a>>::Span ) -> Selfwhere E: IntoIterator<Item = Option<Maybe<<I as Input<'a>>::Token, &'a <I as Input<'a>>::Token>>>,
Fast path for
a.merge(Error::expected_found(...)) that may incur less overhead by, for example, reusing allocations.source§fn replace_expected_found<E>(
self,
expected: E,
found: Option<Maybe<<I as Input<'a>>::Token, &'a <I as Input<'a>>::Token>>,
span: <I as Input<'a>>::Span
) -> Selfwhere
E: IntoIterator<Item = Option<Maybe<<I as Input<'a>>::Token, &'a <I as Input<'a>>::Token>>>,
fn replace_expected_found<E>( self, expected: E, found: Option<Maybe<<I as Input<'a>>::Token, &'a <I as Input<'a>>::Token>>, span: <I as Input<'a>>::Span ) -> Selfwhere E: IntoIterator<Item = Option<Maybe<<I as Input<'a>>::Token, &'a <I as Input<'a>>::Token>>>,
Fast path for
a = Error::expected_found(...) that may incur less overhead by, for example, reusing allocations.source§impl Error for ParserError
impl Error for ParserError
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
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 ParserError
impl Send for ParserError
impl Sync for ParserError
impl Unpin for ParserError
impl UnwindSafe for ParserError
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