store is_negative for all number literals in the parse ast

This commit is contained in:
Folkert 2021-03-12 16:11:46 +01:00
parent 866fa14590
commit 182fd5201d
12 changed files with 142 additions and 46 deletions

View file

@ -24,8 +24,8 @@ impl<'a> Formattable<'a> for Expr<'a> {
}
// These expressions never have newlines
Float(_)
| Num(_)
Float { .. }
| Num { .. }
| NonBase10Int { .. }
| Access(_, _)
| AccessorFunction(_)
@ -218,7 +218,7 @@ impl<'a> Formattable<'a> for Expr<'a> {
buf.push(')');
}
}
Num(string) | Float(string) | GlobalTag(string) | PrivateTag(string) => {
Num { string, .. } | Float { string, .. } | GlobalTag(string) | PrivateTag(string) => {
buf.push_str(string)
}
NonBase10Int {