<div dir="auto">I'll try to take a look. When writing instances (which I consider a beginner-level activity), it's really important to learn to follow the laws. While that may just sound like a bunch of theory, it turns out that in practice violating typeclass laws leads to seriously unintuitive behavior, breaking the expectations users have developed after using many instances.</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Sep 18, 2021, 9:47 PM Viktor Dukhovni <<a href="mailto:ietf-dane@dukhovni.org">ietf-dane@dukhovni.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Thu, Sep 16, 2021 at 09:56:37PM -0400, Viktor Dukhovni wrote:<br>
<br>
> Surely a one click link from the Prelude re-export is no worse than a 1-click link<br>
> in the module table of contents?<br>
> <br>
> I am rather reluctant beat new readers over the head with laws that often are much<br>
> too abstract to add clarity.<br>
<br>
I've opened an MR: <a href="https://gitlab.haskell.org/ghc/ghc/-/merge_requests/6555" rel="noreferrer noreferrer" target="_blank">https://gitlab.haskell.org/ghc/ghc/-/merge_requests/6555</a><br>
<br>
that adds a "Laws" link to the class head haddocks, and attempts to<br>
improve some prose that was found a bit wanting in the recent threads.<br>
<br>
    <a href="https://dnssec-stats.ant.isi.edu/~viktor/haskell/docs/libraries/base/Prelude.html#g:11" rel="noreferrer noreferrer" target="_blank">https://dnssec-stats.ant.isi.edu/~viktor/haskell/docs/libraries/base/Prelude.html#g:11</a><br>
<br>
    <a href="https://dnssec-stats.ant.isi.edu/~viktor/haskell/docs/libraries/base/Data-Foldable.html#overview" rel="noreferrer noreferrer" target="_blank">https://dnssec-stats.ant.isi.edu/~viktor/haskell/docs/libraries/base/Data-Foldable.html#overview</a><br>
<br>
The Overview of Data.Foldable is aimed at a novice to intermediate<br>
Haskell programmer, not a complete beginner or someone long familiar<br>
with the ins and outs of folds.  The idea is to help the reader be able<br>
to reason about the various Foldable methods and choose the right one<br>
for the task at hand.  Maybe, though not the main intent, to write better<br>
Foldable instances (if not simply derived).<br>
<br>
Perhaps the intended audience should be explicitly stated, to save<br>
complete beginners who are not ready for it, or seasoned Haskellers who<br>
don't need it the trouble of figuring out whether the content is for<br>
them???<br>
<br>
-- <br>
        Viktor.<br>
_______________________________________________<br>
Haskell-Cafe mailing list<br>
To (un)subscribe, modify options or view archives go to:<br>
<a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe" rel="noreferrer noreferrer" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe</a><br>
Only members subscribed via the mailman list are allowed to post.</blockquote></div>