Skip to content

Commit

Permalink
removing dependency on circular-vector
Browse files Browse the repository at this point in the history
  • Loading branch information
noinia authored Aug 19, 2024
1 parent 98e6840 commit 02a69d3
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 22 deletions.
10 changes: 0 additions & 10 deletions cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,6 @@ packages:
-- ../miso-bulma

allow-newer:
vector-circular:vector,
vector-circular:base,
vector-circular:template-haskell,
vector-circular:semigroupoids,
vector-circular:primitive,
vector-circular:deepseq,
pretty:deepseq,
pretty:dlist,
geojson:deepseq,
Expand Down Expand Up @@ -51,10 +45,6 @@ source-repository-package
-- location: https://github.com/noinia/miso
-- tag: 1d16ba220bcd6be28d1e89d141330cd6875c70ff

source-repository-package
type: git
location: https://github.com/noinia/vector-circular
tag: 98090784e9ed97cf761cf69ad3f32b88dbdd30a2

package miso
flags: +jsaddle
1 change: 0 additions & 1 deletion hgeometry-combinatorial/hgeometry-combinatorial.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ common setup
, vector-builder >= 0.3.7 && < 1
, vector-algorithms >= 0.8 && < 1
, nonempty-vector >= 0.2.3 && < 1
, vector-circular >= 0.1.4 && < 1
, linear >= 1.20 && < 2
, HsYAML >= 0.2 && < 1
, aeson >= 2.0 && < 3
Expand Down
7 changes: 0 additions & 7 deletions hgeometry-combinatorial/src/HGeometry/Cyclic.hs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
--------------------------------------------------------------------------------
module HGeometry.Cyclic
( Cyclic(..)
, toCircularVector
, HasDirectedTraversals(..)
, ShiftedEq(..)
) where
Expand All @@ -29,7 +28,6 @@ import qualified Data.List.NonEmpty as NonEmpty
import Data.Maybe (isJust)
import Data.Semigroup.Foldable
import qualified Data.Vector as V
import Data.Vector.Circular (CircularVector(..))
import qualified Data.Vector.Mutable as MV
import qualified Data.Vector.NonEmpty as NV
import GHC.Generics (Generic)
Expand Down Expand Up @@ -78,11 +76,6 @@ instance (Index (v a) ~ Int, Foldable v, Ixed (v a)) => Ixed (Cyclic v a) where
instance Reversing (v a) => Reversing (Cyclic v a) where
reversing (Cyclic v) = Cyclic (reversing v)

-- | Turn the cyclic vector into a circular Vector
toCircularVector :: Cyclic NV.NonEmptyVector a -> CircularVector a
toCircularVector (Cyclic v) = CircularVector v 0


-- | Class that models that some type has a cyclic traversal starting
-- from a particular index.
class HasDirectedTraversals v where
Expand Down
6 changes: 2 additions & 4 deletions hgeometry/src/HGeometry/Polygon/Convex/Tangents.hs
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,13 @@ import Data.Monoid
import Data.Ord (comparing)
import Data.Semigroup.Foldable (Foldable1 (..))
import HGeometry.Ext
-- import Data.Vector.Circular (CircularVector)
-- import qualified Data.Vector.Circular as CV
-- import qualified Data.Vector.Circular.Util as CV
import HGeometry.LineSegment
import HGeometry.Point
import HGeometry.Polygon.Class
import HGeometry.Polygon.Convex.Class
import HGeometry.Vector
import HGeometry.Polygon.Convex.Implementation (findMaxWith)
import HGeometry.Vector

--------------------------------------------------------------------------------

-- | Given a convex polygon poly, and a point outside the polygon, find the
Expand Down

0 comments on commit 02a69d3

Please sign in to comment.