This repository was archived by the owner on Oct 4, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 30
filterValues and filterKeys #97
Merged
paf31
merged 4 commits into
purescript-deprecated:master
from
matthewleon:filters-squashed
Jun 4, 2017
Merged
filterValues and filterKeys #97
paf31
merged 4 commits into
purescript-deprecated:master
from
matthewleon:filters-squashed
Jun 4, 2017
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
paf31
reviewed
Jun 3, 2017
src/Data/StrMap.purs
Outdated
|
||
-- | Filter out those key/value pairs of a map for which a predicate | ||
-- | fails to hold. | ||
filter :: forall a. (String -> a -> Boolean) -> StrMap a -> StrMap a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
filterWithKey
perhaps?
paf31
reviewed
Jun 3, 2017
src/Data/StrMap.purs
Outdated
|
||
-- | Filter out those key/value pairs of a map for which a predicate | ||
-- | on the value fails to hold. | ||
filterValues :: forall a. (a -> Boolean) -> StrMap a -> StrMap a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would just call this one filter
actually.
Sorry for the bikeshedding 😁 cc @hdgarrood |
Nothing to be sorry about, someone's gotta do it! |
whitespace pluralize test fixes simplify tests use ST to reduce algorithmic complexity
also add documentation
3b43471
to
54534ea
Compare
following review: purescript-deprecated#97 (review)
👍 for |
matthewleon
added a commit
to matthewleon/purescript-maps
that referenced
this pull request
Jun 4, 2017
Thanks! |
paf31
pushed a commit
that referenced
this pull request
Jun 4, 2017
* persistent map filters and isSubMap * rename filter fns following review #97 (review)
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
supersedes #80
Rebases and implements the suggestions in that PR.