deepseq: Add more instances. #50

Richard Eisenberg rae at richarde.dev
Wed Jan 15 08:58:33 UTC 2020


I'd be in favor of adding the instances. Programming with pointers is hard and annoying. It's one of the reasons we like Haskell, where usually we don't have to worry about it. But if you are going to program with pointers, you already need to understand the notion of indirection, and so I don't think these instances will particularly throw people off.

Richard

> On Jan 15, 2020, at 7:55 AM, Henning Thielemann <lemming at henning-thielemann.de> wrote:
> 
> 
> On Tue, 14 Jan 2020, chessai . wrote:
> 
>> David put my thoughts pretty clearly: is it more useful or more confusing? I am also leaning toward more confusing. Hopefully more can weigh in on this.
> 
> I also think NFData instances for reference types are more dangerous than helpful. Since laziness and strictness account for subtle programming mistakes, it is better if GHC tells you that 'rnf tvar' does possibly not perform what you expect. I'd even consider to add an instance with a type error message to show the user that this instance has been omitted by intention.
> _______________________________________________
> Libraries mailing list
> Libraries at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries



More information about the Libraries mailing list