I'll give the full desugaring, perhaps that will make it more clear:
> foo :: (Monad m) => m Int
> foo = return id >>= (\i -> return (i 7))
>
> fooSet :: Set Int
> fooSet = foo
mkMonadDictSet :: EqDict a -> MonadDict Set
eqDictInt :: EqDict Int
return :: MoandDict m -> a -> m a
foo :: MonadDict m -> m Int
foo monadDict = (>>=) monadDict
(return monadDict id)
(\i -> return monadDict (i 7))
fooSet :: Set Int
fooSet = foo (mkMonadDictSet eqDictInt)
John
--
John Meacham - ⑆repetae.net⑆john⑈
_______________________________________________
Haskell-prime mailing list
[email protected]
http://haskell.org/mailman/listinfo/haskell-prime