Parse negative numbers

pull/25/head
Ethan Reece 2023-09-30 04:35:15 -05:00
parent d14c5ace00
commit d40467bc00
Signed by: me
GPG Key ID: D3993665FF92E1C3
2 changed files with 2 additions and 2 deletions

View File

@ -1 +1 @@
5*3+2 5*3-2+-4-4

View File

@ -23,7 +23,7 @@ symbol :: Text -> Parser Text
symbol = L.symbol C.space symbol = L.symbol C.space
int :: Parser Int int :: Parser Int
int = lexeme L.decimal int = lexeme $ L.signed (return ()) L.decimal
term :: Parser Expr term :: Parser Expr
term = Lit <$> int term = Lit <$> int