[Haskell-cafe] Re: ANNOUNCE: deepseq-

Simon Marlow marlowsd at gmail.com
Thu Nov 19 06:24:03 EST 2009

On 18/11/2009 04:05, Malcolm Wallace wrote:
>> The documentation claim that "The default implementation of 'deepseq'
>> is simply 'seq'" is not exactly right, as `deepseq` and `seq` have
>> different signatures.
> Yes indeed. In order to use deepseq, it looks like I also need some way
> to force the () return value, e.g.
> let res = deepseq (my big computation)
> in res `seq` use res
> or
> let res = deepseq (my big computation)
> in case res of () -> use res


let !res = deepseq (my big computation)
in use res


More information about the Haskell-Cafe mailing list