Re: Macro Implementation: I Don't Understand This Error Message

2010-10-03 Thread Eivind Magnus Hvidevold
I'm not sure where I picked it up, but I remembered the arguments being called form and env, and googling for clojure form env led me to: http://groups.google.com/group/clojure/browse_thread/thread/d710c290b67951a3/b827d46389110f26?lnk=gstq=clojure+macro+%26env#b827d46389110f26 : form contains

Re: Macro Implementation: I Don't Understand This Error Message

2010-10-02 Thread Stefan Rohlfing
@Jürgen and Chris Thank you very much for helping me enlarge my understanding of macros! I realize that learning the subtleties of a macro implementation is not easy but well worth the effort. It is also quite interesting that a macro as it seems takes two implicit extra arguments. I am curious

Macro Implementation: I Don't Understand This Error Message

2010-10-01 Thread Stefan Rohlfing
Dear Clojure Group, I wanted to expand the 'infix' macro presented in chapter 7.3.1 of 'Clojure in Action' to handle nested s-expressions: My first version did not work: (defmacro my-infix [expr] (if (coll? expr) (let [ [left op right] expr] (list op (my-infix left) (my-infix

Re: Macro Implementation: I Don't Understand This Error Message

2010-10-01 Thread Jürgen Hötzel
2010/10/1 Stefan Rohlfing stefan.rohlf...@gmail.com: Dear Clojure Group, I wanted to expand the 'infix' macro presented in chapter 7.3.1 of 'Clojure in Action' to handle nested s-expressions: My first version did not work: (defmacro my-infix [expr]  (if (coll? expr)    (let [ [left op

Re: Macro Implementation: I Don't Understand This Error Message

2010-10-01 Thread Chris Perkins
On Oct 1, 3:59 am, Stefan Rohlfing stefan.rohlf...@gmail.com wrote: I wanted to expand the 'infix' macro presented in chapter 7.3.1 of 'Clojure in Action' to handle nested s-expressions: My first version did not work: (defmacro my-infix [expr]   (if (coll? expr)     (let [ [left op right]