Skip to content

Commit ee41586

Browse files
Fix clippy::match_wildcard_for_single_variants lints (#421)
1 parent b487bda commit ee41586

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/bezpath.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ impl BezPath {
323323
PathEl::LineTo(p) => p,
324324
PathEl::QuadTo(_, p2) => p2,
325325
PathEl::CurveTo(_, _, p3) => p3,
326-
_ => return None,
326+
PathEl::ClosePath => return None,
327327
};
328328
match self.0[ix] {
329329
PathEl::LineTo(p) => Some(PathSeg::Line(Line::new(last, p))),
@@ -335,7 +335,7 @@ impl BezPath {
335335
}
336336
_ => None,
337337
}),
338-
_ => None,
338+
PathEl::MoveTo(_) => None,
339339
}
340340
}
341341

@@ -1355,7 +1355,7 @@ impl PathEl {
13551355
PathEl::LineTo(p1) => Some(*p1),
13561356
PathEl::QuadTo(_, p2) => Some(*p2),
13571357
PathEl::CurveTo(_, _, p3) => Some(*p3),
1358-
_ => None,
1358+
PathEl::ClosePath => None,
13591359
}
13601360
}
13611361
}

0 commit comments

Comments
 (0)