macro | since v0.0-2156 | Edit |
(specify! expr & impls)
Identical to reify but mutates its first argument.
(core/defmacro specify!
[expr & impls]
(core/let [x (with-meta (gensym "x") {:extend :instance})]
`(let [~x ~expr]
(extend-type ~x ~@impls)
~x)))