From e51d7c723c7b6c49d1d132bc7084eac95059aa3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9ctor=20Ram=C3=B3n=20Jim=C3=A9nez?= Date: Thu, 20 Nov 2025 02:03:01 +0100 Subject: [PATCH] Remove `Mul` and `Div` implementations for `Rectangle` --- core/src/rectangle.rs | 45 ------------------------------------------- 1 file changed, 45 deletions(-) diff --git a/core/src/rectangle.rs b/core/src/rectangle.rs index afc15cc8..e417d08d 100644 --- a/core/src/rectangle.rs +++ b/core/src/rectangle.rs @@ -354,19 +354,6 @@ impl std::ops::Mul for Rectangle { } } -impl std::ops::Div for Rectangle { - type Output = Self; - - fn div(self, scale: f32) -> Self { - Self { - x: self.x / scale, - y: self.y / scale, - width: self.width / scale, - height: self.height / scale, - } - } -} - impl From> for Rectangle { fn from(rectangle: Rectangle) -> Rectangle { Rectangle { @@ -407,35 +394,3 @@ where } } } - -impl std::ops::Mul> for Rectangle -where - T: std::ops::Mul + Copy, -{ - type Output = Rectangle; - - fn mul(self, scale: Vector) -> Self { - Rectangle { - x: self.x * scale.x, - y: self.y * scale.y, - width: self.width * scale.x, - height: self.height * scale.y, - } - } -} - -impl std::ops::Div> for Rectangle -where - T: std::ops::Div + Copy, -{ - type Output = Rectangle; - - fn div(self, scale: Vector) -> Self { - Rectangle { - x: self.x / scale.x, - y: self.y / scale.y, - width: self.width / scale.x, - height: self.height / scale.y, - } - } -}