Add parsing negative numbers

This commit is contained in:
Alex Bethel 2021-08-30 15:03:29 -06:00
parent 2c36b2a5f7
commit 6f8a49b711

View file

@ -139,7 +139,7 @@ pub enum Token {
String(String),
/// Integer
#[regex(r"[0-9]+", get_int)]
#[regex(r"-?[0-9]+", get_int)]
Integer(i32),
/// A C-complaint identifier