patch 0.0.5.0 → 0.0.5.1
raw patch · 13 files changed
+75/−29 lines, 13 filesdep +base-orphans
Dependencies added: base-orphans
Files
- ChangeLog.md +5/−0
- patch.cabal +4/−1
- src/Data/Functor/Misc.hs +8/−3
- src/Data/Monoid/DecidablyEmpty.hs +3/−0
- src/Data/Patch.hs +5/−5
- src/Data/Patch/Class.hs +6/−1
- src/Data/Patch/DMap.hs +6/−1
- src/Data/Patch/DMapWithMove.hs +7/−2
- src/Data/Patch/IntMap.hs +5/−2
- src/Data/Patch/Map.hs +6/−2
- src/Data/Patch/MapWithMove.hs +6/−2
- src/Data/Patch/MapWithPatchingMove.hs +6/−2
- src/Data/Semigroup/Additive.hs +8/−8
ChangeLog.md view
@@ -1,5 +1,10 @@ # Revision history for patch +## Unreleased++* New dep of `data-orphans` for old GHC to get instances honestly instead of+ via `monoidal-containers`.+ ## 0.0.5.0 - 2021-12-17 * `Additive` now lives in `Data.Semigroup.Additive`, but is still reexported
patch.cabal view
@@ -1,5 +1,5 @@ Name: patch-Version: 0.0.5.0+Version: 0.0.5.1 Synopsis: Data structures for describing changes to other data structures. Description: Data structures for describing changes to other data structures.@@ -42,6 +42,9 @@ , semigroupoids >= 4.0 && < 6 , transformers >= 0.5.6.0 && < 0.6 , witherable >= 0.3 && < 0.5++ if impl(ghc < 8.6) -- really, if base < 8.12+ build-depends: base-orphans >= 0.8 && < 0.9 exposed-modules: Data.Functor.Misc , Data.Monoid.DecidablyEmpty
src/Data/Functor/Misc.hs view
@@ -10,9 +10,14 @@ {-# LANGUAGE RankNTypes #-} {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE StandaloneDeriving #-}--- | This module provides types and functions with no particular theme, but--- which are relevant to the use of 'Functor'-based datastructures like--- 'Data.Dependent.Map.DMap'.++{- |+Description: Misc utilities relating to functor.++This module provides types and functions with no particular theme, but which+are relevant to the use of 'Functor'-based datastructures like+'Data.Dependent.Map.DMap'.+-} module Data.Functor.Misc ( -- * Const2 Const2 (..)
src/Data/Monoid/DecidablyEmpty.hs view
@@ -5,6 +5,9 @@ {-# LANGUAGE TypeOperators #-} -- TODO upstream somwhere else?+{-|+Description: This module provides a class to decide whether a monoid element is the identity.+-} module Data.Monoid.DecidablyEmpty where import Data.Functor.Identity
src/Data/Patch.hs view
@@ -3,11 +3,11 @@ {-# LANGUAGE StandaloneDeriving #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE TypeOperators #-}--- |--- Module:--- Data.Patch--- Description:--- This module defines the 'Patch' class.++{-|+Description:+ This module defines the 'Group' class, and reexports the other modules.+-} module Data.Patch ( module Data.Patch , module X
src/Data/Patch/Class.hs view
@@ -1,7 +1,12 @@ {-# LANGUAGE CPP #-} {-# LANGUAGE ScopedTypeVariables #-} {-# LANGUAGE TypeFamilies #-}--- | The interface for types which represent changes made to other types++{-|+Description: The module provides the 'Patch' class.++This is a class for types which represent changes made to other types+-} module Data.Patch.Class where import Data.Functor.Identity
src/Data/Patch/DMap.hs view
@@ -7,7 +7,12 @@ {-# LANGUAGE StandaloneDeriving #-} {-# LANGUAGE TypeFamilies #-} --- | 'Patch'es on 'DMap' that consist only of insertions (or overwrites) and deletions.+{-|+Description: A basic 'Patch' on 'DMap'++Patches of this type consist only of insertions (including overwrites) and+deletions.+-} module Data.Patch.DMap where import Data.Patch.Class
src/Data/Patch/DMapWithMove.hs view
@@ -11,8 +11,13 @@ {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UndecidableInstances #-} --- |Module containing @'PatchDMapWithMove' k v@ and associated functions, which represents a 'Patch' to a @'DMap' k v@ which can insert, update, delete, and--- move values between keys.+{-|+Description: A more advanced 'Patch' for 'DMap'.++This Module contains @'PatchDMapWithMove' k v@ and associated functions, which+represents a 'Patch' to a @'DMap' k v@ which can insert, update, delete, and+move values between keys.+-} module Data.Patch.DMapWithMove where import Data.Patch.Class
src/Data/Patch/IntMap.hs view
@@ -7,8 +7,11 @@ {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE TypeFamilies #-} --- | Module containing 'PatchIntMap', a 'Patch' for 'IntMap' which allows for--- insert/update or delete of associations.+{-|+Description: Module containing 'PatchIntMap', a 'Patch' for 'IntMap'.++Patches of this sort allow for insert/update or delete of associations.+-} module Data.Patch.IntMap where import Control.Lens
src/Data/Patch/Map.hs view
@@ -8,8 +8,12 @@ {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE TypeFamilies #-} --- | 'Patch'es on 'Map' that consist only of insertions (including overwrites)--- and deletions+{-|+Description: A basic 'Patch' on 'Map'++Patches of this type consist only of insertions (including overwrites) and+deletions.+-} module Data.Patch.Map where import Data.Patch.Class
src/Data/Patch/MapWithMove.hs view
@@ -14,8 +14,12 @@ {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE ViewPatterns #-} --- | 'Patch'es on 'Map' that can insert, delete, and move values from one key to--- another+{-|+Description: An intermediate 'Patch' on 'Map'++Patches of this type can insert, delete, and also move values from one key to+another.+-} module Data.Patch.MapWithMove ( PatchMapWithMove ( PatchMapWithMove
src/Data/Patch/MapWithPatchingMove.hs view
@@ -11,8 +11,12 @@ {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UndecidableInstances #-} --- | 'Patch'es on 'Map' that can insert, delete, and move values from one key to--- another+{-|+Description: An advanced 'Patch' on 'Map'++Patches of this type can can insert, delete, and move values from one key to+another, and move patches may also additionally patch the value being moved.+-} module Data.Patch.MapWithPatchingMove ( PatchMapWithPatchingMove (..) , patchMapWithPatchingMove
src/Data/Semigroup/Additive.hs view
@@ -1,21 +1,21 @@ {-# LANGUAGE CPP #-} {-# LANGUAGE TypeOperators #-} {-# LANGUAGE TypeFamilies #-}--- |--- Module:--- Data.Semigroup.Additive--- Description:--- This module defines a class for commutative semigroups, until it is moved--- to another library.++{-|+Description : A class for commutative semigroups+-} module Data.Semigroup.Additive ( Additive ) where import Data.Functor.Const (Const (..)) import Data.Functor.Identity--- For base-orphans, TODO don't cheat.-import Data.Map.Monoidal () import Data.Proxy+#if !MIN_VERSION_base(4,12,0)+-- for :*: and :.: semigroup instances+import Data.Orphans ()+#endif #if !MIN_VERSION_base(4,11,0) import Data.Semigroup (Semigroup (..)) #endif