[Haskell-beginners] mayBe stuck

Daniel Fischer daniel.is.fischer at web.de
Fri Aug 6 09:18:17 EDT 2010


On Friday 06 August 2010 14:52:06, aditya siram wrote:
> Doesn't the -Wall flag pick that up?
> -deech

Not if there's an explicit error call for the undefined cases, e.g.

head :: [a] -> a
head (x:_) = x
head _ = error "Prelude.head: empty list"

compiles without warning.


More information about the Beginners mailing list