Re: Really loving Clooj but..

2012-01-04 Thread Arthur Edelstein
Hi Erlis, Just to confirm: there currently aren't any built-in tracing or other special debugging capabilities in clooj. tools.trace is quite cool, though. Arthur -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to

Re: Really loving Clooj but..

2011-12-31 Thread Sean Corfield
On Sat, Dec 31, 2011 at 6:43 AM, jweiss wrote: > I use a modified version of tools.trace (or rather the old version > called clojure.contrib.trace, but works with 1.3), you might be > interested in some of the additions (sorry not well doc'd at the > moment): Those look like nice additions. Perha

Re: Really loving Clooj but..

2011-12-31 Thread jweiss
I use a modified version of tools.trace (or rather the old version called clojure.contrib.trace, but works with 1.3), you might be interested in some of the additions (sorry not well doc'd at the moment): 1) Don't blow up if a function throws an exception (return value shown in the trace will be t

Re: Really loving Clooj but..

2011-12-30 Thread Erlis Vidal
Hi Jonas, That's what I was looking for. Thanks for your reply On Fri, Dec 30, 2011 at 8:16 AM, Jonas wrote: > You should take a look at tools.trace [1]. A minimal example: > > (ns trc.core > (:use [clojure.tools.trace :only [deftrace]])) > > (deftrace fib [n] > (if (or (=

Re: Really loving Clooj but..

2011-12-30 Thread Jonas
You should take a look at tools.trace [1]. A minimal example: (ns trc.core (:use [clojure.tools.trace :only [deftrace]])) (deftrace fib [n] (if (or (= n 0) (= n 1)) 1 (+ (fib (- n 1)) (fib (- n 2) the following is printed when (fib 4) is evaluated: TRACE t

Re: Really loving Clooj but..

2011-12-30 Thread Erlis Vidal
Hi Cedric, I'm glad to know there's no such need for debugging. Maybe it's a need for me right now due to my level, but the more I work with the language, the more I'll learn. On top of that the community helps a lot, thanks to all of you for that. I've been in a lot of places, and I can tell that

Re: Really loving Clooj but..

2011-12-29 Thread Cedric Greevey
On Thu, Dec 29, 2011 at 10:50 PM, Erlis Vidal wrote: > Cedric, you have a really good point, I just realized it after reading your > email. After sending the original email I saw what the error was, but what I > still unable to know is how could I debug from Clooj, other than using > println, any

Re: Really loving Clooj but..

2011-12-29 Thread Erlis Vidal
Guys, Thanks so much for all the answers, thanks for taking the time to give me so many hints even when my email shows my Clojure ignorance. Cedric, you have a really good point, I just realized it after reading your email. After sending the original email I saw what the error was, but what I sti

Re: Really loving Clooj but..

2011-12-29 Thread Cedric Greevey
On Thu, Dec 29, 2011 at 6:23 PM, Mark Engelberg wrote: > I'd also like to know whether Clooj has any debug or stacktracing > capabilities.  Also, can the Clooj repl control the print level of > infinite lazy structures? (set! *print-length* 20) (set! *print-level* 20) (.printStackTrace *e) Hav

Re: Really loving Clooj but..

2011-12-29 Thread Mark Engelberg
I'd also like to know whether Clooj has any debug or stacktracing capabilities. Also, can the Clooj repl control the print level of infinite lazy structures? Thanks, Mark -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send e

Re: Really loving Clooj but..

2011-12-29 Thread Hubert Iwaniuk
Just add (println min) before if-let and you will see what is happening. Hubert. On Thu, Dec 29, 2011 at 10:23 PM, Erlis Vidal wrote: > Hi guys, > > I've using Clooj and following the labrepl but I'm hitting a wall right now. > How can I debug here? > > This the code I want to debug > > (defn mi

Re: Really loving Clooj but..

2011-12-29 Thread Laurent PETIT
2011/12/29 Erlis Vidal > Hi guys, > > I've using Clooj and following the labrepl but I'm hitting a wall right > now. How can I debug here? > > This the code I want to debug > > (defn min-1 [x & more] > (loop [min x > more (seq more)] > (if-let [x (first more)] > (recur (if (<

Re: Really loving Clooj but..

2011-12-29 Thread Bronsa
you are invoking the function in the wrong way what you really want to do is this: user> (min-1 2 1 3) 1 2011/12/29 Erlis Vidal > Hi guys, > > I've using Clooj and following the labrepl but I'm hitting a wall right > now. How can I debug here? > > This the code I want to debug > > (defn min-1

Really loving Clooj but..

2011-12-29 Thread Erlis Vidal
Hi guys, I've using Clooj and following the labrepl but I'm hitting a wall right now. How can I debug here? This the code I want to debug (defn min-1 [x & more] (loop [min x more (seq more)] (if-let [x (first more)] (recur (if (< x min) x min) (next more)) min))) This