packages feed

creatur 5.7.2 → 5.7.3

raw patch · 2 files changed

+15/−3 lines, 2 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

+ ALife.Creatur.Persistent: modifyPS :: (Show a, Read a) => (a -> a) -> StateT (Persistent a) IO ()
+ ALife.Creatur.Persistent: runPS :: Read a => (a -> b) -> StateT (Persistent a) IO b

Files

creatur.cabal view
@@ -1,5 +1,5 @@ Name:              creatur-Version:           5.7.2+Version:           5.7.3 Stability:         experimental Synopsis:          Framework for artificial life experiments. Description:       A software framework for automating experiments@@ -36,7 +36,7 @@ source-repository this   type:     git   location: https://github.com/mhwombat/creatur.git-  tag:      5.7.2+  tag:      5.7.3  library   GHC-Options:      -Wall -fno-warn-orphans
src/ALife/Creatur/Persistent.hs view
@@ -15,7 +15,9 @@     Persistent,     mkPersistent,     getPS,-    putPS+    putPS,+    modifyPS,+    runPS   ) where  import ALife.Creatur.Util (modifyLift)@@ -47,6 +49,16 @@   modify (\p -> p { psValue=s })   p' <- get   liftIO $ store p'++modifyPS :: (Show a, Read a) => (a -> a) -> StateT (Persistent a) IO ()+modifyPS f = do+  p <- getPS+  putPS $ f p++runPS :: Read a => (a -> b) -> StateT (Persistent a) IO b+runPS f = do+  p <- getPS+  return $ f p  store :: Show a => Persistent a -> IO () store p = do