What are the equivalents in Guile Scheme of the (trace procedure)
and (trace-let (bindings) body)
tracing facilities from Chez Scheme.
I've reviewed the documentation at https://www.gnu.org/software/guile/manual/html_node/Tracing-Traps.html, but I cannot figure out how to use the Guile tracing procedures from the source code file, not from the Guile REPL which may be done with ,trace (procedure application)
given previously imported module (use-modules (system vm trace))
.
I'm interested in tracing from the source code the application of recursive procedures similar to (trace fact1)
with the below output to the console
trace: (fact1 4)
trace: | (fact1 3)
trace: | | (fact1 2)
trace: | | | (fact1 1)
trace: | | | | (fact1 0)
trace: | | | | 1
trace: | | | 1
trace: | | 2
trace: | 6
trace: 24
Could the named let (let name (bindings) body)
syntactic extension be traced in Guile? The need for this arises when investigating tail recursive implementations of procedures.
Thank you very much!