pub enum TokenKind {
Show 45 variants
Ident(String),
Keyword(Keyword),
Bool(bool),
Int(i64),
Float(f64),
Duration(i64),
Str(Vec<StringPart>),
DocComment(String),
LParen,
RParen,
LBrace,
RBrace,
LBracket,
RBracket,
Comma,
Colon,
Dot,
DotDot,
DotDotLt,
Ellipsis,
Arrow,
FatArrow,
Question,
Underscore,
Eq,
EqEq,
Bang,
BangEq,
Lt,
LtEq,
Gt,
GtEq,
Plus,
Minus,
Star,
Slash,
Percent,
AmpAmp,
PipePipe,
PlusEq,
MinusEq,
StarEq,
SlashEq,
PercentEq,
Eof,
}Variants§
Ident(String)
Keyword(Keyword)
Bool(bool)
true / false.
Int(i64)
Float(f64)
Duration(i64)
A duration literal such as 500ms or 5s, normalised to nanoseconds.
Str(Vec<StringPart>)
DocComment(String)
/// text attached to the following declaration.
LParen
RParen
LBrace
RBrace
LBracket
RBracket
Comma
Colon
Dot
DotDot
DotDotLt
Ellipsis
Arrow
FatArrow
Question
Underscore
Eq
EqEq
Bang
BangEq
Lt
LtEq
Gt
GtEq
Plus
Minus
Star
Slash
Percent
AmpAmp
PipePipe
PlusEq
MinusEq
StarEq
SlashEq
PercentEq
Eof
Implementations§
Trait Implementations§
impl StructuralPartialEq for TokenKind
Auto Trait Implementations§
impl Freeze for TokenKind
impl RefUnwindSafe for TokenKind
impl Send for TokenKind
impl Sync for TokenKind
impl Unpin for TokenKind
impl UnsafeUnpin for TokenKind
impl UnwindSafe for TokenKind
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