
16 Apr
2003
16 Apr
'03
9:14 a.m.
Axel Simon wrote:
I see three strands of modelling widget hierarchies in Haskell:
1.) Don't. Each widget has an individual type, unconnected to the other widgets. (Glynn's ponit of view, if I am not mistaken)
No; my view is *not* to have distinct Haskell types for each widget
class. I should be able to replace any widget by a "compatible" widget
(e.g. a subclass) without having to change all of the code which uses
that widget.
Either have a single generic Widget type (with type checks deferred to
run time), or use type classes.
--
Glynn Clements