mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 06:14:46 +00:00
Move Int and Float modules into Num
This commit is contained in:
parent
d041355c1d
commit
88990c8711
26 changed files with 543 additions and 547 deletions
|
@ -308,7 +308,7 @@ enum IntOrFloat {
|
|||
/// Given the `a` in `Num a`, determines whether it's an int or a float
|
||||
fn num_argument_to_int_or_float(subs: &Subs, var: Variable) -> IntOrFloat {
|
||||
match subs.get_without_compacting(var).content {
|
||||
Content::Alias(Symbol::INT_INTEGER, args, _) => {
|
||||
Content::Alias(Symbol::NUM_INTEGER, args, _) => {
|
||||
debug_assert!(args.is_empty());
|
||||
IntOrFloat::IntType
|
||||
}
|
||||
|
@ -316,7 +316,7 @@ fn num_argument_to_int_or_float(subs: &Subs, var: Variable) -> IntOrFloat {
|
|||
// If this was still a (Num *), assume compiling it to an Int
|
||||
IntOrFloat::IntType
|
||||
}
|
||||
Content::Alias(Symbol::FLOAT_FLOATINGPOINT, args, _) => {
|
||||
Content::Alias(Symbol::NUM_FLOATINGPOINT, args, _) => {
|
||||
debug_assert!(args.is_empty());
|
||||
IntOrFloat::FloatType
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue