bbloom on irc suggested this: https://github.com/brandonbloom/backtick and looks like *template *is the macro I was looking for => (template {:a (+ 1 2) c d :b ~(+ 1 3)}) {:a (+ 1 2), :b 4, c d}
Totally awesome! On Tue, Feb 19, 2013 at 7:35 PM, AtKaaZ <atk...@gmail.com> wrote: > I am trying (but failing) to find a way to have a macro like: > => *(xmacro* {:a (+ 1 2) :b ~(+ 1 3)}) > {:a (clojure.core/+ 1 2), :b 4} > ;*without specifying the backquote ` on the input* > > I need it to behave like this: > => (*eval '`*{:a (+ 1 2) :b ~(+ 1 3)}) > {:a (clojure.core/+ 1 2), :b 4} > > But I don't get how I could do that, yet I feel I'm missing something > pretty basic. > > I've also made a gist for this: https://gist.github.com/AtKaaZ/4988320 > > But this is the best that I can do without errors: > > => (defmacro x [a] `~a ) > > => (*x `*{:a (+ 1 2) :b ~(+ 1 3)}) > {:a (clojure.core/+ 1 2), :b 4} > > But I don't want to have to specify the backquote ` in the > input to the macro, I need the macro to automatically add > that. > > Thank you for your help. > > > -- > Please correct me if I'm wrong or incomplete, > even if you think I'll subconsciously hate it. > > -- Please correct me if I'm wrong or incomplete, even if you think I'll subconsciously hate it. -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.