Enum liquid_core::parser::TryMatchToken
source · [−]pub enum TryMatchToken<'a, T> {
Matches(T),
Fails(TagToken<'a>),
}Expand description
The result of calling TagToken’s try.
If the token is successfully matched, the match is returned; otherwise, the TagToken is returned back.
Variants
Matches(T)
Fails(TagToken<'a>)
Implementations
sourceimpl<'a, T> TryMatchToken<'a, T>
impl<'a, T> TryMatchToken<'a, T>
pub fn into_result(self) -> Result<T>
pub fn into_result_custom_msg(self, msg: &str) -> Result<T>
Auto Trait Implementations
impl<'a, T> RefUnwindSafe for TryMatchToken<'a, T> where
T: RefUnwindSafe,
impl<'a, T> !Send for TryMatchToken<'a, T>
impl<'a, T> !Sync for TryMatchToken<'a, T>
impl<'a, T> Unpin for TryMatchToken<'a, T> where
T: Unpin,
impl<'a, T> UnwindSafe for TryMatchToken<'a, T> where
T: UnwindSafe,
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