seq as a class method
Manuel M T Chakravarty
chak at cse.unsw.edu.au
Fri Mar 24 15:32:36 EST 2006
> Wolfgang Jeltsch:
> >it seems that there is not yet a ticket about putting seq into a type class
And I hope it stays that way.
> This sounds like a good idea in principle, but it was a nightmare in
> First, the implementation details and the difference between _|_ and
> const _|_
> make a difference to space behaviour, and one needs a way to control that.
> Hiding the differences can make space leaks *impossible* to fix.
Along similar lines: I like Haskell being lazy, but it has to make it
easier for the programmer to enforce eager evaluation where necessary
for good resource utilisation. `seq' already is annoying and
inconvenient (as it forces you to re-arrange your code), let's not make
it worse. I'd like Haskell' to make it easier to force evaluation,
which is why I like the bang pattern proposal.
More information about the Haskell-prime