packages feed

fin 0.3 → 0.3.1

raw patch · 5 files changed

+33/−66 lines, 5 filesdep −bifunctorsdep −natsdep −semigroupsdep ~QuickCheckdep ~basedep ~boringPVP ok

version bump matches the API change (PVP)

Dependencies removed: bifunctors, nats, semigroups, void

Dependency ranges changed: QuickCheck, base, boring, dec, deepseq, hashable, some, universe-base

API changes (from Hackage documentation)

Files

ChangeLog.md view
@@ -1,3 +1,9 @@+# Version history for fin++## 0.3.1++- Support GHC-8.6.5...9.10.1+ ## 0.3  - Remove `Data.Fin.Enum` module. It didn't work as well as hoped.
fin.cabal view
@@ -1,6 +1,6 @@-cabal-version:      >=1.10+cabal-version:      2.2 name:               fin-version:            0.3+version:            0.3.1 synopsis:           Nat and Fin: peano naturals and finite numbers category:           Data, Dependent Types, Singletons, Math description:@@ -48,7 +48,7 @@  homepage:           https://github.com/phadej/vec bug-reports:        https://github.com/phadej/vec/issues-license:            BSD3+license:            BSD-3-Clause license-file:       LICENSE author:             Oleg Grenrus <oleg.grenrus@iki.fi> maintainer:         Oleg.Grenrus <oleg.grenrus@iki.fi>@@ -56,18 +56,15 @@ build-type:         Simple extra-source-files: ChangeLog.md tested-with:-  GHC ==7.8.4-   || ==7.10.3-   || ==8.0.2-   || ==8.2.2-   || ==8.4.4-   || ==8.6.5+  GHC ==8.6.5    || ==8.8.4    || ==8.10.7    || ==9.0.2-   || ==9.2.7-   || ==9.4.4-   || ==9.6.1+   || ==9.2.8+   || ==9.4.8+   || ==9.6.5+   || ==9.8.2+   || ==9.10.1  source-repository head   type:     git@@ -87,26 +84,20 @@     Data.Type.Nat.LT    other-modules:    TrustworthyCompat-  build-depends:-      base           >=4.7     && <4.19-    , boring         >=0.2     && <0.3-    , dec            >=0.0.4   && <0.1-    , deepseq        >=1.3.0.2 && <1.5-    , hashable       >=1.2.7.0 && <1.5-    , QuickCheck     >=2.13.2  && <2.15-    , some           >=1.0.4   && <1.1-    , universe-base  >=1.1.2   && <1.2 -  if !impl(ghc >=8.2)-    build-depends: bifunctors >=5.5.3 && <5.6--  if !impl(ghc >=8.0)-    build-depends: semigroups >=0.18.5 && <0.21+  -- GHC boot libs+  build-depends:+    , base     >=4.12.0.0 && <4.21+    , deepseq  >=1.4.4.0  && <1.6 -  if !impl(ghc >=7.10)-    build-depends:-        nats  >=1.1.2 && <1.2-      , void  >=0.7.3 && <0.8+  -- other dependencies+  build-depends:+    , boring         ^>=0.2.2+    , dec            ^>=0.0.6+    , hashable       ^>=1.4.4.0+    , QuickCheck     ^>=2.14.2  || ^>=2.15+    , some           ^>=1.0.6+    , universe-base  ^>=1.1.4    if impl(ghc >=9.0)     -- these flags may abort compilation with GHC-8.10@@ -114,7 +105,6 @@     ghc-options: -Winferred-safe-imports -Wmissing-safe-haskell-mode  -- dump-core--- if impl(ghc >= 8.0) --  build-depends: dump-core --  ghc-options: -fplugin=DumpCore -fplugin-opt DumpCore:core-html @@ -125,7 +115,7 @@   hs-source-dirs:   test   default-language: Haskell2010   build-depends:-      base+    , base     , fin     , inspection-testing  >=0.2.0.1 && <0.6     , tagged
src/Data/Fin.hs view
@@ -1,4 +1,3 @@-{-# LANGUAGE CPP                  #-} {-# LANGUAGE DataKinds            #-} {-# LANGUAGE DeriveDataTypeable   #-} {-# LANGUAGE EmptyCase            #-}@@ -54,20 +53,17 @@  import Control.DeepSeq    (NFData (..)) import Data.Bifunctor     (bimap)+import Data.EqP           (EqP (..)) import Data.GADT.Show     (GShow (..)) import Data.Hashable      (Hashable (..)) import Data.List.NonEmpty (NonEmpty (..))+import Data.OrdP          (OrdP (..)) import Data.Proxy         (Proxy (..)) import Data.Type.Nat      (Nat (..)) import Data.Typeable      (Typeable) import GHC.Exception      (ArithException (..), throw) import Numeric.Natural    (Natural) -#if MIN_VERSION_some(1,0,5)-import Data.EqP  (EqP (..))-import Data.OrdP (OrdP (..))-#endif- import qualified Data.Boring           as Boring import qualified Data.List.NonEmpty    as NE import qualified Data.Type.Nat         as N@@ -104,8 +100,6 @@ deriving instance Eq (Fin n) deriving instance Ord (Fin n) -#if MIN_VERSION_some(1,0,5)- -- | -- -- >>> eqp FZ FZ@@ -142,8 +136,6 @@     comparep FZ     (FS _) = LT     comparep (FS _) FZ     = GT     comparep (FS n) (FS m) = comparep n m--#endif  -- | 'Fin' is printed as 'Natural'. --
src/Data/Nat.hs view
@@ -1,11 +1,6 @@ {-# LANGUAGE CPP                #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE Safe               #-}--#if __GLASGOW_HASKELL__ < 710-{-# LANGUAGE DataKinds          #-}-{-# LANGUAGE StandaloneDeriving #-}-#endif -- | 'Nat' numbers. -- -- This module is designed to be imported qualified.@@ -44,11 +39,6 @@ -- Better than GHC's built-in 'GHC.TypeLits.Nat' for some use cases. -- data Nat = Z | S Nat deriving (Eq, Typeable, Data)--#if __GLASGOW_HASKELL__ < 710-deriving instance Typeable 'Z-deriving instance Typeable 'S-#endif  -- | 'Nat' is printed as 'Natural'. --
src/Data/Type/Nat.hs view
@@ -1,4 +1,3 @@-{-# LANGUAGE CPP                  #-} {-# LANGUAGE DataKinds            #-} {-# LANGUAGE DeriveDataTypeable   #-} {-# LANGUAGE EmptyCase            #-}@@ -67,21 +66,17 @@  import Control.DeepSeq   (NFData (..)) import Data.Boring       (Boring (..))+import Data.EqP          (EqP (..)) import Data.Function     (fix)-import Data.GADT.Compare (GCompare (..), GEq (..), GOrdering (..))+import Data.GADT.Compare (GCompare (..), GEq (..), GOrdering (..), defaultCompare, defaultEq) import Data.GADT.DeepSeq (GNFData (..)) import Data.GADT.Show    (GShow (..))+import Data.OrdP         (OrdP (..)) import Data.Proxy        (Proxy (..)) import Data.Type.Dec     (Dec (..)) import Data.Typeable     (Typeable) import Numeric.Natural   (Natural) -#if MIN_VERSION_some(1,0,5)-import Data.EqP          (EqP (..))-import Data.OrdP         (OrdP (..))-import Data.GADT.Compare (defaultCompare, defaultEq)-#endif- import qualified GHC.TypeLits as GHC  import Unsafe.Coerce (unsafeCoerce)@@ -251,10 +246,6 @@     EqNat ('S n) ('S m) = EqNat n m     EqNat n      m      = 'False -#if !MIN_VERSION_base(4,11,0)-type instance n == m = EqNat n m-#endif- -- | @since 0.2.1 instance SNatI n => Boring (SNat n) where     boring = snat@@ -292,13 +283,11 @@ instance Ord (SNat a) where     compare _ _ = EQ -#if MIN_VERSION_some(1,0,5) -- | @since 0.2.2 instance EqP SNat where eqp = defaultEq  -- | @since 0.2.2 instance OrdP SNat where comparep = defaultCompare-#endif  -- | Decide equality of type-level numbers. --