
26 Feb
2007
26 Feb
'07
4:44 a.m.
Hello Tim, Monday, February 26, 2007, 2:26:44 AM, you wrote:
Rather than using existential types, a simple record of functions can be often be useful. ie:
data Component = Component { draw :: String add :: Component -> Component }
Steve, you can look at the pages http://haskell.org/haskellwiki/OOP_vs_type_classes http://haskell.org/haskellwiki/IO_inside which describes some alternatives to OO approach used in functional programming world and Haskell in partial. because first page is just about switching from OOP to Haskell, you may consider adding to this page patterns you've designed -- Best regards, Bulat mailto:Bulat.Ziganshin@gmail.com