PPRINT-INDENT should take reals, not just integers, as arguments.
... make it so.
... note a possible bug in the way it's been made so.
(aref (vector x) (incf i)))
(foo-x x))
=> error
+
+349: PPRINT-INDENT rounding implementation decisions
+ At present, pprint-indent (and indeed the whole pretty printer)
+ more-or-less assumes that it's using a monospace font. That's
+ probably not too silly an assumption, but one piece of information
+ the current implementation loses is from requests to indent by a
+ non-integral amount. As of sbcl-0.8.15.9, the system silently
+ truncates the indentation to an integer at the point of request, but
+ maybe the non-integral value should be propagated through the
+ pprinter and only truncated at output? (So that indenting by 1/2
+ then 3/2 would indent by two spaces, not one?)
* fixed some bugs revealed by Paul Dietz' test suite:
** POSITION on displaced vectors with non-zero displacement
returns the right answer.
- ** (SIMPLE-STRING) is a valid type specifier for sequence creators.
+ ** (SIMPLE-STRING) is a valid type specifier for sequence
+ creators.
+ ** *PRINT-LEVEL* handling for slotless structures is pedantically
+ correct.
+ ** PPRINT-INDENT accepts a request for an indentation of any REAL.
changes in sbcl-0.8.15 relative to sbcl-0.8.14:
* incompatible change: SB-INT:*BEFORE-SAVE-INITIALIZATIONS* and
#!+sb-doc
"Specify the indentation to use in the current logical block if STREAM
(which defaults to *STANDARD-OUTPUT*) is it is a pretty-printing stream
- and do nothing if not. (See PPRINT-LOGICAL-BLOCK.) N is the indention
+ and do nothing if not. (See PPRINT-LOGICAL-BLOCK.) N is the indentation
to use (in ems, the width of an ``m'') and RELATIVE-TO can be either:
:BLOCK - Indent relative to the column the current logical block
started on.
:CURRENT - Indent relative to the current column.
- The new indention value does not take effect until the following line
+ The new indentation value does not take effect until the following line
break."
(declare (type (member :block :current) relative-to)
- (type integer n)
+ (type real n)
(type (or stream (member t nil)) stream)
(values null))
(let ((stream (case stream
((nil) *standard-output*)
(t stream))))
(when (print-pretty-on-stream-p stream)
- (enqueue-indent stream relative-to n)))
+ (enqueue-indent stream relative-to (truncate n))))
nil)
(defun pprint-tab (kind colnum colinc &optional stream)
;;; checkins which aren't released. (And occasionally for internal
;;; versions, especially for internal versions off the main CVS
;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
-"0.8.15.8"
+"0.8.15.9"