mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-02 16:21:11 +00:00
Code gen numeric comparisons
This commit is contained in:
parent
d751327914
commit
c39b43a265
6 changed files with 197 additions and 13 deletions
|
@ -241,7 +241,7 @@ pub fn types() -> MutMap<Symbol, (SolvedType, Region)> {
|
|||
|
||||
// isLte or (<=) : Num a, Num a -> Bool
|
||||
add_type(
|
||||
Symbol::NUM_LE,
|
||||
Symbol::NUM_LTE,
|
||||
SolvedType::Func(
|
||||
vec![num_type(flex(TVAR1)), num_type(flex(TVAR1))],
|
||||
Box::new(bool_type()),
|
||||
|
@ -259,7 +259,7 @@ pub fn types() -> MutMap<Symbol, (SolvedType, Region)> {
|
|||
|
||||
// isGte or (>=) : Num a, Num a -> Bool
|
||||
add_type(
|
||||
Symbol::NUM_GE,
|
||||
Symbol::NUM_GTE,
|
||||
SolvedType::Func(
|
||||
vec![num_type(flex(TVAR1)), num_type(flex(TVAR1))],
|
||||
Box::new(bool_type()),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue