Skip to content
This repository has been archived by the owner on Jun 3, 2023. It is now read-only.

Keep should return results of transform #31

Open
greghart opened this issue Nov 18, 2015 · 2 comments
Open

Keep should return results of transform #31

greghart opened this issue Nov 18, 2015 · 2 comments

Comments

@greghart
Copy link

I was reading through the documentation, and noticed that keep was basically the same as filter. Looking into it a bit more, I believe keep is supposed to return the results of the transform that are not null as opposed to the original values, as laid out at https://clojuredocs.org/clojure.core/keep .

var t = transducers;
var xf = t.keep(function(x) { if(typeof x == "string") return "cool"; });
t.into([], xf, [0,1,"foo",3,4,"bar"]); // ["foo","bar"] -> should return ['cool', 'cool']
@shaunc
Copy link

shaunc commented Apr 24, 2017

(Is this project still active?... no activity despite PRs waiting...)

@puredanger
Copy link
Contributor

I agree with your analysis here - keep should be returning the results of the transform.

This project is still active, but is maintained by people with many other projects, so it only gets periodic attention.

Also, as noted in the readme, this project does not accept pull requests.

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

No branches or pull requests

3 participants