packages feed

vinyl 0.11.0 → 0.12.0

raw patch · 6 files changed

+16/−15 lines, 6 filesdep ~basePVP ok

version bump matches the API change (PVP)

Dependency ranges changed: base

API changes (from Hackage documentation)

- Data.Vinyl.XRec: instance forall u (f :: * -> *) (g :: u -> *) (a :: u). (Data.Vinyl.XRec.IsoHKD f (Data.Vinyl.XRec.HKD g a), Data.Vinyl.XRec.IsoHKD g a, GHC.Base.Functor f) => Data.Vinyl.XRec.IsoHKD (Data.Vinyl.Functor.Compose f g) a
- Data.Vinyl.XRec: instance forall u (f :: u -> *) (a :: u) (g :: u -> *). (Data.Vinyl.XRec.IsoHKD f a, Data.Vinyl.XRec.IsoHKD g a) => Data.Vinyl.XRec.IsoHKD (Data.Vinyl.Functor.Lift (->) f g) a
+ Data.Vinyl.XRec: instance forall k (f :: * -> *) (g :: k -> *) (a :: k). (Data.Vinyl.XRec.IsoHKD f (Data.Vinyl.XRec.HKD g a), Data.Vinyl.XRec.IsoHKD g a, GHC.Base.Functor f) => Data.Vinyl.XRec.IsoHKD (Data.Vinyl.Functor.Compose f g) a
+ Data.Vinyl.XRec: instance forall k (f :: k -> *) (a :: k) (g :: k -> *). (Data.Vinyl.XRec.IsoHKD f a, Data.Vinyl.XRec.IsoHKD g a) => Data.Vinyl.XRec.IsoHKD (Data.Vinyl.Functor.Lift (->) f g) a
- Data.Vinyl: class RecMapMethod c (f :: u -> *) (ts :: [u])
+ Data.Vinyl: class RecMapMethod c f ts
- Data.Vinyl: class RecPointed c (f :: u -> *) (ts :: [u])
+ Data.Vinyl: class RecPointed c f ts
- Data.Vinyl: class XRMap (f :: u -> *) (g :: u -> *) (rs :: [u])
+ Data.Vinyl: class XRMap f g rs
- Data.Vinyl: rpointMethod :: RecPointed c f ts => (forall (a :: u). c (f a) => f a) -> Rec f ts
+ Data.Vinyl: rpointMethod :: RecPointed c f ts => (forall a. c (f a) => f a) -> Rec f ts
- Data.Vinyl.Class.Method: class RecMapMethod c (f :: u -> *) (ts :: [u])
+ Data.Vinyl.Class.Method: class RecMapMethod c f ts
- Data.Vinyl.Class.Method: class RecMapMethod1 c (f :: u -> *) (ts :: [u])
+ Data.Vinyl.Class.Method: class RecMapMethod1 c f ts
- Data.Vinyl.Class.Method: class RecPointed c (f :: u -> *) (ts :: [u])
+ Data.Vinyl.Class.Method: class RecPointed c f ts
- Data.Vinyl.Class.Method: rpointMethod :: RecPointed c f ts => (forall (a :: u). c (f a) => f a) -> Rec f ts
+ Data.Vinyl.Class.Method: rpointMethod :: RecPointed c f ts => (forall a. c (f a) => f a) -> Rec f ts
- Data.Vinyl.FromTuple: class TupleXRec (f :: u -> *) (t :: [u])
+ Data.Vinyl.FromTuple: class TupleXRec f t
- Data.Vinyl.Lens: class (i ~ RIndex r rs, NatToInt i) => RecElem record (r :: k) (r' :: k) (rs :: [k]) (rs' :: [k]) (i :: Nat) | r r' rs i -> rs' where {
+ Data.Vinyl.Lens: class (i ~ RIndex r rs, NatToInt i) => RecElem record r r' rs rs' (i :: Nat) | r r' rs i -> rs' where {
- Data.Vinyl.Lens: class is ~ RImage rs ss => RecSubset record (rs :: [k]) (ss :: [k]) is where {
+ Data.Vinyl.Lens: class is ~ RImage rs ss => RecSubset record rs ss is where {
- Data.Vinyl.XRec: class IsoHKD (f :: u -> *) (a :: u) where {
+ Data.Vinyl.XRec: class IsoHKD f a where {
- Data.Vinyl.XRec: class XRMap (f :: u -> *) (g :: u -> *) (rs :: [u])
+ Data.Vinyl.XRec: class XRMap f g rs
- Data.Vinyl.XRec: xrmapAux :: XRMap f g rs => (forall (a :: u). XData f a -> XData g a) -> XRec f rs -> XRec g rs
+ Data.Vinyl.XRec: xrmapAux :: XRMap f g rs => (forall a. XData f a -> XData g a) -> XRec f rs -> XRec g rs

Files

CHANGELOG.md view
@@ -1,3 +1,6 @@+# 0.12.0+- GHC 8.8.1 support. Class type signatures were changed to remove explicit kind variables. This is to simplify the use of `TypeApplications` which changed with GHC 8.8.1 to require explicit application to those kind variables. Leaving them out of the class definitions preserves existing usage of `TypeApplications`. Thanks to Justin Le (@msgksg).+ # 0.11.0  - Changed the `Show` instance of `CoRec`
Data/Vinyl/Class/Method.hs view
@@ -160,8 +160,8 @@  -- | Generate a record from fields derived from type class -- instances.-class RecPointed c (f :: u -> *) (ts :: [u]) where-  rpointMethod :: (forall (a :: u). c (f a) => f a) -> Rec f ts+class RecPointed c f ts where+  rpointMethod :: (forall a. c (f a) => f a) -> Rec f ts  instance RecPointed c f '[] where   rpointMethod _ = RNil@@ -175,14 +175,14 @@ -- | Apply a typeclass method to each field of a 'Rec' where the class -- constrains the index of the field, but not its interpretation -- functor.-class RecMapMethod c (f :: u -> *) (ts :: [u]) where+class RecMapMethod c f ts where   rmapMethod :: (forall a. c (PayloadType f a) => f a -> g a)              -> Rec f ts -> Rec g ts  -- | Apply a typeclass method to each field of a 'Rec' where the class -- constrains the field when considered as a value interpreted by the -- record's interpretation functor.-class RecMapMethod1 c (f :: u -> *) (ts :: [u])where+class RecMapMethod1 c f ts where   rmapMethod1 :: (forall a. c (f a) => f a -> g a)               -> Rec f ts -> Rec g ts 
Data/Vinyl/FromTuple.hs view
@@ -51,7 +51,7 @@   UncurriedXRec '(f, ts) = XRec f ts  -- | Convert between an 'XRec' and an isomorphic tuple.-class TupleXRec (f :: u -> *) (t :: [u]) where+class TupleXRec f t where   -- | Convert an 'XRec' to a tuple. Useful for pattern matching on an   -- entire record.   xrecTuple :: XRec f t -> ListToHKDTuple f t
Data/Vinyl/Lens.hs view
@@ -38,9 +38,7 @@ -- the constraint solver realize that this is a decidable predicate -- with respect to the judgemental equality in @k@. class (i ~ RIndex r rs, NatToInt i)-  => RecElem record (r :: k) (r' :: k)-             (rs :: [k]) (rs' :: [k])-             (i :: Nat) | r r' rs i -> rs' where+  => RecElem record r r' rs rs' (i :: Nat) | r r' rs i -> rs' where   -- | An opportunity for instances to generate constraints based on   -- the functor parameter of records passed to class methods.   type RecElemFCtx record (f :: k -> *) :: Constraint@@ -141,7 +139,7 @@ -- record to the former's is evident. That is, we can either cast a larger -- record to a smaller one, or we may replace the values in a slice of a -- record.-class is ~ RImage rs ss => RecSubset record (rs :: [k]) (ss :: [k]) is where+class is ~ RImage rs ss => RecSubset record rs ss is where   -- | An opportunity for instances to generate constraints based on   -- the functor parameter of records passed to class methods.   type RecSubsetFCtx record (f :: k -> *) :: Constraint
Data/Vinyl/XRec.hs view
@@ -81,8 +81,8 @@ -- permit unrolling of the recursion across a record. The function -- mapped across the vector hides the 'HKD' type family under a newtype -- constructor to help the type checker.-class XRMap (f :: u -> *) (g :: u -> *) (rs :: [u]) where-  xrmapAux :: (forall (a :: u) . XData f a -> XData g a) -> XRec f rs -> XRec g rs+class XRMap f g rs where+  xrmapAux :: (forall a . XData f a -> XData g a) -> XRec f rs -> XRec g rs  instance XRMap f g '[] where   xrmapAux _ RNil = RNil@@ -127,7 +127,7 @@ -- This involves the so-called /higher-kinded data/ type family. See -- <http://reasonablypolymorphic.com/blog/higher-kinded-data> for more -- discussion.-class IsoHKD (f :: u -> *) (a :: u) where+class IsoHKD f a where   type HKD f a   type HKD f a = f a   unHKD :: HKD f a -> f a
vinyl.cabal view
@@ -1,5 +1,5 @@ name:                vinyl-version:             0.11.0+version:             0.12.0 synopsis:            Extensible Records -- description: license:             MIT@@ -12,7 +12,7 @@ build-type:          Simple cabal-version:       >=1.10 extra-source-files:  CHANGELOG.md-tested-with:         GHC == 8.0.2, GHC == 8.2.2, GHC == 8.4.4, GHC == 8.6.2+tested-with:         GHC == 8.4.4, GHC == 8.6.5, GHC == 8.8.1  description: Extensible records for Haskell with lenses. @@ -109,7 +109,7 @@   build-depends:       base                      , vinyl                      , microlens-                     , hspec >= 2.2.4 && < 2.7+                     , hspec >= 2.2.4 && < 2.8                      , should-not-typecheck >= 2.0 && < 2.2   ghc-options:         -threaded -rtsopts -with-rtsopts=-N   default-language:    Haskell2010