From 7cb44bf790c2da648911d751d59d0739de37c392 Mon Sep 17 00:00:00 2001 From: Hanno Braun Date: Fri, 23 Feb 2024 13:08:23 +0100 Subject: [PATCH] Simplify argument of private function --- crates/fj-core/src/validate/shell.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/crates/fj-core/src/validate/shell.rs b/crates/fj-core/src/validate/shell.rs index acb1faa5b..25764efe2 100644 --- a/crates/fj-core/src/validate/shell.rs +++ b/crates/fj-core/src/validate/shell.rs @@ -4,7 +4,7 @@ use fj_math::{Point, Scalar}; use crate::{ geometry::{CurveBoundary, SurfaceGeometry}, - objects::{Curve, HalfEdge, Shell, Surface, Vertex}, + objects::{Curve, HalfEdge, Shell, Vertex}, queries::{ AllHalfEdgesWithSurface, BoundingVerticesOfHalfEdge, SiblingOfHalfEdge, }, @@ -237,7 +237,7 @@ impl ShellValidationError { half_edge_a.clone(), &surface_a.geometry(), half_edge_b.clone(), - surface_b.clone(), + &surface_b.geometry(), ) .all(|d| d < config.distinct_min_distance) { @@ -361,7 +361,7 @@ fn distances( edge_a: Handle, surface_a: &SurfaceGeometry, edge_b: Handle, - surface_b: Handle, + surface_b: &SurfaceGeometry, ) -> impl Iterator { fn sample( percent: f64, @@ -383,7 +383,7 @@ fn distances( for i in 0..sample_count { let percent = i as f64 * step; let sample1 = sample(percent, (&edge_a, surface_a)); - let sample2 = sample(1.0 - percent, (&edge_b, &surface_b.geometry())); + let sample2 = sample(1.0 - percent, (&edge_b, surface_b)); distances.push(sample1.distance_to(&sample2)) } distances.into_iter()