Bulat Ziganshin wrote:

> instead of writing 
> foo :: (Num a, Monad m) => a -> m ()
> allow to write
> foo :: Num -> Monad ()

as has been noted, that would be special treatment
for unary type classes with argument of kind *.

Also, *if* we want such a shorthand, it is not clear whether we want
existential or forall typing per default. Referring to your example,
the "foo" function must be able to return a value in *each* monad
that the caller specifies at the call site, while we were discussing
functions that make their own choice of returning *some* monad instance.

Best regards,
-- 
-- Johannes Waldmann -- Tel/Fax (0341) 3076 6479/80 --
---- http://www.imn.htwk-leipzig.de/~waldmann/ -------

_______________________________________________
Haskell-prime mailing list
Haskell-prime@haskell.org
http://haskell.org/mailman/listinfo/haskell-prime

Reply via email to