Elisp macro tests
public text v1 · immutable(defun foo (n)
"Evaluates to n copies of the string 'foo', concatenated"
(let ((result))
(dotimes (i n)
(setq result (concat result "foo")))
result))
(defmacro this-macro-will-fail (arg)
(list (foo arg)))
(defmacro this-macro-will-work (arg)
`(foo ,arg))
(this-macro-will-fail 3)
(this-macro-will-work 3)