Improve Data.Functor documentation

Tony Morris tonymorris at gmail.com
Thu Nov 14 17:05:22 UTC 2019


+1 on both points and especially the second one.

On 11/11/19 10:30 pm, chessai . wrote:
> A beginner learning about parametricity and the relationship between
> Functorial composition and Functor identity brought up a good point to
> me: the documentation for Bifunctor[1] and Profunctor[2] both explain
> the relationship between parametricity and their laws, particularly
> what constitutes a minimum "burden" of proof. I don't have an exact
> wording yet, but I think it would be a good idea to update the Functor
> documentation accordingly. 
>
> A separate point of issue: The line "The instances of Functor for
> lists, Maybe and IO satisfy these laws." This statement is redundant
> at best when you consider that Haskellers aim for instances of Functor
> to be lawful. At worst it could leave beginners confused and with more
> questions. I could imagine someone interpreting this statement as
> saying there might exist some unlawful instances. I think this line
> should just be removed.
>
> Let me know what you think.
>
> Thanks
>
>
>
> _______________________________________________
> Libraries mailing list
> Libraries at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20191115/a97d8a6f/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20191115/a97d8a6f/attachment.sig>


More information about the Libraries mailing list