From f12b6bc046d3ebe60792f0bf10713800e547dc6e Mon Sep 17 00:00:00 2001 From: Nathan Marz Date: Fri, 18 Sep 2015 15:01:01 -0400 Subject: [PATCH] fix typo/formatting --- src/com/rpl/specter.cljc | 5 +++-- test/com/rpl/specter/core_test.cljc | 6 +++--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/com/rpl/specter.cljc b/src/com/rpl/specter.cljc index c13c26f..04cf692 100644 --- a/src/com/rpl/specter.cljc +++ b/src/com/rpl/specter.cljc @@ -117,7 +117,7 @@ )) (defn replace-in - "Similar to transform, except returns a pair of [transformd-structure sequence-of-user-ret]. + "Similar to transform, except returns a pair of [transformed-structure sequence-of-user-ret]. The transform-fn in this case is expected to return [ret user-ret]. ret is what's used to transform the data structure, while user-ret will be added to the user-ret sequence in the final return. replace-in is useful for situations where you need to know the specific values @@ -164,6 +164,7 @@ (i/srange-transform structure start end next-fn) )) + (def BEGINNING (srange 0 0)) (def END (srange-dynamic count count)) @@ -307,7 +308,7 @@ "Adds an external value to the collected vals. Useful when additional arguments are required to the transform function that would otherwise require partial application or a wrapper function. - + e.g., incrementing val at path [:a :b] by 3: (transform [:a :b (putval 3)] + some-map)"} putval diff --git a/test/com/rpl/specter/core_test.cljc b/test/com/rpl/specter/core_test.cljc index 9bc34b9..28d7965 100644 --- a/test/com/rpl/specter/core_test.cljc +++ b/test/com/rpl/specter/core_test.cljc @@ -526,13 +526,13 @@ #?(:clj (deftest large-params-test (let [path (apply s/comp-paths (repeat 25 s/keypath)) - m (reduce + m (reduce (fn [m k] {k m}) - :a + :a (reverse (range 25)))] (is (= :a (s/select-one (apply path (range 25)) m))) )) -;;TODO: there's a bug in clojurescript that won't allow +;;TODO: there's a bug in clojurescript that won't allow ;; non function implementations of IFn to have more than 20 arguments )