With current trace:

[0] (my-length #<unspecified>)
[0] my-length -> (escaping)

With patch applied trace gives:

[0] (my-length #<unspecified>)", Called from: ""#(dashboard.scm:1099:
my-length #f #f)"
[0] my-length -> (escaping)

I then know exactly where my bug lies.

The patch:

diff -Naur trace/trace.scm trace-tweaked/trace.scm
--- trace/trace.scm    2016-07-02 16:35:15.626457742 -0700
+++ trace-tweaked/trace.scm    2016-07-02 16:34:25.690456156 -0700
@@ -61,6 +61,8 @@
     (trace-indent)
     (set! *trace-indent-level* (fx+ 1 *trace-indent-level*))
     (write (cons name args) port)
+    (write ", Called from: " port)
+    (write (conc (car (reverse (get-call-chain)))))
     (write-char #\newline port)
     (flush-output port) ) )

Alternatively I suppose I could create a new egg but that seems overkill.
It has become tiresome to maintain the patch myself.
_______________________________________________
Chicken-users mailing list
Chicken-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-users

Reply via email to