Hi Peter,
I'm delighted to hear about your successes with Haskell programming!
I suspect that parametric polymorphism has a lot to do with phenomenon of
works-when-it-compiles. The more polymorphic a signature is, the fewer the
possible type-correct definitions. Luckily, the definition that "works" is
one of the few type-correct ones. As John Reynolds and then Phil Wadler
showed, some useful properties necessarily hold purely as a consequence of
the polymorphic type, regardless of the implementation. (See "Theorems for
free".)
- Conal
2009/2/14 Peter Verswyvelen
One of the things I liked a lot when working with C# was that as soon as my code compiled, it usually worked after an iteration of two.At least if we forget about the nasty imperative debugging that is needed after a while because of unanticipated and unchecked runtime side effects. After heaving read about Haskell and having written some small programs for the last year or so, I'm now finally writing a bigger program with it. It is not so easy yet since learning a language and trying to reach a deadline at the same time is hard :)
However, it is just amazing that whenever my Haskell program compiles (which to be fair can take a while for an average Haskeller like me ;-), it just... works! I have heard rumors that this was the case, but I can really confirm it.
A bit hurray for strong typing! (and if you don't like it, you can still use Dynamic and Typeable ;-)
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe