Inversed-Tech / eyelid

Private iris matching
Apache License 2.0
0 stars 0 forks source link

Fix panic bugs in `ark_poly` Add and Sub impls #43

Open teor2345 opened 3 months ago

teor2345 commented 3 months ago

Some missing truncate_leading_zeroes() in ark_poly operator impls can cause a panic in degree():

We can submit a PR to ark_poly, get it merged, and then upgrade to the next release.

In the meantime, we can add a truncate_to_canonical_form() in our own Poly impls. This means we can't use derive_more macros, unless the underlying implementation is correct.

teor2345 commented 3 months ago

Currently this is fixed by depending on https://github.com/arkworks-rs/algebra/pull/638 via https://github.com/arkworks-rs/algebra/commit/8233e9a3fc63370aef65ed24e0c7f6e07dac43e6 in PR #32.

We don't use SparsePolynomial, so this bug shouldn't happen to us.