class Axal::Lexer
- Axal::Lexer
- Reference
- Object
Defined in:
lang/lexer.crConstant Summary
-
KEYWORD =
["and", "else", "end", "false", "fn", "if", "nil", "or", "return", "true", "while", "mod", "fget", "describe", "it"]
-
ONE_CHAR_LEX =
["(", ")", ":", ",", ".", "-", "+", "/", "*", "[", "]", "{", "}"]
-
ONE_OR_TWO_CHAR_LEX =
["!", "=", ">", "<"]
-
WHITESPACE =
[" ", "\r", "\t"]
Constructors
Instance Method Summary
- #after_source_end_location
- #alpha?(c : String)
- #alpha_numeric?(c : String)
- #consume : String
- #consume_digits
- #current_location
- #digit?(c : String)
- #external_code
- #identifier
- #ignore_comment_line
- #lookahead(offset = 1) : String
- #number
- #source : String
- #source_completed?
- #source_uncompleted?
- #start_tokenization
- #string
- #token_from_one_char_lex(lexeme)
- #token_from_one_or_two_char_lex(lexeme)
-
#tokenize
ameba:disable Metrics/CyclomaticComplexity
- #tokens : Array(Token)
- #triangle