(strange) huge difference

Andre W B Furtado awfurtado@uol.com.br
Tue, 6 Nov 2001 03:27:41 -0200


I was surprised when the very simple following program, once compiled with
GHC-4.08.1, generated a 28.8 Kb file, but when compiled with GHC-5.02
generated a 436 Kb file. Is this the GHC behavior to be expected?

fac :: Int -> Int
fac n = product [1..n]

main :: IO ()
main = do
 putStrLn "HELLO WORLD"
 putStrLn (show (fac 5))


-- Andre