steal from jai

This commit is contained in:
2026-06-01 22:40:24 -04:00
parent d864adfd05
commit 1d568f8ce3
17 changed files with 231 additions and 84 deletions
+2 -5
View File
@@ -26,7 +26,6 @@ def_tokens! {
DashEqual: "-=",
AsteriskEqual: "*=",
SlashEqual: "/=",
DoubleColon: "::",
Hash: "#",
}
keyword {
@@ -38,6 +37,7 @@ def_tokens! {
While: "while",
For: "for",
Match: "match",
Break: "break",
}
other {
Ident(String),
@@ -112,10 +112,7 @@ impl Iterator for Tokens<'_> {
_ => Token::Slash,
'=' => Token::SlashEqual,
},
':' => then! {
_ => Token::Colon,
':' => Token::DoubleColon,
},
':' => Token::Colon,
';' => Token::Semicolon,
'=' => then! {
_ => Token::Equal,