I've written two versions of a prime number sieve, and I'm trying to figure out how to performance test them. I've found functions to get the current date and time, and to subtract them, but when I put them in a do notation, I guess the laziness or something, makes the calculation happen first, then the two times are called, so I get almost 0 difference between the two.

I guess I'm looking for something like this:
timer :: (a -> b) -> a -> IO TimeDiff

Spencer Janssen

_______________________________________________
Haskell mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/haskell

Reply via email to