def round
import bend-collections-laws-math@1.0.0.0/spec/math/f64.bend as F64import Base
import bend-collections-laws-math@1.0.0.0/src/math/f64.bend as F
import bend-collections-laws-math@1.0.0.0/src/math/natural.bend as M
179def round(+s: Bool, +m: Nat, +x: Nat) -> F.F64:
180 pick(F.F64, Nat.is_eq(m, 0n), zero(s), round_u(s, m, x, Nat.max(Nat.sub(Nat.add(x, M.bit_length(m)), 53n), Nat.sub(zb(), 1074n))))
Uses (12)
Used by (141)
- bend-collections-laws-math@1.0.0.0/spec/math/f64:to_integral
- bend-collections-laws-math@1.0.0.0/proofs/math/typed/f64rtools:round_shift
- bend-collections-laws-math@1.0.0.0/proofs/math/typed/f64tools:rw_value
- bend-collections-laws-math@1.0.0.0/spec/math/f64:rnear
- bend-collections-laws-math@1.0.0.0/proofs/math/typed/f64fmod:FM
- …