Created
August 5, 2013 19:51
-
-
Save gtrak/6158977 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; nREPL 0.1.7 | |
user> (defmacro my-macro [name params] `(defn ~name ~params (prn 1))) | |
#'user/my-macro | |
user> (my-macro a [b c d]) | |
#'user/a | |
user> (a) | |
ArityException Wrong number of args (0) passed to: user$a clojure.lang.AFn.throwArity (AFn.java:437) | |
user> (a 1 2 3) | |
1 | |
nil | |
user> (my-macro a [a b c]) | |
#'user/a | |
user> (a 1 2 3) | |
1 | |
nil | |
user> (my-macro f [f b c]) | |
#'user/f | |
user> (f 1 2 3) | |
1 | |
nil | |
user> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment