rewrite-clj

https://github.com/clj-commons/rewrite-clj
borkdude 2019-04-10T18:39:53.003900Z

Hi! @lee I want to make sure if I understood you correctly here: https://github.com/xsc/rewrite-clj/pull/71

borkdude 2019-04-10T18:40:10.004400Z

Are you going to work on this solely in rewrite-cljs or contribute back to rewrite-clj as well?

2019-04-10T22:47:34.005Z

@borkdude i'm sure @lee will answer but in the meantime, does the following touch on your question? https://github.com/clj-commons/rewrite-cljs/issues/19

2019-04-10T22:51:27.008600Z

@lee i've looked through rewrite-clj and rewrite-cljs a bit more with an eye toward a zipper that is aware of comments but will skip whitespace, and i'm getting the sense that trying to implement this in the custom zipper is likely to be easier than in clojure.zip (though i have an idea of how it might be done in the latter too). the further thought of being able to pass in different types of things to skip came up -- may be stimulated by what you said about folks wanting to skip uneval too. do you think having the custom zipper map carrying around what sorts of things it skips (or doesn't) and having that consulted when it is instructed to move, makes sense?

lread 2019-04-10T23:17:35.012100Z

Hi @borkdude, I will be happy to contribute back to rewrite-clj. If I am successful in converting rewrite-cljs to a cljc project, we might not need 2 projects though. We’ll see what the author of rewrite-clj thinks after I have something to show.

lread 2019-04-10T23:22:40.014600Z

@sogaiu, I think that probably makes sense, but would you ever want to change what you skip after the zipper is created? It was @plexus who was interested in skipping uneval nodes: https://github.com/xsc/rewrite-clj/issues/70

2019-04-10T23:37:23.017300Z

@lee thanks for that link. i didn't expect to want to change what to skip after the zipper is created -- i think i'm missing some implication here in your comment though, would you mind elaborating on it? is there something unnecessary about carrying the items to skip (or not) around?

lread 2019-04-10T23:41:51.020900Z

that was the only thing I could think of. I was thinking about alignment work I am doing for cljfmt, at first I was skipping unevals and then changed my mind. That’s it, just musing.