#[non_exhaustive]pub enum TokenKind {
Show 19 variants
LowerId {
qualifier: Option<ModuleName>,
name: Identifier,
},
UpperId {
qualifier: Option<ModuleName>,
name: Identifier,
},
Op(Operator),
IntLit(String),
DecimalLit(String),
StringLit(String),
CharLit(String),
LParen,
RParen,
LBracket,
RBracket,
LBrace,
RBrace,
Comma,
Semi,
Backtick,
VLBrace,
VRBrace,
VSemi,
}Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
LowerId
Lowercase-initial identifier, possibly qualified: foo, Map.lookup.
UpperId
Uppercase-initial identifier, possibly qualified: Foo, DA.Set.Set.
Op(Operator)
Symbolic operator: +, <-, ->, =, =>, ::, ., \, …
IntLit(String)
DecimalLit(String)
StringLit(String)
CharLit(String)
LParen
RParen
LBracket
RBracket
LBrace
RBrace
Comma
Semi
Backtick
VLBrace
Layout-inserted virtual open brace (block start).
VRBrace
Layout-inserted virtual close brace (block end).
VSemi
Layout-inserted virtual semicolon (new item at block indentation).
Implementations§
Trait Implementations§
impl Eq for TokenKind
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