
I am +1 on this change. I was naively under the wrong impression that a simple instance NFData Bla is enough already with the current package. I would be nice if it worked, and the proposal seems to achieve this (at least if one derives Generic). --Andreas On 16.10.2014 21:41, Edward Kmett wrote:
On one hand, the change is a path to a better deepseq that is more correct.
On the other hand
1.) It does change the semantics of existing code.
2.) It does cause existing code that works to break if they don't supply a Generic instance or a manual default.
Admittedly:
#1 happens by making it more strict, which is what we want in the case of NFData, for once. #2 is something that is easily rectified and makes the resulting code more robust/useful anyways. Folks who don't want to lean on generics have the option to just write the rnf x = seq x ()default, so nobody is being forced to lean on the extension.
I'm somewhat on the fence about this, because I don't like silent semantics changes, but as it is only happening by making things more strict /in the one place in the language/ where that is the very point, you can consider me weakly +1.
-Edward
On Thu, Oct 16, 2014 at 1:09 PM, Andres Löh
mailto:andres.loeh@gmail.com> wrote: > The Proposal > ============ > > I hereby propose to merge `deepseq-generics`[2] into `deepseq`[1] in > order to add Generics support to the `NFData` class based on the > `-XDeriveGenerics` and `-XDefaultSignature` language extensions. > > A concrete patch is available for bike-review at [3]
+1
Cheers, Andres _______________________________________________ Libraries mailing list Libraries@haskell.org mailto:Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries
_______________________________________________ Libraries mailing list Libraries@haskell.org http://www.haskell.org/mailman/listinfo/libraries
-- Andreas Abel <>< Du bist der geliebte Mensch. Department of Computer Science and Engineering Chalmers and Gothenburg University, Sweden andreas.abel@gu.se http://www2.tcs.ifi.lmu.de/~abel/