Skip to content

Implement asumMap and foldMapA by coercing foldMap#191

Merged
vrom911 merged 2 commits intokowainik:masterfrom
josephcsible:coercefoldmap
Sep 21, 2019
Merged

Implement asumMap and foldMapA by coercing foldMap#191
vrom911 merged 2 commits intokowainik:masterfrom
josephcsible:coercefoldmap

Conversation

@josephcsible
Copy link
Copy Markdown
Contributor

This is how fmapDefault and foldMapDefault look in base,
and is useful for the same reasons.

Checklist:

HLint

  • I've changed the exposed interface (add new reexports, remove reexports, rename reexported things, etc.).
    • I've updated hlint.dhall accordingly to my changes (add new rules for the new imports, remove old ones, when they are outdated, etc.).
    • I've generated the new .hlint.yaml file (see this instructions).

General

  • I've updated the CHANGELOG with the short description of my latest changes.
  • All new and existing tests pass.
  • I keep the code style used in the files I've changed (see style-guide for more details).
  • I've used the stylish-haskell file.
  • My change requires the documentation updates.
    • I've updated the documentation accordingly.
  • I've added the [ci skip] text to the docs-only related commit's name.

Copy link
Copy Markdown
Contributor

@chshersh chshersh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a good change 👍 I have several suggestions but overall seems nice.

Copy link
Copy Markdown
Contributor

@chshersh chshersh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

josephcsible and others added 2 commits September 21, 2019 12:28
This is how `fmapDefault` and `foldMapDefault` look in base,
and is useful for the same reasons.
Co-Authored-By: Dmitrii Kovanikov <kovanikov@gmail.com>
@vrom911 vrom911 merged commit 97211f9 into kowainik:master Sep 21, 2019
@josephcsible josephcsible deleted the coercefoldmap branch September 21, 2019 21:20
@josephcsible
Copy link
Copy Markdown
Contributor Author

Note to self: If we ever have ala from Lens, or "via applications" from ghc-proposals/ghc-proposals#218, use those to make these even simpler.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants