refactor Ord to be based on compare

This commit is contained in:
2024-12-29 16:16:49 -08:00
parent 413f95940f
commit 6397cac18a
11 changed files with 47 additions and 57 deletions

View File

@@ -23,7 +23,7 @@ instance Sub BigInt where a - b = subbi a b
instance Cast Int BigInt where cast x = itobi x
instance Eq BigInt where a == b = jsEq a b
instance Show BigInt where show = jsShow
instance Ord BigInt where a < b = jsLT a b
instance Ord BigInt where compare a b = jsCompare a b
infixl 7 _%_
pfunc _%_ : BigInt BigInt BigInt := `(x,y) => x % y`