Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/tealang.pest
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ double_colon = { "::" }
// Example: "&[i32]" in function parameters
ampersand = { "&" }

// Literals and identifiers
// Numeric literal: zero or a non-zero digit followed by any digits
// Examples: "0", "1", "10", "48", "57", "1005"
num = @{
Expand Down Expand Up @@ -109,7 +108,7 @@ kw_i32 = @{ "i32" ~ &(WHITESPACE | semicolon | comma | rparen | lbrace | rbrace
kw_use = @{ "use" ~ WHITESPACE }

// Identifier: starts with letter or underscore, followed by letters, digits, or underscores
// Cannot be a keyword (enforced by negative lookaheads)
// Cannot be a keyword: this step is performed after the keyword is recognized.
// Examples: "x", "count", "my_getint", "quickread", "arr", "head", "tail", "inq"
identifier = @{
(ASCII_ALPHA | "_") ~ (ASCII_ALPHA | ASCII_DIGIT | "_")*
Expand Down
Loading