packages feed

semialign 1.2 → 1.2.0.1

raw patch · 3 files changed

+25/−12 lines, 3 filesdep ~basedep ~hashabledep ~semigroupsPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: base, hashable, semigroups, vector

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -1,3 +1,7 @@+# 1.2.0.1++-  GHC-9.2 support+ # 1.2  - Migrate `SemialignWithIndex` and `ZipWithIndex` to this package,
semialign.cabal view
@@ -1,6 +1,6 @@ cabal-version:      >=1.10 name:               semialign-version:            1.2+version:            1.2.0.1 synopsis:   Align and Zip type-classes from the common Semialign ancestor. @@ -32,6 +32,7 @@      || ==8.8.4      || ==8.10.4      || ==9.0.1+     || ==9.2.1   , GHCJS ==8.4  source-repository head@@ -50,6 +51,8 @@    if impl(ghc >=8.0)     ghc-options: -Wno-trustworthy-safe+  if impl(ghc >=9.2)+    ghc-options: -Wno-noncanonical-monoid-instances    hs-source-dirs:   src   exposed-modules:@@ -63,16 +66,16 @@    -- ghc boot libs   build-depends:-      base          >=4.5.1.0 && <4.16+      base          >=4.5.1.0 && <4.17     , containers    >=0.4.2.1 && <0.7-    , transformers  >=0.3.0.0 && <0.6+    , transformers  >=0.3.0.0 && <0.7    -- These   build-depends:    these >=1.1.1.1 && <1.2    -- other dependencies   build-depends:-      hashable                       >=1.2.7.0  && <1.4+      hashable                       >=1.2.7.0  && <1.5     , indexed-traversable            >=0.1.1    && <0.2     , indexed-traversable-instances  >=0.1      && <0.2     , tagged                         >=0.8.6    && <0.9@@ -86,8 +89,8 @@   if !impl(ghc >=8.0)     build-depends:         semigroups           >=0.18.5  && <0.20-      , transformers         >=0.3.0.0 && <0.6-      , transformers-compat  >=0.6.5   && <0.7+      , transformers         >=0.3.0.0 && <0.7+      , transformers-compat  >=0.6.5   && <0.8      -- Ensure Data.Functor.Classes is always available     if impl(ghc >=7.10)
src/Data/Semialign/Internal.hs view
@@ -28,7 +28,7 @@ import Data.Maybe                        (catMaybes) import Data.Monoid                       (Monoid (..)) import Data.Proxy                        (Proxy (..))-import Data.Semigroup                    (Option (..), Semigroup (..))+import Data.Semigroup                    (Semigroup (..)) import Data.Sequence                     (Seq) import Data.Tagged                       (Tagged (..)) import Data.Vector.Fusion.Stream.Monadic (Step (..), Stream (..))@@ -74,6 +74,10 @@ import qualified Data.IntMap as IntMap #endif +#if !(MIN_VERSION_base(4,16,0))+import Data.Semigroup (Option (..))+#endif + import Data.These import Data.These.Combinators @@ -481,6 +485,7 @@ instance ZipWithIndex Int NonEmpty instance RepeatWithIndex Int NonEmpty +#if !(MIN_VERSION_base(4,16,0)) deriving instance Semialign Option deriving instance Align Option deriving instance Unalign Option@@ -488,11 +493,10 @@ deriving instance Repeat Option deriving instance Unzip Option -{--deriving instance SemialignWithIndex () Option-deriving instance ZipWithIndex () Option-deriving instance RepeatWithIndex () Option--}+-- deriving instance SemialignWithIndex () Option+-- deriving instance ZipWithIndex () Option+-- deriving instance RepeatWithIndex () Option+#endif  ------------------------------------------------------------------------------- -- containers: ListLike@@ -742,7 +746,9 @@                 Done -> case (av, adone) of                     (Just x, False) -> Yield (f $ This x) (sa, sb, Nothing, adone)                     (_, True)       -> Done+#if __GLASGOW_HASKELL__ < 902                     _               -> Skip (sa, sb, Nothing, False)+#endif  instance Monad m => Zip (Stream m) where     zipWith = Stream.zipWith