On Tuesday, 2 February 2016 04:32:57 UTC+2, Herwig Hochleitner wrote: > Well, for multi-arity, you'd have to parse the argument tuples. I mean, > `(print ~args) will almost work, since most destructurings can also be > evaluated and printed, but not so for seq destructurings a la (defprint x > [fst & nxt]), which will choke on the symbol '&, trying to evaluate (print > [fst & nxt]). > > > ~' circumvents namespace expansion in syntax-quote. `& will emit > current.ns/&, while `~'& will just emit &. Normally this should be avoided, > as it can capture variable names (hece the auto-gensym `args#), but for & > it's OK, because this is syntax for another macro, defn.
Thanks for the explanation about ~'. I discover that with & it works a differently: both ~'& and & emits & (both in clj and cljs) -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups "ClojureScript" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/clojurescript.
