diff --git a/crates/fj-kernel/src/builder/cycle.rs b/crates/fj-kernel/src/builder/cycle.rs index 5d5a62e87..04251a2fc 100644 --- a/crates/fj-kernel/src/builder/cycle.rs +++ b/crates/fj-kernel/src/builder/cycle.rs @@ -12,7 +12,7 @@ pub trait CycleBuilder { /// Update the partial cycle with a polygonal chain from the provided points fn with_poly_chain( self, - vertices: impl IntoIterator>, + vertices: impl IntoIterator>>, ) -> Self; /// Update the partial cycle with a polygonal chain from the provided points @@ -30,8 +30,10 @@ pub trait CycleBuilder { impl CycleBuilder for PartialCycle { fn with_poly_chain( self, - vertices: impl IntoIterator>, + vertices: impl IntoIterator>>, ) -> Self { + let vertices = vertices.into_iter().map(Into::into); + let iter = self .half_edges() .last() @@ -100,9 +102,7 @@ impl CycleBuilder for PartialCycle { points: impl IntoIterator>>, ) -> Self { self.with_poly_chain(points.into_iter().map(|position| { - SurfaceVertex::partial() - .with_position(Some(position)) - .into() + SurfaceVertex::partial().with_position(Some(position)) })) }