packages feed

base-orphans 0.8.5 → 0.8.6

raw patch · 4 files changed

+57/−11 lines, 4 filesPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

API changes (from Hackage documentation)

- Data.Orphans: instance Data.Functor.Classes.Eq1 Data.Fixed.Fixed
- Data.Orphans: instance Data.Functor.Classes.Ord1 Data.Fixed.Fixed

Files

CHANGES.markdown view
@@ -1,3 +1,12 @@+## Changes in 0.8.6 [2021.10.29]+ - Backport `Eq`, `Ord`, `Bounded`, `Enum`, and `Ix` instances for `Solo`,+   introduced in GHC 9.2/`base-4.16`+ - Remove the backported `Eq1` and `Ord1` instances for `Fixed` that were+   introduced in `base-orphans-0.8.5`. While these briefly appeared in a+   release candidate version of GHC 9.2.1, they were ultimately removed from+   the final 9.2.1 release. This release of `base-orphans` synchronizes with+   that change.+ ## Changes in 0.8.5 [2021.08.29]  - Backport new instances from GHC 9.2/`base-4.16`    * `Eq1`, `Read1`, and `Show1` instances for `Complex`
README.markdown view
@@ -55,8 +55,8 @@  * `Eq{1,2}`, `Ord{1,2}`, `Show{1,2}`, and `Read{1,2}` instances for `(,,)` and `(,,,)`  * `Eq` and `Ord` instances for `Control.Exception.ErrorCall`  * `Eq`, `Ord`, `Read`, and `Show` instances for data types in `GHC.Generics`+ * `Eq`, `Ord`, `Bounded`, `Enum`, and `Ix` instances for `Solo`  * `Eq1`, `Read1`, and `Show1` instances for `Complex`- * `Eq1` and `Ord1` instances for `Fixed`  * `Eq1`, `Ord1`, `Read1`, and `Show1` instances for `NonEmpty`  * `Foldable` instance for `Either`, `(,)` and `Const`  * `Foldable` and `Traversable` instances for `Alt` from `Data.Monoid`
base-orphans.cabal view
@@ -1,13 +1,13 @@ cabal-version: 1.12 --- This file has been generated from package.yaml by hpack version 0.34.2.+-- This file has been generated from package.yaml by hpack version 0.34.5. -- -- see: https://github.com/sol/hpack ----- hash: 3f7729521eafb32086f9ec5393064162845096085d8c2302ff44044aecc88db3+-- hash: 804afa44cbb02fb57224b372fbde6da86b3817761980426d9505942e9b67551f  name:                base-orphans-version:             0.8.5+version:             0.8.6 synopsis:            Backwards-compatible orphan instances for base description:         @base-orphans@ defines orphan instances that mimic instances available in                      later versions of @base@ to a wider (older) range of compilers.@@ -35,7 +35,8 @@ license:             MIT license-file:        LICENSE build-type:          Simple-tested-with:         GHC == 7.0.4 , GHC == 7.2.2 , GHC == 7.4.2 , GHC == 7.6.3 , GHC == 7.8.4 , GHC == 7.10.3 , GHC == 8.0.2 , GHC == 8.2.2 , GHC == 8.4.4 , GHC == 8.6.5 , GHC == 8.8.4 , GHC == 8.10.7, GHC == 9.0.1, GHC == 9.2.*+tested-with:+    GHC == 7.0.4 , GHC == 7.2.2 , GHC == 7.4.2 , GHC == 7.6.3 , GHC == 7.8.4 , GHC == 7.10.3 , GHC == 8.0.2 , GHC == 8.2.2 , GHC == 8.4.4 , GHC == 8.6.5 , GHC == 8.8.4 , GHC == 8.10.7 , GHC == 9.0.1 , GHC == 9.2.1 extra-source-files:     CHANGES.markdown     README.markdown
src/Data/Orphans.hs view
@@ -75,6 +75,10 @@ import qualified Data.Traversable as T (Traversable(..)) #endif +#if MIN_VERSION_base(4,15,0) && !(MIN_VERSION_base(4,16,0))+import           GHC.Tuple (Solo(..))+#endif+ #if __GLASGOW_HASKELL__ < 710 import           Control.Exception as Exception import           Control.Monad.ST.Lazy as Lazy@@ -1663,12 +1667,6 @@       where         complexPrec = 6 -instance Eq1 Fixed where-    liftEq _eq (MkFixed x) (MkFixed y) = x == y--instance Ord1 Fixed where-    liftCompare _cmp (MkFixed x) (MkFixed y) = compare x y- instance Eq a => Eq2 ((,,) a) where     liftEq2 e1 e2 (u1, x1, y1) (v1, x2, y2) =         u1 == v1 &&@@ -1805,6 +1803,44 @@ #  if !(MIN_VERSION_base(4,11,0))     Functor.Pair x1 y1 `mappend` Functor.Pair x2 y2 = Functor.Pair (x1 `mappend` x2) (y1 `mappend` y2) #  endif+# endif++# if MIN_VERSION_base(4,15,0)+instance Enum a => Enum (Solo a) where+    succ (Solo a) = Solo (succ a)+    pred (Solo a) = Solo (pred a)++    toEnum x = Solo (toEnum x)++    fromEnum (Solo x) = fromEnum x+    enumFrom (Solo x) = [Solo a | a <- enumFrom x]+    enumFromThen (Solo x) (Solo y) =+      [Solo a | a <- enumFromThen x y]+    enumFromTo (Solo x) (Solo y) =+      [Solo a | a <- enumFromTo x y]+    enumFromThenTo (Solo x) (Solo y) (Solo z) =+      [Solo a | a <- enumFromThenTo x y z]++deriving instance Eq a => Eq (Solo a)+deriving instance Ord a => Ord (Solo a)+deriving instance Bounded a => Bounded (Solo a)++instance Ix a => Ix (Solo a) where -- as derived+    {-# SPECIALISE instance Ix (Solo Int) #-}++    {-# INLINE range #-}+    range (Solo l, Solo u) =+      [ Solo i | i <- range (l,u) ]++    {-# INLINE unsafeIndex #-}+    unsafeIndex (Solo l, Solo u) (Solo i) =+      unsafeIndex (l,u) i++    {-# INLINE inRange #-}+    inRange (Solo l, Solo u) (Solo i) =+      inRange (l, u) i++    -- Default method for index # endif #endif