Changes for clojure.core/condp

jafingerhut on Wed, 28 Mar 2012
user=> (condp (comp seq re-seq) "foo=bar"
         #"[+](\w+)"    :>> #(vector (-> % first (nth 1) keyword) true)
         #"[-](\w+)"    :>> #(vector (-> % first (nth 1) keyword) false)
         #"(\w+)=(\S+)" :>> #(let [x (first %)]
                               [(keyword (nth x 1)) (nth x 2)]))

[:foo "bar"]
kotarak on Tue, 13 Jul 2010
user=> (condp (comp seq re-seq) "foo=bar"
         #"[+](\w+)"    :>> #(vector (-> % first (nth 1) keyword) true)
         #"[-](\w+)"    :>> #(vector (-> % first (nth 1) keyword) false)
         #"(\w+)=(\S+)" :>> #(let [x (first %)]
                               [(keyword (nth x 1)) (nth x 2)]))

[:foo "bar"]