
5 Jul
2006
5 Jul
'06
10:49 a.m.
Hi With the following program: --------------------------------- import System main = do (x:_) <- getArgs print $ fact (read x) fact :: Int -> Int fact 0 = 1 fact n | n > 0 = n * fact (n - 1) -------------------------------- Running Main without any arguments via Hat gives me a trace, and the error message:
Error: pattern-match failure in do expression
Running hat-stack Main.hat gives me:
Tracefile "Main.hat" contains no reference to a program error.
How come? I get the same results on both Windows and Linux. Thanks Neil