Artifact 1a2d23ccdd0d3a64d720d7ca8bb5b2d6a04bd03580a2bfe20fb7089326de1cf9:
- Executable file
r37/lisp/csl/html/r37_0223.html
— part of check-in
[f2fda60abd]
at
2011-09-02 18:13:33
on branch master
— Some historical releases purely for archival purposes
git-svn-id: https://svn.code.sf.net/p/reduce-algebra/code/trunk/historical@1375 2bfe0521-f11c-4a00-b80e-6202646ff360 (user: arthurcnorman@users.sourceforge.net, size: 1796) [annotate] [blame] [check-ins using] [more...]
<A NAME=TR> <TITLE>TR</TITLE></A> <b><a href=r37_idx.html>INDEX</a></b><p><p> <B>TR</B> _ _ _ _ _ _ _ _ _ _ _ _ <B>declaration</B><P> <P> <P> <P> The <em>tr</em> declaration is used to trace system or user-written procedures. It is only useful to those with a good knowledge of both Lisp and the internal formats used by REDUCE. <P> <P> <P> <H3> syntax: </H3> <em>tr</em><name>{,<name>}* <P> <P> <P> <name> is the name of a REDUCE system procedure or one of your own procedures. <P> <P> <P> <H3> examples: </H3> <P><PRE><TT></TT></PRE><P>The system procedure <em>prepsq</em> is traced, which prepares REDUCE standard forms for printing by converting them to a Lisp prefix form.<P><PRE><TT> tr prepsq; (PREPSQ) x**2 + y; PREPSQ entry: Arg 1: (((((X . 2) . 1) ((Y . 1) . 1)) . 1) PREPSQ return value = (PLUS (EXPT X 2) Y) PREPSQ entry: Arg 1: (1 . 1) PREPSQ return value = 1 2 X + Y untr prepsq; (PREPSQ) </TT></PRE><P> <P> <P> This example is for a PSL-based system; the above format will vary if other Lisp systems are used. <P> <P> When a procedure is traced, the first lines show entry to the procedure and the arguments it is given. The value returned by the procedure is printed upon exit. If you are tracing several procedures, with a call to one of them inside the other, the inner trace will be indented showing procedure nesting. There are no trace options. However, the format of the trace depends on the underlying Lisp system used. The trace can be removed with the command <A HREF=r37_0224.html>untr</A>. Note that <em>trace</em>, below, is a matrix operator, while <em>tr</em> does procedure tracing. <P> <P> <P>