Arc Forumnew | comments | leaders | submitlogin
1 point by akkartik 5345 days ago | link | parent

Thanks, that was exactly what I wanted.

I could swear I tried ,', .. :/

I successfully applied your thinking to make args a gensym:

  (mac macro-alias(a b)
    (w/uniq args
      `(mac ,a ,args
         `(,',b ,@,args))))
This works like alias at http://arclanguage.org/item?id=13097 for macros. (It would also works on functions, but macro-aliases of functions are not first-class functions.)


1 point by akkartik 5344 days ago | link

My lesson from this experience: quote and unquote are not exact opposites.

  > (define a 3)
  > `(list ',a)
  '(list '3)
  > `(list ,'a)
  '(list a)

-----