packages feed

newtype-generics 0.5.4 → 0.6.3

raw patch · 4 files changed

Files

CHANGELOG.md view
@@ -1,5 +1,19 @@ # Changelog for `newtype-generics` +## [0.6.3] – 2026-05-30+- Maintainer switch to Haskell Github Trust+- Support newer compilers.++## [0.6.2] – 2022-05-19+- Remove dependency on `transformers`.++## [0.6.1] – 2021-11-02+- Support GHC-9.2++## [0.6] – 2021-02-04+- Remove the deprecated `Control.Newtype` module.+- Support GHC-9.0+ ## [0.5.4] – 2019-09-10 - Add `Newtype` instance for `Data.Monoid.Ap`. - Support GHC-8.8.@@ -36,7 +50,9 @@ - Relax types of `underF` and `overF` to allow different input & output functors  -[Unreleased]: https://github.com/sjakobi/newtype-generics/compare/v0.5.4...HEAD+[Unreleased]: https://github.com/sjakobi/newtype-generics/compare/v0.6...HEAD+[0.6.1]: https://github.com/sjakobi/newtype-generics/compare/v0.6...v0.6.1+[0.6]: https://github.com/sjakobi/newtype-generics/compare/v0.5.4...v0.6 [0.5.4]: https://github.com/sjakobi/newtype-generics/compare/v0.5.3...v0.5.4 [0.5.3]: https://github.com/sjakobi/newtype-generics/compare/v0.5.2.2...v0.5.3 [0.5.2.2]: https://github.com/sjakobi/newtype-generics/compare/v0.5.2.1...v0.5.2.2
− Control/Newtype.hs
@@ -1,6 +0,0 @@-module Control.Newtype-{-# deprecated "Import \"Control.Newtype.Generics\" instead" #-}-  ( module Control.Newtype.Generics-  ) where--import Control.Newtype.Generics
Control/Newtype/Generics.hs view
@@ -6,6 +6,7 @@ {-# LANGUAGE MultiParamTypeClasses      #-} {-# LANGUAGE StandaloneDeriving         #-} {-# LANGUAGE TypeFamilies               #-}+{-# LANGUAGE TypeOperators              #-} {-# LANGUAGE UndecidableInstances       #-} {- | The 'Newtype' typeclass and related functions.@@ -60,14 +61,15 @@ import Control.Arrow import Data.Functor.Compose import Data.Functor.Identity-#if MIN_VERSION_base(4,7,0) import Data.Fixed-#endif+import Data.Kind (Type) import Data.Monoid import Data.Ord-#if MIN_VERSION_base(4,9,0) import qualified Data.Semigroup-import Data.Semigroup (Min(..), Max(..), WrappedMonoid(..), Option(..))+#if MIN_VERSION_base(4,16,0)+import Data.Semigroup (Min(..), Max(..), WrappedMonoid(..))+#else+import Data.Semigroup (Min(..), Max(..), WrappedMonoid(..),Option(..)) #endif import GHC.Generics {-import Generics.Deriving-}@@ -84,7 +86,7 @@  -- Generic Newtype class GNewtype n where-  type GO n :: *+  type GO n :: Type   gpack   :: GO n -> n p   gunpack :: n p  -> GO n @@ -105,7 +107,7 @@ -- | As long as the type @n@ is an instance of Generic, you can create an instance -- with just @instance Newtype n@ class Newtype n where-  type O n :: *+  type O n :: Type   type O n = GO (Rep n)    pack   :: O n -> n@@ -240,7 +242,6 @@   pack = ArrowMonad   unpack (ArrowMonad a) = a -#if MIN_VERSION_base(4,7,0) -- Instances from Data.Fixed  -- | @since 0.5.1@@ -248,7 +249,6 @@   type O (Fixed a) = Integer   pack = MkFixed   unpack (MkFixed x) = x-#endif  -- Instances from Data.Functor.Compose @@ -316,16 +316,14 @@   pack = Last   unpack (Last a) = a -#if MIN_VERSION_base(4,8,0) -- | @since 0.5.1 instance Newtype (Alt f a) where   type O (Alt f a) = f a   pack = Alt   unpack (Alt x) = x-#endif  #if MIN_VERSION_base(4,12,0)--- | @since Unreleased+-- | @since 0.5.4 instance Newtype (Ap f a) where   type O (Ap f a) = f a   pack = Ap@@ -341,7 +339,6 @@   unpack (Down a) = a  -#if MIN_VERSION_base(4,9,0) -- Instances from Data.Semigroup  -- | @since 0.5.1@@ -374,6 +371,7 @@   pack = WrapMonoid   unpack (WrapMonoid m) = m +#if !MIN_VERSION_base(4,16,0) -- | @since 0.5.1 instance Newtype (Option a) where   type O (Option a) = Maybe a
newtype-generics.cabal view
@@ -1,5 +1,5 @@ Name:                newtype-generics-Version:             0.5.4+Version:             0.6.3 Synopsis:            A typeclass and set of functions for working with newtypes Description:         Per Conor McBride, the Newtype typeclass represents the packing and unpacking of a newtype,                      and allows you to operate under that newtype with functions such as ala.@@ -8,27 +8,26 @@ License:             BSD3 License-file:        LICENSE Author:              Darius Jahandarie, Conor McBride, João Cristóvão, Simon Jakobi-Maintainer:          Simon Jakobi <simon.jakobi@gmail.com>-Homepage:            http://github.com/sjakobi/newtype-generics+Maintainer:          Haskell Github Trust <https://github.com/haskell-github-trust>+Homepage:            http://github.com/haskell-github-trust/newtype-generics Category:            Control Build-type:          Simple Extra-source-files:  CHANGELOG.md Cabal-version:       >=1.10 Tested-with:-  GHC==8.8.1,-  GHC==8.6.5,-  GHC==8.4.4,-  GHC==8.2.2,-  GHC==8.0.2,-  GHC==7.10.3,-  GHC==7.8.4,-  GHC==7.6.3+  GHC==9.14.1,+  GHC==9.12.4,+  GHC==9.10.3,+  GHC==9.8.4,+  GHC==9.6.7,+  GHC==9.4.2,+  GHC==9.2.1,+  GHC==9.0.1,+  GHC==8.10.7  Library-  Exposed-modules:     Control.Newtype-                     , Control.Newtype.Generics-  Build-depends:       base >= 4.6 && < 4.14-                     , transformers < 0.6+  Exposed-modules:     Control.Newtype.Generics+  Build-depends:       base >= 4.9 && < 4.23   Ghc-options: -Wall   default-language:   Haskell2010