ListZipper 1.1.0.0 → 1.1.1.0
raw patch · 2 files changed
+11/−3 lines, 2 filesdep +QuickCheckPVP ok
version bump matches the API change (PVP)
Dependencies added: QuickCheck
API changes (from Hackage documentation)
+ Data.List.Zipper: instance (Arbitrary a) => Arbitrary (Zipper a)
+ Data.List.Zipper: instance (Eq a) => Eq (Zipper a)
+ Data.List.Zipper: instance (Show a) => Show (Zipper a)
Files
- Data/List/Zipper.hs +9/−1
- ListZipper.cabal +2/−2
Data/List/Zipper.hs view
@@ -1,6 +1,14 @@ module Data.List.Zipper where -data Zipper a = Zip ![a] ![a]+import Control.Monad (liftM2)+import Test.QuickCheck (Arbitrary(..))+++data Zipper a = Zip ![a] ![a] deriving (Eq,Show)++instance Arbitrary a => Arbitrary (Zipper a) where+ arbitrary = liftM2 Zip arbitrary arbitrary+ coarbitrary (Zip ls rs) = coarbitrary rs . coarbitrary ls empty :: Zipper a empty = Zip [] []
ListZipper.cabal view
@@ -1,5 +1,5 @@ name: ListZipper-version: 1.1.0.0+version: 1.1.1.0 copyright: (c) 2008 Ryan Ingram license: BSD3 license-file: LICENSE@@ -15,4 +15,4 @@ library exposed-modules: Data.List.Zipper- build-depends: base >= 3.0+ build-depends: base >= 3.0, QuickCheck