pub enum HaskellTokenType {
Show 101 variants
Whitespace,
Newline,
Comment,
Case,
Class,
Data,
Default,
Deriving,
Do,
Else,
Foreign,
If,
Import,
In,
Infix,
Infixl,
Infixr,
Instance,
Let,
Module,
Newtype,
Of,
Then,
Type,
Where,
Underscore,
As,
Qualified,
Hiding,
Identifier,
Constructor,
Number,
Integer,
Float,
String,
StringLiteral,
Char,
CharLiteral,
Plus,
Minus,
Star,
Slash,
Percent,
Assign,
Equal,
NotEqual,
Less,
Greater,
LessEqual,
GreaterEqual,
And,
Or,
Arrow,
LeftArrow,
DoubleArrow,
Pipe,
Ampersand,
Bang,
Exclamation,
Question,
Colon,
DoubleColon,
Semicolon,
Comma,
Dot,
DoubleDot,
DotDot,
Dollar,
At,
Tilde,
Backslash,
Append,
LeftParen,
RightParen,
LeftBracket,
RightBracket,
LeftBrace,
RightBrace,
Quote,
Backquote,
Backtick,
Function,
DataDeclaration,
ModuleDeclaration,
ImportDeclaration,
TypeAliasDeclaration,
TypeSignature,
Equation,
Pattern,
LiteralExpression,
IdentifierExpression,
PrefixExpression,
InfixExpression,
ApplicationExpression,
LambdaExpression,
LetExpression,
CaseExpression,
CaseArm,
Root,
Error,
Eof,
}Expand description
Haskell token types. Token types for the Haskell language.
Variants§
Whitespace
Whitespace characters.
Newline
Newline characters.
Comment
Comments.
Case
case keyword.
Class
class keyword.
Data
data keyword.
Default
default keyword.
Deriving
deriving keyword.
Do
do keyword.
Else
else keyword.
Foreign
foreign keyword.
If
if keyword.
Import
import keyword.
In
in keyword.
Infix
infix keyword.
Infixl
infixl keyword.
Infixr
infixr keyword.
Instance
instance keyword.
Let
let keyword.
Module
module keyword.
Newtype
newtype keyword.
Of
of keyword.
Then
then keyword.
Type
type keyword.
Where
where keyword.
Underscore
_ keyword.
As
as keyword.
Qualified
qualified keyword.
Hiding
hiding keyword.
Identifier
An identifier.
Constructor
A constructor identifier.
Number
A number literal.
Integer
An integer literal.
Float
A float literal.
String
A string literal.
StringLiteral
A string literal.
Char
A char literal.
CharLiteral
A char literal.
Plus
+ operator.
Minus
- operator.
Star
* operator.
Slash
/ operator.
Percent
% operator.
Assign
= operator (assignment).
Equal
== operator.
NotEqual
/= operator.
Less
< operator.
Greater
> operator.
LessEqual
<= operator.
GreaterEqual
>= operator.
And
&& operator.
Or
|| operator.
Arrow
-> operator.
LeftArrow
<- operator.
DoubleArrow
=> operator.
Pipe
| operator.
Ampersand
& operator.
Bang
! operator.
Exclamation
! operator.
Question
? operator.
Colon
: operator.
DoubleColon
:: operator.
Semicolon
; punctuation.
Comma
, punctuation.
Dot
. operator.
DoubleDot
.. operator.
DotDot
.. operator.
Dollar
$ operator.
At
@ operator.
Tilde
~ operator.
Backslash
\ operator.
Append
++ operator.
LeftParen
( punctuation.
RightParen
) punctuation.
LeftBracket
[ punctuation.
RightBracket
] punctuation.
LeftBrace
{ punctuation.
RightBrace
} punctuation.
Quote
' punctuation.
Backquote
` punctuation.
Backtick
` punctuation.
Function
A function.
DataDeclaration
A data declaration.
ModuleDeclaration
A module declaration.
ImportDeclaration
An import declaration.
TypeAliasDeclaration
A type alias declaration.
TypeSignature
A type signature.
Equation
A function equation.
Pattern
A pattern.
LiteralExpression
A literal expression.
IdentifierExpression
An identifier expression.
PrefixExpression
A prefix expression.
InfixExpression
An infix expression.
ApplicationExpression
A function application.
LambdaExpression
A lambda expression.
LetExpression
A let expression.
CaseExpression
A case expression.
CaseArm
A case arm.
Root
Root element.
Error
Error token.
Eof
End of file token.
Implementations§
Source§impl HaskellTokenType
impl HaskellTokenType
Sourcepub fn is_keyword(&self) -> bool
pub fn is_keyword(&self) -> bool
Returns true if the token type is a keyword.
Trait Implementations§
Source§impl Clone for HaskellTokenType
impl Clone for HaskellTokenType
Source§fn clone(&self) -> HaskellTokenType
fn clone(&self) -> HaskellTokenType
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more