Rename (Un)TypedExpr.Int -> (Un)TypedExpr.UInt
We do not actually every parse negative values in there, as a negative value is a combination of a 'Negate' and 'UInt' expression. However, for patterns and constant, it'll be simpler to parse whole Int values as there's no ambiguity with arithmetic operations there. To avoid confusion of having some 'Int' constructors containing only non-negative values, and some being on the whole range, I've renamed the constructor to 'UInt' to make this more obvious.
This commit is contained in:
@@ -2,9 +2,7 @@ use chumsky::prelude::*;
|
||||
|
||||
use crate::{
|
||||
ast,
|
||||
parser::{
|
||||
annotation, error::ParseError, literal::bytearray::parser as bytearray, token::Token, utils,
|
||||
},
|
||||
parser::{annotation, error::ParseError, literal::bytearray, token::Token, utils},
|
||||
};
|
||||
|
||||
pub fn parser() -> impl Parser<Token, ast::UntypedDefinition, Error = ParseError> {
|
||||
|
||||
Reference in New Issue
Block a user