Hi,

This isn't a bug in Hugs; it's a request for an enhancement.

It would be very nice if hugs would statically check the definitions
in a module to see if all patterns for a type are covered.  For example, if
the user wrote a function 

> sum_all :: [Int] -> Int
> sum_all (x:xs) = x + sum_all xs

then hugs should warn the user that the pattern [] is not covered
by the definition.  This warning might be toggled by a command line
switch if annoying.

SML has this feature, at least in the implementations I've used (SML/NJ),
and it's very helpful for students.

        Gary Leavens
        229 Atanasoff Hall, Department of Computer Science
        Iowa State Univ., Ames, Iowa 50011-1040 USA
        [EMAIL PROTECTED]  phone: +1 515 294-1580 fax: +1 515 294-0258
        URL: http://www.cs.iastate.edu/~leavens/homepage.html

Reply via email to