Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
implementation Functor IOSpec where
map fn expr = Bind expr (Pure . fn)
implementation Applicative IOSpec where
pure = Pure
fExpr <*> aExpr = Bind fExpr (\f => map f aExpr)
implementation Monad IOSpec where
(>>=) = Bind
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment