Next: , Previous: Repl, Up: Session Support

7.5.2 Quick Print

(require 'qp) When displaying error messages and warnings, it is paramount that the output generated for circular lists and large data structures be limited. This section supplies a procedure to do this. It could be much improved.

Notice that the neccessity for truncating output eliminates Common-Lisp's Format from consideration; even when variables *print-level* and *print-level* are set, huge strings and bit-vectors are not limited.
— Procedure: qp arg1 ...
— Procedure: qpn arg1 ...
— Procedure: qpr arg1 ...

qp writes its arguments, separated by spaces, to (current-output-port). qp compresses printing by substituting ‘...’ for substructure it does not have sufficient room to print. qpn is like qp but outputs a newline before returning. qpr is like qpn except that it returns its last argument.

— Variable: *qp-width*

*qp-width* is the largest number of characters that qp should use. If *qp-width* is #f, then all items will be writen. If *qp-width* is 0, then all items except procedures will be writen; procedures will be indicated by ‘#[proc]’.