From 7e22e2d45293c5916812be03dc7367134b69b3ad Mon Sep 17 00:00:00 2001 From: Héctor Ramón Jiménez Date: Thu, 3 Nov 2022 04:53:27 +0100 Subject: Fix lints by `clippy` --- graphics/src/gradient/linear.rs | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'graphics/src/gradient/linear.rs') diff --git a/graphics/src/gradient/linear.rs b/graphics/src/gradient/linear.rs index aaa9e234..439e848e 100644 --- a/graphics/src/gradient/linear.rs +++ b/graphics/src/gradient/linear.rs @@ -36,12 +36,9 @@ pub enum Position { }, } -impl Into for (Point, Point) { - fn into(self) -> Position { - Position::Absolute { - start: self.0, - end: self.1, - } +impl From<(Point, Point)> for Position { + fn from((start, end): (Point, Point)) -> Self { + Self::Absolute { start, end } } } -- cgit