rust/integral-geometry/src/lib.rs
branchtransitional_engine
changeset 16051 2003b466b279
parent 15948 9bd828451d77
parent 16010 5ba4d3a0c3eb
child 16056 d4675c190fa5
--- a/rust/integral-geometry/src/lib.rs	Wed Aug 28 15:31:51 2024 +0200
+++ b/rust/integral-geometry/src/lib.rs	Wed Aug 28 15:34:49 2024 +0200
@@ -59,7 +59,7 @@
 
     #[inline]
     pub const fn rotate90(self) -> Self {
-        Point::new(self.y, -self.x)
+        Self::new(self.y, -self.x)
     }
 
     #[inline]
@@ -68,8 +68,8 @@
     }
 
     #[inline]
-    pub fn clamp(self, rect: &Rect) -> Point {
-        Point::new(rect.x_range().clamp(self.x), rect.y_range().clamp(self.y))
+    pub fn clamp(self, rect: &Rect) -> Self {
+        Self::new(rect.x_range().clamp(self.x), rect.y_range().clamp(self.y))
     }
 
     #[inline]