Skip to content

Commit

Permalink
use where clause for long trait bounds
Browse files Browse the repository at this point in the history
  • Loading branch information
xoloki committed Oct 9, 2024
1 parent 2089718 commit 2b6d213
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ pub struct Polynomial<Param, Arg> {
_x: std::marker::PhantomData<Arg>,
}

impl<
Param: Clone + Zero + Random + Add + AddAssign<<Arg as Mul<Param>>::Output>,
Arg: Clone + One + Mul<Param> + MulAssign,
> Polynomial<Param, Arg>
impl<Param, Arg> Polynomial<Param, Arg>
where
Param: Clone + Zero + Random + Add + AddAssign<<Arg as Mul<Param>>::Output>,
Arg: Clone + One + Mul<Param> + MulAssign,
{
/// construct new random polynomial of the specified degree
pub fn random<RNG: RngCore + CryptoRng>(n: u32, rng: &mut RNG) -> Self {
Expand Down

0 comments on commit 2b6d213

Please sign in to comment.