Skip to content

Commit

Permalink
Avoid a lazy pmapping
Browse files Browse the repository at this point in the history
  • Loading branch information
vemv authored and bbatsov committed Sep 16, 2021
1 parent 1b64607 commit eb77344
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/refactor_nrepl/core.clj
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@
Note that files which are non-existent, hidden or build-artifacts
are pruned by this function."
[pred dir]
;; ensure pmap is not used lazily:
{:post [(vector? %)]}
(->> dir
file-seq
;; `pmap` performs better in large projects.
Expand All @@ -112,7 +114,7 @@
(complement build-artifact?))
f)
f)))
(filter identity)))
(filterv identity)))

(defn read-ns-form
([path]
Expand Down

0 comments on commit eb77344

Please sign in to comment.