Struct koto_lexer::LexedToken
source · pub struct LexedToken {
pub token: Token,
pub source_bytes: Range<usize>,
pub span: Span,
pub indent: usize,
}
Expand description
A Token along with additional metadata
Fields§
§token: Token
The token
source_bytes: Range<usize>
The byte positions in the source representing the token
span: Span
The token’s span
indent: usize
The indentation level of the token’s starting line
Implementations§
Trait Implementations§
source§impl Clone for LexedToken
impl Clone for LexedToken
source§fn clone(&self) -> LexedToken
fn clone(&self) -> LexedToken
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for LexedToken
impl Debug for LexedToken
source§impl Default for LexedToken
impl Default for LexedToken
source§impl PartialEq for LexedToken
impl PartialEq for LexedToken
source§fn eq(&self, other: &LexedToken) -> bool
fn eq(&self, other: &LexedToken) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for LexedToken
Auto Trait Implementations§
impl Freeze for LexedToken
impl RefUnwindSafe for LexedToken
impl Send for LexedToken
impl Sync for LexedToken
impl Unpin for LexedToken
impl UnwindSafe for LexedToken
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