Add parsing negative numbers

This commit is contained in:
Alex Bethel 2021-08-30 15:03:29 -06:00
parent 1d24082ee8
commit a3b6ae326e

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