> You should do the counting strictly:
> 
>         Just n -> case n+1 of n1 -> addToFM f w n1

Careful - that case expression doesn't actually force n to be evaluated.
It's exactly equivalent to
                
   let n1 = n+1 in addToFM f w n1

You need to use seq to force evaluation.

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

Reply via email to