[Haskell-cafe] Best idiom for avoiding Defaulting warnings with ghc -Wall -Werror ??

Neil Mitchell ndmitchell at gmail.com
Sat Jun 23 16:23:34 EDT 2007


Hi

> > All the puffing about the advantages of
> > strong typing look pretty silly if code hangs up on an incomplete
> > pattern.
>
> Okay... people who don't worry so much about incomplete patterns believe
> that they get things done.
>
> There are trade offs in type systems about how much effort you want to
> require of the user and how much the type system will catch.  Haskell's
> type system is at a point that does a lot with very little.  You can do
> ridiculously more if you don't mind requiring more from the user.

I know Catch got mentioned at the beginning of this thread, but it
does read like an advert for Catch :) You can have existing Haskell
with no annotations that is proven free from pattern-match errors
automatically. You can do the trick of saying error "this branch
cannot be reached", then Catch will validate that you are correct.

http://www-users.cs.york.ac.uk/~ndm/catch/

Thanks

Neil


More information about the Haskell-Cafe mailing list