[Haskell-cafe] Question on type synonym definition and language extensions

Olivier Boudry olivier.boudry at gmail.com
Thu May 29 17:19:56 EDT 2008


On Thu, May 29, 2008 at 4:38 PM, Henning Thielemann <
lemming at henning-thielemann.de> wrote:

> Is
>
>  type Matrix monad array num = monad (array (Int,Int) num)
>
> ok for you?
>

Not really what I was looking for but I may end up using it.

What I wanted is to hide the Monad and Array and have it inferred from the
context of the array

STArray or STUArray when run in the ST monad with runST(U)Array, IOArray or
IOUArray when used in the IO monad, etc...

I'm not sure it's the right thing to do. I may create more troubles than I
solve. I was just trying to keep things as generic as possible.

Thanks for your reply,

Olivier.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20080529/804d85a4/attachment-0001.htm


More information about the Haskell-Cafe mailing list