From 17b8b91f63a6c614f0a0ca10991edee6f52ca3d4 Mon Sep 17 00:00:00 2001 From: Hanno Braun Date: Sat, 9 Apr 2022 15:24:38 +0200 Subject: [PATCH] Add `PolyChain::reverse` --- fj-math/src/poly_chain.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/fj-math/src/poly_chain.rs b/fj-math/src/poly_chain.rs index f9726384e..0c762226d 100644 --- a/fj-math/src/poly_chain.rs +++ b/fj-math/src/poly_chain.rs @@ -51,6 +51,12 @@ impl PolyChain { self } + + /// Reverse the order of points in the `PolyChain` + pub fn reverse(mut self) -> Self { + self.points.reverse(); + self + } } impl Default for PolyChain {