This PR changes the YasheParams struct into a YasheConf trait. As part of that change, the YasheConf trait is implemented for the existing polynomial config marker structs. There is also a convenience method for converting T to the Coeff type.
YASHE also needs some specific conversions on Coeff, they are added as trait bounds. Unfortunately these bounds need to be repeated on every generic type, impl, and function. (But the compiler will tell you where.)
I fixed a reduction bug in polynomials, where the modular reduction was skipped.
I also changed some clippy lints. I noticed an undocumented unwrap() from a previous PR, this is clearer as an expect().
This PR depends on #79.
This PR changes the
YasheParams
struct into aYasheConf
trait. As part of that change, theYasheConf
trait is implemented for the existing polynomial config marker structs. There is also a convenience method for convertingT
to theCoeff
type.YASHE also needs some specific conversions on
Coeff
, they are added as trait bounds. Unfortunately these bounds need to be repeated on every generic type, impl, and function. (But the compiler will tell you where.)I fixed a reduction bug in polynomials, where the modular reduction was skipped.
I also changed some clippy lints. I noticed an undocumented
unwrap()
from a previous PR, this is clearer as anexpect()
.Close #59.