Enum hairy::HairyParserError
source · [−]pub enum HairyParserError<'a> {
Lexer(HairyLexerError),
Parser(&'a str),
Expr(CompileErrorDescription<'a>),
Eval(EvalError<'a>),
Other(&'a str),
}
Expand description
The errors that can occur during Hairy template parsing. It can either be a lexer error (so a part of
the input can not be translated to a token), or a parser error (a different token expected).
As Hairy templates can contain expressions, these expressions can also trigger errors. These
can either be in the parsing of the expressions, or during optimizing (which causes
EvalErrors). Other errors are reporting using Other
.
Variants
Lexer(HairyLexerError)
Parser(&'a str)
Expr(CompileErrorDescription<'a>)
Eval(EvalError<'a>)
Other(&'a str)
Trait Implementations
sourceimpl<'a> Clone for HairyParserError<'a>
impl<'a> Clone for HairyParserError<'a>
sourcefn clone(&self) -> HairyParserError<'a>
fn clone(&self) -> HairyParserError<'a>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<'a> Debug for HairyParserError<'a>
impl<'a> Debug for HairyParserError<'a>
sourceimpl<'a> Display for HairyParserError<'a>
impl<'a> Display for HairyParserError<'a>
sourceimpl<'a> From<EncodingError> for HairyParserError<'a>
impl<'a> From<EncodingError> for HairyParserError<'a>
sourcefn from(_: EncodingError) -> Self
fn from(_: EncodingError) -> Self
Converts to this type from the input type.
impl<'a> Copy for HairyParserError<'a>
Auto Trait Implementations
impl<'a> RefUnwindSafe for HairyParserError<'a>
impl<'a> Send for HairyParserError<'a>
impl<'a> Sync for HairyParserError<'a>
impl<'a> Unpin for HairyParserError<'a>
impl<'a> UnwindSafe for HairyParserError<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more