Structsยง
- Lexer
Result - Lexer
State ๐ - Lexer state for tracking position during tokenization
Functionsยง
- handle_
ampersand ๐ - Handles ampersand character (logical AND)
- handle_
block_ ๐comment - Handles multi-line block comments
- handle_
dash ๐ - Handles dash character (minus or arrow)
- handle_
equals ๐ - Handles equals character (assignment or equality)
- handle_
exclamation ๐ - Handles exclamation mark (not or not equal)
- handle_
greater_ ๐than - Handles greater than character (greater than or greater than or equal)
- handle_
identifier ๐ - Handles alphabetic identifiers and keywords
- handle_
invalid_ ๐char - Handles invalid characters
- handle_
less_ ๐than - Handles less than character (less than or less than or equal)
- handle_
line_ ๐comment - Handles single-line comments
- handle_
number ๐ - Handles numeric literals (integers and floating point)
- handle_
pipe ๐ - Handles pipe character (logical OR)
- handle_
simple_ ๐token - Handles simple one-character tokens
- handle_
slash ๐ - Handles slash character (divide or comments)
- handle_
string ๐ - Handles string literals
- handle_
whitespace ๐ - Handles whitespace characters in the input
- tokenize
- Converts source code text into a sequence of tokens with line information