Skip to content

Commit

Permalink
cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
jgcodes2020 committed Jan 14, 2025
1 parent c657357 commit 5ab5eff
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 8 deletions.
4 changes: 1 addition & 3 deletions graphene/src/matrix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ impl ops::Mul<Vec4> for Matrix {

impl ops::Mul<Vec3> for Matrix {
type Output = Vec3;

fn mul(self, rhs: Vec3) -> Self::Output {
(&self).transform_vec3(&rhs)
}
Expand All @@ -267,7 +267,6 @@ impl ops::Mul<Point> for Matrix {
}
}


impl ops::Mul<Point3D> for Matrix {
type Output = Point3D;

Expand All @@ -276,7 +275,6 @@ impl ops::Mul<Point3D> for Matrix {
}
}


#[cfg(test)]
mod tests {
use super::Matrix;
Expand Down
2 changes: 1 addition & 1 deletion graphene/src/quaternion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -172,4 +172,4 @@ impl ops::MulAssign<Quaternion> for Quaternion {
fn mul_assign(&mut self, rhs: Quaternion) {
*self = *self * rhs;
}
}
}
4 changes: 2 additions & 2 deletions graphene/src/vec2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ impl ops::Mul<f32> for Vec2 {
fn mul(self, rhs: f32) -> Self::Output {
(&self).scale(rhs)
}
}
}
impl ops::MulAssign<f32> for Vec2 {
fn mul_assign(&mut self, rhs: f32) {
*self = *self * rhs;
Expand Down Expand Up @@ -131,4 +131,4 @@ impl ops::DivAssign<Vec2> for Vec2 {
fn div_assign(&mut self, rhs: Vec2) {
*self = *self / rhs;
}
}
}
2 changes: 1 addition & 1 deletion graphene/src/vec3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ impl ops::Mul<f32> for Vec3 {
fn mul(self, rhs: f32) -> Self::Output {
(&self).scale(rhs)
}
}
}
impl ops::MulAssign<f32> for Vec3 {
fn mul_assign(&mut self, rhs: f32) {
*self = *self * rhs;
Expand Down
2 changes: 1 addition & 1 deletion graphene/src/vec4.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ impl ops::Mul<f32> for Vec4 {
fn mul(self, rhs: f32) -> Self::Output {
(&self).scale(rhs)
}
}
}
impl ops::MulAssign<f32> for Vec4 {
fn mul_assign(&mut self, rhs: f32) {
*self = *self * rhs;
Expand Down

0 comments on commit 5ab5eff

Please sign in to comment.