[{"name":"Monad.List","comment":"\n\n\n# List Monad\n\n@docs return, bind, fail\n\n","unions":[],"aliases":[],"values":[{"name":"bind","comment":" bind function for List\n\nThe behavior is the same as the concatMap\n\n","type":"List.List a -> (a -> List.List b) -> List.List b"},{"name":"fail","comment":" fail function for List\n","type":"a -> List.List a"},{"name":"return","comment":" return function for List\n","type":"a -> List.List a"}],"binops":[]},{"name":"Monad.Maybe","comment":"\n\n\n# Maybe Monad\n\n@docs return, bind, fail\n\n","unions":[],"aliases":[],"values":[{"name":"bind","comment":" bind function for Maybe\n","type":"Maybe.Maybe a -> (a -> Maybe.Maybe b) -> Maybe.Maybe b"},{"name":"fail","comment":" fail function for Maybe\n","type":"a -> Maybe.Maybe a"},{"name":"return","comment":" return function for Maybe\n","type":"a -> Maybe.Maybe a"}],"binops":[]},{"name":"Monad.State","comment":"\n\n\n# State Monad\n\nComputations which maintain state.\n\nBinding strategy: Binding threads a state parameter through the sequence of bound functions so that the same state value is never used twice, giving the illusion of in-place update.\n\nUseful for: Building computations from sequences of operations that require a shared state.\n\n@docs State\n@docs return, bind, runState\n@docs get, put\n@docs evalState, execState\n\n","unions":[{"name":"State","comment":" State\n","args":["s","a"],"cases":[["State",["s -> ( a, s )"]]]}],"aliases":[],"values":[{"name":"bind","comment":" bind function for State\n","type":"Monad.State.State s a -> (a -> Monad.State.State s b) -> Monad.State.State s b"},{"name":"evalState","comment":" Get the new value\n","type":"Monad.State.State s a -> s -> a"},{"name":"execState","comment":" Get the new state\n","type":"Monad.State.State s a -> s -> s"},{"name":"get","comment":" Get current state\n","type":"Monad.State.State a a"},{"name":"put","comment":" Put a new state\n","type":"s -> Monad.State.State s ()"},{"name":"return","comment":" return function for State\n","type":"a -> Monad.State.State s a"},{"name":"runState","comment":" Run the state\n","type":"Monad.State.State s a -> s -> ( a, s )"}],"binops":[]},{"name":"Monad.Writer","comment":"\n\n\n# Writer Monad\n\nThe definition of writer monad in Haskell is\n\n    newtype Writer w a = Writer { runWriter :: (a,w) }\n\nwhere `w` should be monoid (with mappend function).\n\nWe assume you only use List so we replace `w` with `List w`\n\n@docs Writer\n@docs return, runWriter, bind, tell\n\n","unions":[{"name":"Writer","comment":" Writer\n","args":["w","a"],"cases":[["Writer",["( a, List.List w )"]]]}],"aliases":[],"values":[{"name":"bind","comment":" bind function for Writer\n","type":"Monad.Writer.Writer w a -> (a -> Monad.Writer.Writer w b) -> Monad.Writer.Writer w b"},{"name":"return","comment":" return function for Writer\n","type":"a -> Monad.Writer.Writer w a"},{"name":"runWriter","comment":" Run the writer\n","type":"Monad.Writer.Writer w a -> ( a, List.List w )"},{"name":"tell","comment":" tell function for Writer\n","type":"List.List w -> Monad.Writer.Writer w ()"}],"binops":[]}]