Deprecate Foldable for Either

Kris Nuttycombe kris.nuttycombe at gmail.com
Fri Mar 3 17:45:51 UTC 2017


On Fri, Mar 3, 2017 at 10:37 AM, Richard Eisenberg <rae at cs.brynmawr.edu>
wrote:

> I think one of the reasons this debate continues to crop up is that there
> is a fundamental tension in the design of Haskell:
>
> Haskell strives to be
>   a) richly typed, leading to "if it compiles, it works!"
>   b) as general as possible, leading to wide applicability of polymorphic
> functions
>
> These two laudable goals work against each other. In many instances, we
> will have to choose between them, and different people will have different
> judgment calls.


This is an interesting assertion; I don't believe that these goals work
against one another at all. In fact, I find that (b) leads to "if it
compiles, it works" much more often than not. John De Goes goes into depth
on this principle here:
http://degoes.net/articles/insufficiently-polymorphic where he points out
"Monomorphic code is much more likely to be incorrect than polymorphic
code, because for every type signature, there are many more possible
implementations.".
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20170303/f5aae9d1/attachment-0001.html>


More information about the Libraries mailing list