Move integer and char parsing out of the parser and back into the lexer

This commit is contained in:
2025-10-10 14:45:08 -04:00
parent 0cbb800c19
commit b5d552376e
4 changed files with 114 additions and 37 deletions

View File

@@ -75,10 +75,9 @@ fn lex() -> Result<(), Box<dyn Error>> {
println!("\x1b[31m{e}\x1b[0m");
break Ok(Response::Deny);
}
Ok(Token { lexeme, kind, span: Span { head, tail } }) => println!(
"{kind:?}\x1b[11G {head:<4} {tail:<4} {}",
lexeme.escape_debug()
),
Ok(Token { lexeme, kind, span: Span { head, tail } }) => {
println!("{kind:?}\x1b[11G {head:<4} {tail:<4} {lexeme:?}")
}
}
}
})?;