[Haskell-cafe] I'd like start with Haskell, but...
bulat.ziganshin at gmail.com
Sun Dec 17 12:33:49 EST 2006
Sunday, December 17, 2006, 5:46:57 PM, you wrote:
> sum <- newIORef 0
> why in the world would you write a summation function like that?
gui/db libs are imperative ones and using them you need to deal with a lot
of mutable values. this example shows that programming with mutable data is
less better done in C than in Haskell - imperative language has a lot of
syntax sugar which allows automatic generation of all those
readIORef/writeIORef calls (or their equivalents)
Bulat mailto:Bulat.Ziganshin at gmail.com
More information about the Haskell-Cafe