Hi Ken, On 29 Jul 2011, at 22:02, Ken Wesson wrote: >> P.S. Thanks everyone for your help so far. My brain is overheating but I am >> learning a lot. > > You're welcome. > > To do what you're proposing you will probably need the emitted > function to look like: > > (fn [& args] > (let [foo (some logic goes here) > bar (some logic goes here) > ...] > (body goes here))) > > where the first logic checks the args for containing the value for > foo, if it does evaluates to that value, and if not evaluates to foo's > default; the second does likewise for bar; and so on.
I just finished implementing a solution and it looks exactly like this. You're absolutely right - this is precisely the pattern I was looking for. What I didn't do, and I think the biggest lesson I've learned from these early macro-fighting days, is to do exactly what you propose: sketch out what the macro should expand to *before* working on the macro itself. Thanks everyone once again, Sam --- http://sam.aaron.name -- 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