moonlite at dtek.chalmers.se
Fri Jan 26 17:33:59 EST 2007
On Fri, 2007-01-26 at 23:26 +0100, Mattias Bengtsson wrote:
> On Fri, 2007-01-26 at 11:34 -0800, Chad Scherrer wrote:
> > This seems like a natural thing to have around, but it's not in GHC
> > 6.6...
> > newTArrayIO :: (Enum i, Ix i) => (i, i) -> a -> IO (TArray i a)
> > newTArrayIO (a,b) = liftM (TArray . listArray (a,b)) . sequence .
> > zipWith ignore [a..b] . repeat . newTVarIO
> > where ignore = flip const
> > I haven't done any testing with this beyond type checking, but it
> > seems like it could be useful for similar cases to newTVarIO. Has
> > anyone else played with anything similar?
> Agree. I learned lots regarding technologies that seemed like pure magic
> before, like GADT's and fundeps etc.
> Definately a good read.
Hrrm. This was meant as a reply to Justin Bailey, sorry.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20070126/74e197e1/attachment.bin
More information about the Haskell-Cafe