Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Foldable instance defaults can cause CycleInDeclaration error #396

Open
jmatsushita opened this issue Jul 27, 2021 · 1 comment
Open

Foldable instance defaults can cause CycleInDeclaration error #396

jmatsushita opened this issue Jul 27, 2021 · 1 comment

Comments

@jmatsushita
Copy link

I just bumped into the problem mentioned here https://stackoverflow.com/a/38490637/3237351 and the solution was also indeed to go from foldl = foldlDefault to fold f = foldlDefault f. It feels like this could be better documented in the Foldable instance. Maybe by simply giving a trivial example like the one in SO.

File this documentation issue on the foldable-traversable repo purescript/purescript-foldable-traversable#139 but thought that it would be also good to have this (probably common) case mentioned in the possible causes, or maybe as a note?

@JordanMartinez
Copy link
Contributor

I think this is worth having. It's sort of special casing for that situation, but it would be nice to know about this quirky situation sooner.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants