
17 Dec
2006
17 Dec
'06
12:33 p.m.
Hello Dan, 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) -- Best regards, Bulat mailto:Bulat.Ziganshin@gmail.com