store/[org.clojure/clojure "1.8.0"] clj::clojure.core/bound-fn

Official Documentation

Add notes
Arities
==================================================
   [& fntail]

Docstring
==================================================
  Returns a function defined by the given fntail, which will install the
  same bindings in effect as in the thread at the time bound-fn was called.
  This may be used to define a helper function which runs on a different
  thread, but needs the same bindings in place.

Source

(defmacro bound-fn
  "Returns a function defined by the given fntail, which will install the
  same bindings in effect as in the thread at the time bound-fn was called.
  This may be used to define a helper function which runs on a different
  thread, but needs the same bindings in place."
  {:added "1.1"}
  [& fntail]
  `(bound-fn* (fn ~@fntail)))

Example 1

Edit
(def ^:dynamic *some-var* nil)

(defn f [] (println *some-var*))

;; run f without a new binding
(f)
;; > nil
;; => nil

;; run f with a new binding
(binding [*some-var* "hello"]
  (f))
;; > hello
;; => nil

;; run f in a thread with a new binding
(binding [*some-var* "goodbye"]
  (.start (Thread. f)))
;; > nil
;; => nil

;; run a bound f in a thread with a new binding
(binding [*some-var* "goodbye"]
  (.start (Thread. (bound-fn [] (f)))))
;; > goodbye
;; => nil

Uses on crossclj