Monad transformers

1 · Shane Mulligan · Nov. 27, 2019, 11 a.m.
Original resource https://wiki.haskell.org/Meta-tutorial grok haskell monad transformers Original article http://blog.sigfpe.com/2006/05/grok-haskell-monad-transformers.html State monad 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 import Control.Monad.Identity import Control.Monad.State test1 = do a <- get modify (+1) b <- get return (a,b) test2 = do a <- get modify (++"1") b <- get return (a,b) go1 = evalState test1 0 go2 = evalSta...