Hi,
On Feb 19, 6:16 pm, Michał Marczyk wrote:
> You missed a quote (~name# -> ~'name#); this works fine:
>
> (defmacro my-macro [& body]
> `(let [name# {#'*a* :new}]
> (macrolet [(~(symbol 'with-my-macrolet)
> [& body#]
>`(with-bindings ~'name#
>
You missed a quote (~name# -> ~'name#); this works fine:
(defmacro my-macro [& body]
`(let [name# {#'*a* :new}]
(macrolet [(~(symbol 'with-my-macrolet)
[& body#]
`(with-bindings ~'name#
~...@body#))]
~...@body))
Since
g-utils.clj#L92
All the best,
Tayssir
On Feb 19, 2:56 pm, Tayssir John Gabbour
wrote:
> Hi,
>
> I'm having problems with nested syntax-quotes, or something.
>
> This works fine:
> (use 'clojure.contrib.macro-utils)
> (def *a* nil)
>
> ;; good
> (de
Hi,
I'm having problems with nested syntax-quotes, or something.
This works fine:
(use 'clojure.contrib.macro-utils)
(def *a* nil)
;; good
(defmacro my-macro [& body]
`(let [name# {#'*a* :new}]
(macrolet [(~(symbol 'with-my-macrolet) [& body#]