def DivSmall.quotient

bend-collections-laws-math@1.0.0.0 · spec/math/u64.bend:48

import bend-collections-laws-math@1.0.0.0/spec/math/u64.bend as U64
import Base
import bend-collections-laws-math@1.0.0.0/spec/lib/numeric.bend as N
import bend-collections-laws-math@1.0.0.0/src/math/u64.bend as U

48# divisors 1 .. 2^20 (the limb division stays inside 32 bits)
49def DivSmall.quotient(+a: U.U64, +d: U32, +hd0: {U32.is_zero(d) == False{} : Bool}, +hle: {U32.is_le(d, 1048576) == True{} : Bool}) -> Type:
50  {bits(U.div_small(a, d)) == N.unsigned_quotient(64n, bits(a), d) : Word(64n)}

Uses (9)

Used by (1)