On Sat, Jul 30, 2011 at 9:07 PM, Alan Malloy <a...@malloys.org> wrote: > (get :foo argmap__5673__auto 42) is the right way to solve this > problem.
Is another way to solve it, yes, and a good one. > Or if, as in the current example, you want to destructure a map with > lots of defaults, simply: > > (let [{:keys [foo bar] :or {foo 42}} (parse-whatever)] > ...body...) Or (let [{:keys [foo bar]} (merge {:foo 42} (parse-whatever))] ...body...) The defaults map can be a literal emitted by the macro and must be on the left of the map-returning (parse-whatever) call. -- Protege: What is this seething mass of parentheses?! Master: Your father's Lisp REPL. This is the language of a true hacker. Not as clumsy or random as C++; a language for a more civilized age. -- 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