mirror of
https://github.com/starovoid/rxing.git
synced 2026-07-26 04:12:34 +00:00
clippy --fix
This commit is contained in:
@@ -45,9 +45,8 @@ impl GridSampler for DefaultGridSampler {
|
||||
// To deal with remaining examples (see #251 and #267) of "numercial instabilities" that have not been
|
||||
// prevented with the Quadrilateral.h:IsConvex() check, we check for all boundary points of the grid to
|
||||
// be inside.
|
||||
let isInside = |p: Point| -> bool {
|
||||
return image.is_in(transform.transform_point(p.centered()));
|
||||
};
|
||||
let isInside =
|
||||
|p: Point| -> bool { image.is_in(transform.transform_point(p.centered())) };
|
||||
for y in (p0.y as i32)..(p1.y as i32) {
|
||||
// for (int y = y0; y < y1; ++y)
|
||||
if !isInside(point(p0.x, y as f32)) || !isInside(point(p1.x - 1.0, y as f32)) {
|
||||
|
||||
@@ -171,7 +171,7 @@ impl Quadrilateral {
|
||||
|
||||
let mirror = if let Some(m) = mirror { m } else { false };
|
||||
|
||||
let mut res = self.clone();
|
||||
let mut res = *self;
|
||||
res.0.rotate_left(((n + 4) % 4) as usize);
|
||||
// std::rotate_copy(q.begin(), q.begin() + ((n + 4) % 4), q.end(), res.begin());
|
||||
if mirror {
|
||||
|
||||
Reference in New Issue
Block a user