X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fcode%2Fpprint.lisp;h=89bac81df5bb0bf9ca0566e13cf6f9cb2536ad7f;hb=67f787e86602efc7e4007fb6bbc970a2fcf613f5;hp=5f9e6a4e8d06ca17fbeca3e2da17040b76af862a;hpb=b841c32badc4627f390cc8ab71b17bc158e7c6b1;p=sbcl.git diff --git a/src/code/pprint.lisp b/src/code/pprint.lisp index 5f9e6a4..89bac81 100644 --- a/src/code/pprint.lisp +++ b/src/code/pprint.lisp @@ -1315,8 +1315,13 @@ line break." ;;; OUTPUT-PRETTY-OBJECT is called by OUTPUT-OBJECT when ;;; *PRINT-PRETTY* is true. (defun output-pretty-object (object stream) - (with-pretty-stream (stream) - (funcall (pprint-dispatch object) stream object))) + (multiple-value-bind (fun pretty) (pprint-dispatch object) + (if pretty + (with-pretty-stream (stream) + (funcall fun stream object)) + ;; No point in consing up a pretty stream if we are not using pretty + ;; printing the object after all. + (output-ugly-object object stream)))) (defun !pprint-cold-init () (/show0 "entering !PPRINT-COLD-INIT")