packages feed

acquire 0.3.4 → 0.3.5

raw patch · 2 files changed

+13/−1 lines, 2 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

+ Acquire: startAndStop :: IO a -> (a -> IO ()) -> Acquire a

Files

acquire.cabal view
@@ -1,6 +1,6 @@ cabal-version: 3.0 name:          acquire-version:       0.3.4+version:       0.3.5 synopsis:      Abstraction over management of resources description:   An implementation of the abstraction suggested in
library/Acquire.hs view
@@ -56,6 +56,18 @@   liftIO io =     Acquire (fmap (,return ()) io) +-- | Construct 'Acquire' by specifying a resource initializer and finalizer actions.+startAndStop ::+  -- | Start the service.+  IO a ->+  -- | Stop the service.+  (a -> IO ()) ->+  Acquire a+startAndStop start stop =+  Acquire $ do+    logger <- start+    pure (logger, stop logger)+ -- * Use  -- |