
5 Dec
2008
5 Dec
'08
1:02 p.m.
On Fri, Dec 05, 2008 at 06:56:46PM +0100, Thomas Davie wrote:
Which reminds me ofc, that there is a valid applicative for states (assuming the monad instance is valid):
instance Applicative (StateT s f) where pure = return (<*>) = ap
All monads are also applicatives ;)
Sure, as long as you add the assumption Monad f.