From 53d1fb882d179e9a690f9caaa332d3a7c53477b0 Mon Sep 17 00:00:00 2001 From: Hanno Braun Date: Sat, 23 Mar 2024 01:15:37 +0100 Subject: [PATCH] Remove unused argument --- .../fj-core/src/operations/build/half_edge.rs | 27 ++++++++----------- crates/fj-core/src/operations/join/cycle.rs | 2 +- 2 files changed, 12 insertions(+), 17 deletions(-) diff --git a/crates/fj-core/src/operations/build/half_edge.rs b/crates/fj-core/src/operations/build/half_edge.rs index 36004248b..53c3abcd5 100644 --- a/crates/fj-core/src/operations/build/half_edge.rs +++ b/crates/fj-core/src/operations/build/half_edge.rs @@ -2,7 +2,7 @@ use fj_interop::ext::ArrayExt; use fj_math::{Arc, Point, Scalar}; use crate::{ - geometry::{CurveBoundary, HalfEdgeGeometry, SurfacePath}, + geometry::{HalfEdgeGeometry, SurfacePath}, objects::{Curve, HalfEdge, Vertex}, operations::{geometry::UpdateHalfEdgeGeometry, insert::Insert}, storage::Handle, @@ -16,10 +16,7 @@ use crate::{ /// [module-level documentation]: super pub trait BuildHalfEdge { /// Create a half-edge that is not joined to a sibling - fn unjoined( - _: impl Into>>, - core: &mut Core, - ) -> HalfEdge { + fn unjoined(core: &mut Core) -> HalfEdge { let curve = Curve::new().insert(core); let start_vertex = Vertex::new().insert(core); @@ -63,7 +60,7 @@ pub trait BuildHalfEdge { let boundary = [arc.start_angle, arc.end_angle].map(|coord| Point::from([coord])); - let half_edge = HalfEdge::unjoined(boundary, core).insert(core); + let half_edge = HalfEdge::unjoined(core).insert(core); core.layers.geometry.define_half_edge( half_edge.clone(), HalfEdgeGeometry { @@ -85,7 +82,7 @@ pub trait BuildHalfEdge { let boundary = [Scalar::ZERO, Scalar::TAU].map(|coord| Point::from([coord])); - let half_edge = HalfEdge::unjoined(boundary, core).insert(core); + let half_edge = HalfEdge::unjoined(core).insert(core); core.layers.geometry.define_half_edge( half_edge.clone(), HalfEdgeGeometry { @@ -109,15 +106,13 @@ pub trait BuildHalfEdge { boundary.zip_ext(points_surface), ); - HalfEdge::unjoined(boundary, core) - .insert(core) - .set_geometry( - HalfEdgeGeometry { - path, - boundary: boundary.into(), - }, - &mut core.layers.geometry, - ) + HalfEdge::unjoined(core).insert(core).set_geometry( + HalfEdgeGeometry { + path, + boundary: boundary.into(), + }, + &mut core.layers.geometry, + ) } } diff --git a/crates/fj-core/src/operations/join/cycle.rs b/crates/fj-core/src/operations/join/cycle.rs index f28850262..5821a1d68 100644 --- a/crates/fj-core/src/operations/join/cycle.rs +++ b/crates/fj-core/src/operations/join/cycle.rs @@ -85,7 +85,7 @@ impl JoinCycle for Cycle { .into_iter() .circular_tuple_windows() .map(|((prev_half_edge, _), (half_edge, geometry))| { - HalfEdge::unjoined(geometry.boundary, core) + HalfEdge::unjoined(core) .update_curve(|_, _| half_edge.curve().clone(), core) .update_start_vertex( |_, _| prev_half_edge.start_vertex().clone(),