[Haskell] Do you use GHC?

2005-04-15 Thread Simon Peyton-Jones
Dear Haskell folk, PLEASE READ THIS IF YOU USE THE Glasgow Haskell Compiler (GHC). I virtually never send messages to overlapping sets of lists, but I'm doing so this time, because I'd really like to get to everyone who uses GHC. Here at GHC HQ, we are often asked how many people use GHC, and w

Re: [Haskell] Control.Monad.Writer as Python generator

2005-04-15 Thread ChrisK
You are correct. Moand.Cont yield even runs without -O optimizing, just slower: Monad.Writer counts 10^9 zeros in 99 seconds (user time) Monad.Cont counts 10^8 zero in 35 seconds user time. So the writer is 3.5 times faster without '-O' With -O Monad.Writer counts 10^9 zeros in 105 seconds Monad

Re: [Haskell] Control.Monad.Writer as Python generator

2005-04-15 Thread Derek Elkins
On Fri, 15 Apr 2005 12:03:01 -0400 ChrisK <[EMAIL PROTECTED]> wrote: > You are correct. Moand.Cont yield even runs without -O optimizing, > just slower: > > Monad.Writer counts 10^9 zeros in 99 seconds (user time) > Monad.Cont counts 10^8 zero in 35 seconds user time. > So the writer is 3.5 tim

[Haskell] FroCoS 2005: Last Call for Papers

2005-04-15 Thread Bernhard Gramlich
[Apologies for multiple copies] FroCoS 2005: LAST CALL FOR PAPERS NEW: Submission site: http://www

Re: [Haskell] Control.Monad.Writer as Python generator

2005-04-15 Thread ChrisK
You are correct. Moand.Cont yield even runs without -O optimizing, just slower ... Anyone have an idea why ghci can't garbage collect it? Is this an actual bug or an innate quirk of the REPL ? GHCi does not "compile" with optimizations, without -O the strictness analyzer isn't run. The optimizer

[Haskell] big integer in haskell

2005-04-15 Thread ting wang
Hello all, I am a new learner, and i am trying to write a function to calculate factorial of a natural number: (I use ghc 6.4, window xp) fac :: Int -> Int fac n | n == 0 = 1 | n > 0 = fac (n-1) * n | otherwise = 0 this works when n < 14 and result is 1278945280, when n > 14 the answer is not right

Re: [Haskell] Control.Monad.Writer as Python generator

2005-04-15 Thread Jan-Willem Maessen
On Apr 15, 2005, at 6:07 PM, ChrisK wrote: You are correct. Moand.Cont yield even runs without -O optimizing, just slower ... Anyone have an idea why ghci can't garbage collect it? Is this an actual bug or an innate quirk of the REPL ? GHCi does not "compile" with optimizations, without -O the str

Re: [Haskell] Control.Monad.Writer as Python generator

2005-04-15 Thread ChrisK
On Apr 15, 2005, at 7:03 PM, Jan-Willem Maessen wrote: On Apr 15, 2005, at 6:07 PM, ChrisK wrote: You are correct. Moand.Cont yield even runs without -O optimizing, just slower ... Anyone have an idea why ghci can't garbage collect it? Is this an actual bug or an innate quirk of the REPL ? GHCi do

Re: [Haskell] big integer in haskell

2005-04-15 Thread Claus Reinke
Hi, the difference is that you restrict your function to Int, whereas the default type is Integer. See: http://www.haskell.org/onlinereport/decls.html#sect4.3.4 and http://www.haskell.org/onlinereport/basic.html#sect6.4 hth, claus btw, you can ask ghci to give you the type of each expression