We needed to calculate the remainder of a BigInt by BigInt in our substreams, hence I implemented the div_rem method under impl BigInt and added some units tests.
Alternative considerations
div_rem is implemented under impl Integer for BigInt for num_bigint::BigInt, see here, but that requires implementing many more methods that I am not sure are useful. Thoughts?
Description
We needed to calculate the remainder of a
BigInt
byBigInt
in our substreams, hence I implemented thediv_rem
method underimpl BigInt
and added some units tests.Alternative considerations
div_rem
is implemented underimpl Integer for BigInt
fornum_bigint::BigInt
, see here, but that requires implementing many more methods that I am not sure are useful. Thoughts?