Is pound-quote (hash-quote, #') in Clojure running the resolve and symbol functions?

后端 未结 2 614
青春惊慌失措
青春惊慌失措 2020-12-31 04:21

Perhaps you can help me find this in the docs. I\'m using pound-quote to be able to pass around unevaluated function names prior to execution. For example:

(         


        
2条回答
  •  长情又很酷
    2020-12-31 04:34

    #' is the reader macro for var. See http://clojure.org/special_forms#var and http://clojure.org/vars

    (var foo) returns the var named by the symbol foo, which can hold any kind of value, including functions.

提交回复
热议问题