(macroexpand-1 '(-> dna (map f) foo))
(foo (map dna f))
(-> [[1 2] 3 4] first second)
2
(macroexpand-1 '(-> :abc name str/upper-case keyword))
(keyword (str/upper-case (name :abc)))
(map #(-> [%]) [5 10 15])
([5] [10] [15])
(macroexpand-1 `(-> ["a"] (fn [x] x)))
(clojure.core/fn ["a"] [user/x] user/x)
(map #(-> [%]) [1 2 3])
([1] [2] [3])
(-> 321 Integer/toString cycle ((partial take 4)))
(\3 \2 \1 \3)
(-> "oh hai" .toUpperCase (.replace "H" "B"))
"OB BAI"
(-> {} (cond-> (true? true) (assoc :bar 1)))
{:bar 1}
(-> {:body ""} (assoc :cookies {:name "cookie-value"}))
{:body "", :cookies {:name "cookie-value"}}
(-> 1 (/ 3) (->> (- 2)))
5/3
(macroexpand-1 '(-> a b c d))
(d (c (b a)))
(-> [] (conj (when (= 1 2) 12)))
[nil]
(-> 1 (+ 1) (->> (* 3)))
6
(macroexpand '(-> [foo] (fn (print foo))))
(fn [foo] (print foo))
(-> (rand-int 2) (* 2) (- 1))
-1
((-> [a] #(* 2 a)) 3)
6
(-> 10 inc inc inc inc inc)
15
(-> 5 (- 1) (->> (str "->")))
"->4"
(-> (range 33) vec transient pop! count)
32
(-> 1 inc (inc) ((partial * 3)))
9
(-> "foobar" .toUpperCase (subs 3 6) .intern)
"BAR"
(-> [] (with-meta {:foo 1}) (conj :x) meta)
{:foo 1}
(macroexpand '(-> 25 Math/sqrt int list))
(list (int (Math/sqrt 25)))
(-> [1 2 3 4] (into-array) (count))
4
(macroexpand-1 '(-> foo (bar baz) bbq))
(bbq (bar foo baz))
(-> {:a 1, :b 2} (dissoc :a))
{:b 2}
(macroexpand (-> [1 2 3] sort reverse))
(3 2 1)
(defn doc* [arg] (-> arg meta :doc))
#'user/doc*
(macroexpand-1 '(-> [%] #(list %)))
(fn* [%] [%1] (list %1))
(-> "addition" {"addition" +} (apply [1 2]))
3
(defn foo [m] (-> m :str .length))
#'user/foo
(-> (+ 2 4) (* 7) -)
-42
(macroexpand-1 '(-> b (update-in [:a] inc)))
(update-in b [:a] inc)
(-> {:a 0, "b" 4} (get "b"))
4
(-> 'clojure.core ns-publics first second meta :doc)
"Returns the sum of nums. (+') returns 0. Supports arbitrary precision.\n See also: +"
(-> [] (concat (when (= 1 2) [12])))
()
(macroexpand '(-> arg1 fname Thread. .start))
(.start (Thread. (fname arg1)))
(macroexpand '(-> (generate-seq) (map println) doall))
(doall (map (generate-seq) println))
(macroexpand '(-> [a 5] (let a)))
(let [a 5] a)
(macroexpand-1 '(-> "foo" (fn [x] x)))
(fn "foo" [x] x)
(macroexpand-1 '(-> x y z w))
(w (z (y x)))
(-> (fn [] 42) (with-meta {:x :y}) meta)
{:x :y}
(macroexpand '(-> 123 #(println %)))
(fn* 123 [%1] (println %1))
(#(-> % inc inc inc) 1)
4
(-> 100 (+ 10 10) (/ 12))
10
(-> [] (conj 1) (conj 2) (conj 3))
[1 2 3]
(doto (count "heyho") (-> (= 5) (assert)))
5
(-> {:a 1, :b 2} keys set)
#{:a :b}
(-> (a b c) quote rest type)
clojure.lang.PersistentList