| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
When tracing for two or more functions is enabled in a single
trace form, the the function tracing hooks print the wrong
name for all but the rightmost function.
* share/txr/stdlib/trace.tl (sys:trace): Fix code which
assumes that the each operator binds fresh lexical variables
on each iteration. Bind a fresh lexical variable lex-n which
copies the current value of the loop variable n, and refer
to this lexical out of the tracing lambda.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The tracing module should warn when traced functions or
methods are being redefined, and stop tracing the original
methods.
* eval.c (trace_check): New function. Calls
sys:trace-redefined-check if the trace module has been
loaded, otherwise does nothing.
(op_defun, op_defmacro): Call trace_check to have a warning
issued for a redefined traced function or macro.
* eval.h (trace_check): Declared.
* lisplib.c (trace_loaded): New global variable.
(trace_instantiate): Flip trace_loaded to t.
* lisplib.h (trace_loaded): Declared.
* share/txr/stdlib/trace.tl (sys:trace-redefine-check): New
function. Checks two situations: traced function or method
is redefined (neither old nor new is traced any longer),
and traced method is overridden (base method continues to be
traced, override is not traced).
* struct.c (static_slot_ensure): Do a trace check here,
taking care of defmeth.
|
|
|
|
|
|
|
|
|
|
|
|
| |
When a method is traced that is actually derived from
another struct type, we convert the (meth ...) name
to refer to that type and issue a warning.
* share/txr/stdlib/trace.tl (sys:trace-canonicalize-name): New
function.
(sys:trace): Canonicalize name, and trace the canonicalized
name. Warn if it is different from the original name.
(sys:untrace): Likewise for untracing.
|
|
|
|
|
|
|
|
|
| |
* share/txr/stdlib/trace.tl (sys:trace): If symbol-function
returns nil, throw exception.
* txr.1: Document the behavior, along with return values
of trace and untrace, and the tolerance of untrace to
bad arguments.
|
|
|
|
|
| |
* share/txr/stdlib/trace.tl (sys:*trace-hash*): Hash must be
equal-based to correctly support compound places.
|
|
New variable *trace-output*, and macros trace and untrace.
* lisplib.c (trace_set_entries, trace_instantiate): new static
functions.
(dlt_register): Register new functions to auto-load trace
module.
* share/txr/stdlib/trace.tl: New file.
* txr.1: Documented.
|