pub enum SchemeTokenType {
Show 44 variants
Whitespace,
Newline,
Comment,
LineComment,
NumberLiteral,
StringLiteral,
CharacterLiteral,
BooleanLiteral,
Identifier,
Symbol,
Keyword,
Define,
Lambda,
If,
Cond,
Case,
Let,
LetStar,
Letrec,
Begin,
Do,
Quote,
Quasiquote,
Unquote,
UnquoteSplicing,
And,
Or,
Not,
Set,
LeftParen,
RightParen,
LeftBracket,
RightBracket,
LeftBrace,
RightBrace,
Dot,
Hash,
Quote_,
Quasiquote_,
Unquote_,
UnquoteSplicing_,
Error,
Eof,
SourceFile,
}Expand description
Token types for the Scheme language.
Variants§
Whitespace
Whitespace.
Newline
A newline.
Comment
A comment.
LineComment
A line comment.
NumberLiteral
A numeric literal.
StringLiteral
A string literal.
CharacterLiteral
A character literal.
BooleanLiteral
A boolean literal.
Identifier
An identifier.
Symbol
A symbol.
Keyword
A keyword.
Define
define keyword.
Lambda
lambda keyword.
If
if keyword.
Cond
cond keyword.
Case
case keyword.
Let
let keyword.
LetStar
let* keyword.
Letrec
letrec keyword.
Begin
begin keyword.
Do
do keyword.
Quote
quote keyword.
Quasiquote
quasiquote keyword.
Unquote
unquote keyword.
UnquoteSplicing
unquote-splicing keyword.
And
and keyword.
Or
or keyword.
Not
not keyword.
Set
set! keyword.
LeftParen
(.
RightParen
).
LeftBracket
[.
RightBracket
].
LeftBrace
{.
RightBrace
}.
Dot
..
Hash
#.
Quote_
'.
Quasiquote_
`.
Unquote_
,.
UnquoteSplicing_
,@.
Error
An error token.
Eof
End of stream.
SourceFile
A source file.
Trait Implementations§
Source§impl Clone for SchemeTokenType
impl Clone for SchemeTokenType
Source§fn clone(&self) -> SchemeTokenType
fn clone(&self) -> SchemeTokenType
Returns a duplicate 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 SchemeTokenType
impl Debug for SchemeTokenType
Source§impl<'de> Deserialize<'de> for SchemeTokenType
impl<'de> Deserialize<'de> for SchemeTokenType
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<SchemeTokenType> for SchemeElementType
impl From<SchemeTokenType> for SchemeElementType
Source§fn from(token: SchemeTokenType) -> Self
fn from(token: SchemeTokenType) -> Self
Converts to this type from the input type.
Source§impl Hash for SchemeTokenType
impl Hash for SchemeTokenType
Source§impl PartialEq for SchemeTokenType
impl PartialEq for SchemeTokenType
Source§impl Serialize for SchemeTokenType
impl Serialize for SchemeTokenType
Source§impl TokenType for SchemeTokenType
impl TokenType for SchemeTokenType
Source§const END_OF_STREAM: Self = Self::Eof
const END_OF_STREAM: Self = Self::Eof
A constant representing the end of the input stream.
Source§type Role = UniversalTokenRole
type Role = UniversalTokenRole
The associated role type for this token kind.
Source§fn is_ignored(&self) -> bool
fn is_ignored(&self) -> bool
Returns true if this token represents trivia (whitespace, comments, etc.).
Source§fn is_role(&self, role: Self::Role) -> bool
fn is_role(&self, role: Self::Role) -> bool
Returns true if this token matches the specified language-specific role.
Source§fn is_universal(&self, role: UniversalTokenRole) -> bool
fn is_universal(&self, role: UniversalTokenRole) -> bool
Returns true if this token matches the specified universal role.
Source§fn is_comment(&self) -> bool
fn is_comment(&self) -> bool
Returns true if this token represents a comment.
Source§fn is_whitespace(&self) -> bool
fn is_whitespace(&self) -> bool
Returns true if this token represents whitespace.
Source§fn is_end_of_stream(&self) -> bool
fn is_end_of_stream(&self) -> bool
Returns true if this token represents the end of the input stream.
impl Copy for SchemeTokenType
impl Eq for SchemeTokenType
impl StructuralPartialEq for SchemeTokenType
Auto Trait Implementations§
impl Freeze for SchemeTokenType
impl RefUnwindSafe for SchemeTokenType
impl Send for SchemeTokenType
impl Sync for SchemeTokenType
impl Unpin for SchemeTokenType
impl UnsafeUnpin for SchemeTokenType
impl UnwindSafe for SchemeTokenType
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