pub struct Token<'a> {
pub kind: u16,
pub start: usize,
pub end: usize,
pub value: Value<'a>,
}Expand description
One token.
Fields§
§kind: u16The token number of the grammar. See crate::token and crate::character. The end of the text is 0.
start: usizeThe byte offset where the token starts.
end: usizeThe byte offset after the token.
value: Value<'a>The value.
Implementations§
Trait Implementations§
impl<'a> StructuralPartialEq for Token<'a>
Auto Trait Implementations§
impl<'a> Freeze for Token<'a>
impl<'a> RefUnwindSafe for Token<'a>
impl<'a> Send for Token<'a>
impl<'a> Sync for Token<'a>
impl<'a> Unpin for Token<'a>
impl<'a> UnsafeUnpin for Token<'a>
impl<'a> UnwindSafe for Token<'a>
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