packages feed

bluefin 0.2.7.0 → 0.4.0.0

raw patch · 3 files changed

+27/−8 lines, 3 filesdep ~bluefin-internalPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: bluefin-internal

API changes (from Hackage documentation)

- Bluefin.Compound: handleMapHandle :: (forall (e :: Effects) (es :: Effects). e :> es => h e -> h es) -> HandleD h
+ Bluefin.Compound: withHandle :: Handle h => ((forall (e :: Effects) (es :: Effects). e :> es => OneWayCoercible (h e) (h es)) => r) -> r
- Bluefin.CloneableHandle: class Generic1 (f :: k -> Type)
+ Bluefin.CloneableHandle: class () => Generic1 (f :: k -> Type)
- Bluefin.CloneableHandle: newtype GenericCloneableHandle (h :: k -> Type) (e :: k)
+ Bluefin.CloneableHandle: newtype () => GenericCloneableHandle (h :: k -> Type) (e :: k)
- Bluefin.Compound: class Generic a
+ Bluefin.Compound: class () => Generic a
- Bluefin.Compound: class Handle (h :: Effects -> Type)
+ Bluefin.Compound: class () => Handle (h :: Effects -> Type)
- Bluefin.Compound: class OneWayCoercible (a :: k) (b :: k)
+ Bluefin.Compound: class () => OneWayCoercible (a :: k) (b :: k)
- Bluefin.Compound: data Compound (e1 :: Effects -> Type) (e2 :: Effects -> Type) (ss :: Effects)
+ Bluefin.Compound: data () => Compound (e1 :: Effects -> Type) (e2 :: Effects -> Type) (ss :: Effects)
- Bluefin.Compound: data HandleD (h :: Effects -> Type)
+ Bluefin.Compound: data () => HandleD (h :: Effects -> Type)
- Bluefin.Compound: mapHandle :: forall (e :: Effects) (es :: Effects). (Handle h, e :> es) => h e -> h es
+ Bluefin.Compound: mapHandle :: forall h (e :: Effects) (es :: Effects). (Handle h, e :> es) => h e -> h es
- Bluefin.Compound: newtype OneWayCoercibleHandle (a :: k -> Type) (es :: k)
+ Bluefin.Compound: newtype () => OneWayCoercibleHandle (a :: k -> Type) (es :: k)
- Bluefin.Coroutine: data Coroutine a b (e :: Effects)
+ Bluefin.Coroutine: data () => Coroutine a b (e :: Effects)
- Bluefin.DslBuilder: data DslBuilder (h :: Effects -> Type) r
+ Bluefin.DslBuilder: data () => DslBuilder (h :: Effects -> Type) r
- Bluefin.Eff: class (es1 :: Effects) :> (es2 :: Effects)
+ Bluefin.Eff: class () => (es1 :: Effects) :> (es2 :: Effects)
- Bluefin.Eff: data Eff (es :: Effects) a
+ Bluefin.Eff: data () => Eff (es :: Effects) a
- Bluefin.Eff: data Effects
+ Bluefin.Eff: data () => Effects
- Bluefin.Exception: data Exception exn (e :: Effects)
+ Bluefin.Exception: data () => Exception exn (e :: Effects)
- Bluefin.Exception.GeneralBracket: data ( (h1 :: Effects -> Type) :~> (h2 :: Effects -> Type) ) (es :: Effects)
+ Bluefin.Exception.GeneralBracket: data () => ( (h1 :: Effects -> Type) :~> (h2 :: Effects -> Type) ) (es :: Effects)
- Bluefin.Exception.GeneralBracket: data MakeExceptions r a (h :: Effects -> Type) (es :: Effects)
+ Bluefin.Exception.GeneralBracket: data () => MakeExceptions r a (h :: Effects -> Type) (es :: Effects)
- Bluefin.HandleReader: data HandleReader (h :: Effects -> Type) (e :: Effects)
+ Bluefin.HandleReader: data () => HandleReader (h :: Effects -> Type) (e :: Effects)
- Bluefin.IO: data EffReader r (es :: Effects) a
+ Bluefin.IO: data () => EffReader r (es :: Effects) a
- Bluefin.IO: data IOE (e :: Effects)
+ Bluefin.IO: data () => IOE (e :: Effects)
- Bluefin.Pipes: data Proxy a' a b' b (e :: Effects)
+ Bluefin.Pipes: data () => Proxy a' a b' b (e :: Effects)
- Bluefin.Reader: data Reader r (e :: Effects)
+ Bluefin.Reader: data () => Reader r (e :: Effects)
- Bluefin.State: data State s (e :: Effects)
+ Bluefin.State: data () => State s (e :: Effects)
- Bluefin.StateSource: data StateSource (e :: Effects)
+ Bluefin.StateSource: data () => StateSource (e :: Effects)
- Bluefin.System.IO: data Handle (e :: Effects)
+ Bluefin.System.IO: data () => Handle (e :: Effects)
- Bluefin.Writer: data Writer w (e :: Effects)
+ Bluefin.Writer: data () => Writer w (e :: Effects)

Files

CHANGELOG.md view
@@ -1,3 +1,8 @@+# 0.4.0.0++* Move `mapHandle` out of class `Handle` and remove `handleMapHandle`.+  See `Bluefin.Compound` for instructions about migrating.+ # 0.2.7.0  * Add `Bluefin.Compound.handleOneWayCoercible`
bluefin.cabal view
@@ -1,6 +1,6 @@ cabal-version:      3.0 name:               bluefin-version:            0.2.7.0+version:            0.4.0.0 license:            MIT license-file:       LICENSE author:             Tom Ellis@@ -42,6 +42,6 @@       Bluefin.System.IO,       Bluefin.Writer,     build-depends:-      bluefin-internal >= 0.3.5.0 && < 0.4+      bluefin-internal >= 0.4.0.0 && < 0.5     hs-source-dirs:   src     default-language: Haskell2010
src/Bluefin/Compound.hs view
@@ -402,9 +402,14 @@     --     counter7State :: 'Bluefin.State.State' Int e,     --     counter7Stream :: 'Bluefin.Stream.Stream' String e     --   }+    --   deriving (Handle) via OneWayCoercibleHandle Counter7     ---    -- instance 'Handle' Counter7 where-    --   handleImpl = handleMapHandle $ \\c ->+    -- -- | The "forall" in the type of @incCounter7@ means that we+    -- -- can't derive the @OneWayCoercible@ instance with+    -- -- 'OneWayCoercible.gOneWayCoercible' so instead we use 'oneWayCoercibleTrustMe'.+    --+    -- instance (e :> es) => 'OneWayCoercible' (Counter7 e) (Counter7 es) where+    --   oneWayCoercibleImpl = oneWayCoercibleTrustMe $ \\c ->     --     MkCounter7     --       { incCounter7Impl = \\ex -> 'useImplUnder' (incCounter7Impl c ex),     --         counter7State = 'mapHandle' (counter7State c),@@ -492,9 +497,17 @@     --   { askLRImpl :: 'Bluefin.Eff.Eff' e r,     --     localLRImpl :: forall e' a. (r -> r) -> Eff e' a -> Eff (e' :& e) a     --   }+    --   deriving (Handle) via OneWayCoercibleHandle (DynamicReader r)     ---    -- instance 'Handle' (DynamicReader r) where-    --   mapHandle h =+    -- -- | The "forall" in the type of @localRImpl@ means that we+    -- -- can't derive the @OneWayCoercible@ instance with+    -- -- 'OneWayCoercible.gOneWayCoercible' instead we use 'oneWayCoercibleTrustMe'.+    --+    -- instance+    --   (e :> es) =>+    --   OneWayCoercible (DynamicReader r e) (DynamicReader r es)+    --   where+    --   oneWayCoercibleImpl = oneWayCoercibleTrustMe $ \\h ->     --     DynamicReader     --       { askLRImpl = 'useImpl' (askLRImpl h),     --         localLRImpl = \\f k -> useImplUnder (localLRImpl h f k)@@ -653,9 +666,9 @@     -- * Functions for making compound effects      -- ** @Handle@-    Handle (handleImpl, mapHandle),+    Handle (handleImpl),     HandleD,-    handleMapHandle,+    mapHandle,      -- ** @OneWayCoercible@ @@ -664,6 +677,7 @@     OneWayCoercible.OneWayCoercible (OneWayCoercible.oneWayCoercibleImpl),     OneWayCoercibleHandle (MkOneWayCoercibleHandle),     handleOneWayCoercible,+    withHandle,     OneWayCoercible.gOneWayCoercible,     oneWayCoercibleTrustMe,     -- | Bluefin re-exports @Generic@ for convenience.