+changes in sbcl-0.9.2 relative to sbcl-0.9.1:
+ * fixed some bugs revealed by Paul Dietz' test suite:
+ ** Invalid dotted lists no longer raise a read error when
+ *READ-SUPPRESS* is T
+
changes in sbcl-0.9.1 relative to sbcl-0.9.0:
* fixed cross-compiler leakages that prevented building a 32-bit
target with a 64-bit host compiler.
(defun legal-fun-name-p (name)
(values (valid-function-name-p name)))
+(deftype function-name () '(satisfies legal-fun-name-p))
+
;;; Signal an error unless NAME is a legal function name.
(defun legal-fun-name-or-type-error (name)
(unless (legal-fun-name-p name)
(error 'simple-type-error
:datum name
- :expected-type '(or symbol (cons (member setf) (cons symbol null)))
+ :expected-type 'function-name
:format-control "invalid function name: ~S"
:format-arguments (list name))))
(let ((nextchar (read-char stream t)))
(cond ((token-delimiterp nextchar)
(cond ((eq listtail thelist)
- (%reader-error
- stream
- "Nothing appears before . in list."))
+ (unless *read-suppress*
+ (%reader-error
+ stream
+ "Nothing appears before . in list.")))
((whitespacep nextchar)
(setq nextchar (flush-whitespace stream))))
(rplacd listtail
(let ((lastobj ()))
(do ((char firstchar (flush-whitespace stream)))
((char= char #\) )
- (%reader-error stream "Nothing appears after . in list."))
+ (if *read-suppress*
+ (return-from read-after-dot nil)
+ (%reader-error stream "Nothing appears after . in list.")))
;; See whether there's something there.
(setq lastobj (read-maybe-nothing stream char))
(when lastobj (return t)))
(flush-whitespace stream)))
((char= lastchar #\) ) lastobj) ;success!
;; Try reading virtual whitespace.
- (if (read-maybe-nothing stream lastchar)
+ (if (and (read-maybe-nothing stream lastchar)
+ (not *read-suppress*))
(%reader-error stream "More than one object follows . in list.")))))
(defun read-string (stream closech)
(defun sharp-left-paren (stream ignore length)
(declare (ignore ignore) (special *backquote-count*))
(let* ((list (read-list stream nil))
- (listlength (length list)))
+ (listlength (handler-case (length list)
+ (type-error
+ (error)
+ (declare (ignore error))
+ (%reader-error stream "improper list in #(): ~S"
+ list)))))
(declare (list list)
(fixnum listlength))
(cond (*read-suppress* nil)
;;; 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"
+"0.9.1.1"