** allow using the (declare (typespec var*)) abbreviation for
(declare (type typespec var*)) with all type specifiers
** circularity detection works properly with PPRINT-LOGICAL-BLOCK
+ ** always return NIL from PPRINT-POP when OBJECT is NIL
+ ** don't signal errors when pretty-printing malformed LABELS,
+ FLET or MACROLET forms
changes in sbcl-0.9.1 relative to sbcl-0.9.0:
* fixed cross-compiler leakages that prevented building a 32-bit
(output-object ,object-var ,stream-var)
(return-from ,block-name nil))))
(incf ,count-name)
- ,@(when object
- `((pop ,object-var)))))
+ ,@(if object
+ `((pop ,object-var))
+ `(nil))))
(declare (ignorable (function ,pp-pop-name)))
(locally
(declare (disable-package-locks
t))))))
(defmacro with-circularity-detection ((object stream) &body body)
- (let ((marker (gensym "WITH-CIRCULARITY-DETECTION-")))
- `(cond ((not *print-circle*)
- ,@body)
- (*circularity-hash-table*
- (let ((,marker (check-for-circularity ,object t :logical-block)))
- (if ,marker
- (when (handle-circularity ,marker ,stream)
- ,@body)
- ,@body)))
- (t
- (let ((*circularity-hash-table* (make-hash-table :test 'eq)))
- (output-object ,object (make-broadcast-stream))
- (let ((*circularity-counter* 0))
- (let ((,marker (check-for-circularity ,object t
- :logical-block)))
- (when ,marker
- (handle-circularity ,marker ,stream)))
- ,@body))))))
+ (let ((marker (gensym "WITH-CIRCULARITY-DETECTION-"))
+ (body-name (gensym "WITH-CIRCULARITY-DETECTION-BODY-")))
+ `(labels ((,body-name ()
+ ,@body))
+ (cond ((not *print-circle*)
+ (,body-name))
+ (*circularity-hash-table*
+ (let ((,marker (check-for-circularity ,object t :logical-block)))
+ (if ,marker
+ (when (handle-circularity ,marker ,stream)
+ (,body-name))
+ (,body-name))))
+ (t
+ (let ((*circularity-hash-table* (make-hash-table :test 'eq)))
+ (output-object ,object (make-broadcast-stream))
+ (let ((*circularity-counter* 0))
+ (let ((,marker (check-for-circularity ,object t
+ :logical-block)))
+ (when ,marker
+ (handle-circularity ,marker ,stream)))
+ (,body-name))))))))
(defun pprint-flet (stream list &rest noise)
(declare (ignore noise))
- (if (cddr list)
+ (if (and (consp list)
+ (consp (cdr list))
+ (cddr list))
(funcall (formatter
"~:<~^~W~^ ~@_~:<~@{~:<~^~W~^~3I ~:_~/SB!PRETTY:PPRINT-LAMBDA-LIST/~1I~:@_~@{~W~^ ~_~}~:>~^ ~_~}~:>~1I~@:_~@{~W~^ ~_~}~:>")
stream
#!+long-float (def-type-predicate-wrapper simple-array-long-float-p)
(def-type-predicate-wrapper simple-array-complex-single-float-p)
(def-type-predicate-wrapper simple-array-complex-double-float-p)
- #!+long-float (def-type-predicate-wrapper simple-array-complex-long-float-p))
+ #!+long-float (def-type-predicate-wrapper simple-array-complex-long-float-p)
+ (def-type-predicate-wrapper vector-nil-p))
\f
;;; Return the specifier for the type of object. This is not simply
;;; (TYPE-SPECIFIER (CTYPE-OF OBJECT)) because CTYPE-OF has different
`(integer 0 (,char-code-limit)))
(defvar *character-database*)
-(declaim (type (vector (unsigned-byte 8)) *character-database*))
+(declaim (type (simple-array (unsigned-byte 8) (*)) *character-database*))
(macrolet ((frob ()
(with-open-file (stream (merge-pathnames
;;; 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.9.1.27"
+"0.9.1.28"