Skip to content

Commit

Permalink
Fix clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
yczhangsjtu committed Feb 25, 2025
1 parent c2ffb2a commit a96a309
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions mpcs/src/whir/field_wrapper.rs
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,7 @@ impl<E: FfExtField> Distribution<ExtensionFieldWrapper<E>> for Standard {
impl<E: FfExtField> Div for ExtensionFieldWrapper<E> {
type Output = Self;

#[allow(clippy::suspicious_arithmetic_impl)]
fn div(self, other: Self) -> Self {
Self(self.0 * other.0.inverse())
}
Expand All @@ -132,6 +133,7 @@ impl<E: FfExtField> Div for ExtensionFieldWrapper<E> {
impl<'a, E: FfExtField> Div<&'a Self> for ExtensionFieldWrapper<E> {
type Output = Self;

#[allow(clippy::suspicious_arithmetic_impl)]
fn div(self, rhs: &'a Self) -> Self::Output {
Self(self.0 * rhs.0.inverse())
}
Expand All @@ -140,6 +142,7 @@ impl<'a, E: FfExtField> Div<&'a Self> for ExtensionFieldWrapper<E> {
impl<'a, E: FfExtField> Div<&'a mut Self> for ExtensionFieldWrapper<E> {
type Output = Self;

#[allow(clippy::suspicious_arithmetic_impl)]
fn div(self, rhs: &'a mut Self) -> Self::Output {
Self(self.0 * rhs.0.inverse())
}
Expand Down
3 changes: 3 additions & 0 deletions mpcs/src/whir/field_wrapper/base.rs
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ impl<E: FfExtField> Distribution<BaseFieldWrapper<E>> for Standard {
impl<E: FfExtField> Div for BaseFieldWrapper<E> {
type Output = Self;

#[allow(clippy::suspicious_arithmetic_impl)]
fn div(self, other: Self) -> Self {
Self(self.0 * other.0.inverse())
}
Expand All @@ -88,6 +89,7 @@ impl<E: FfExtField> Div for BaseFieldWrapper<E> {
impl<'a, E: FfExtField> Div<&'a Self> for BaseFieldWrapper<E> {
type Output = Self;

#[allow(clippy::suspicious_arithmetic_impl)]
fn div(self, rhs: &'a Self) -> Self::Output {
Self(self.0 * rhs.0.inverse())
}
Expand All @@ -96,6 +98,7 @@ impl<'a, E: FfExtField> Div<&'a Self> for BaseFieldWrapper<E> {
impl<'a, E: FfExtField> Div<&'a mut Self> for BaseFieldWrapper<E> {
type Output = Self;

#[allow(clippy::suspicious_arithmetic_impl)]
fn div(self, rhs: &'a mut Self) -> Self::Output {
Self(self.0 * rhs.0.inverse())
}
Expand Down

0 comments on commit a96a309

Please sign in to comment.