On Thu, Oct 18, 2012 at 2:07 PM, David Nolen <dnolen.li...@gmail.com> wrote:
> On Thu, Oct 18, 2012 at 3:06 PM, Grant Rettke <gret...@acm.org> wrote:
>>
>> (-> ((fn []
>>       (let [a 1]
>>         (println "this is a: " a)
>>         a)))
>>    ((fn [a]
>>       (let [b 2]
>>         (println "this is b: " b)
>>         (list a b))))
>>    ((fn [[a b]]
>>       (let [c 3]
>>         (println "this is c: " c)
>>         (println "Sum: " (+ a b c))))))
>
>
> Why should you have to change the shape of your program to insert some
> debugging statements?

Writing a macro like JvJ did or writing all of your code inside of a
let statement like you did is also changing the shape of your program
just to print debug statements isn't it?

Sorry the way I understood the use case that you need to do something,
anything, maybe some expensive, before doing the *next thing*, and
same goes before the *next thing*. I didn't read it as inserting debug
statements at all.

-- 
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

Reply via email to