Use divTruncChecked over divFloorChecked in Deriv

This commit is contained in:
Richard Feldman 2022-04-23 19:35:15 -04:00
parent 95ca4d48e5
commit 05164aad4b
No known key found for this signature in database
GPG Key ID: 7E4127D1E4241798

View File

@ -41,7 +41,7 @@ Expr : [ Val I64, Var Str, Add Expr Expr, Mul Expr Expr, Pow Expr Expr, Ln Expr
divmod : I64, I64 -> Result { div : I64, mod : I64 } [ DivByZero ]*
divmod = \l, r ->
when Pair (Num.divFloorChecked l r) (Num.remChecked l r) is
when Pair (Num.divTruncChecked l r) (Num.remChecked l r) is
Pair div (Ok mod) ->
Ok { div, mod }