From 85bc4001453f09c80c4b9662dd5cf23f0b1fbaed Mon Sep 17 00:00:00 2001 From: William Harold Newman Date: Mon, 21 Jan 2002 16:36:32 +0000 Subject: [PATCH] 0.7.0.3: APD "some simple patches" (sbcl-devel 2002-01-21) for bugs found by PVE --- src/code/array.lisp | 2 +- src/code/class.lisp | 6 +++--- src/code/numbers.lisp | 2 +- src/code/toplevel.lisp | 10 ++++++---- src/compiler/target-main.lisp | 3 ++- version.lisp-expr | 2 +- 6 files changed, 14 insertions(+), 11 deletions(-) diff --git a/src/code/array.lisp b/src/code/array.lisp index dbbfbee..64ef331 100644 --- a/src/code/array.lisp +++ b/src/code/array.lisp @@ -539,7 +539,7 @@ (declare (ignore start end)) (array-element-type array))) (t - (error "~S is not an array." array)))))) + (error 'type-error :datum array :expected-type 'array)))))) (defun array-rank (array) #!+sb-doc diff --git a/src/code/class.lisp b/src/code/class.lisp index a367c73..20bfe11 100644 --- a/src/code/class.lisp +++ b/src/code/class.lisp @@ -1130,10 +1130,10 @@ generic-sequence collection)) (null :translation (member nil) - :inherits (list sequence + :inherits (symbol list sequence mutable-sequence mutable-collection - generic-sequence collection symbol) - :direct-superclasses (list symbol)) + generic-sequence collection) + :direct-superclasses (symbol list)) (generic-number :state :read-only) (number :translation number :inherits (generic-number)) (complex diff --git a/src/code/numbers.lisp b/src/code/numbers.lisp index f663791..9eb5d54 100644 --- a/src/code/numbers.lisp +++ b/src/code/numbers.lisp @@ -1214,7 +1214,7 @@ (13 (boole 13 integer1 integer2)) (14 (boole 14 integer1 integer2)) (15 (boole 15 integer1 integer2)) - (t (error "~S is not of type (mod 16)." op)))) + (t (error 'type-error :datum op :expected-type '(mod 16))))) ;;;; GCD and LCM diff --git a/src/code/toplevel.lisp b/src/code/toplevel.lisp index 8c36aad..d2b9249 100644 --- a/src/code/toplevel.lisp +++ b/src/code/toplevel.lisp @@ -140,15 +140,17 @@ be any non-negative, non-complex number." (when (or (not (realp n)) (minusp n)) - (error "Invalid argument to SLEEP: ~S.~%~ - Must be a non-negative, non-complex number." - n)) + (error 'simple-type-error + :format-control "invalid argument to SLEEP: ~S" + :format-arguments (list n) + :datum n + :expected-type '(real 0))) (multiple-value-bind (sec usec) (if (integerp n) (values n 0) (multiple-value-bind (sec frac) (truncate n) - (values sec(truncate frac 1e-6)))) + (values sec (truncate frac 1e-6)))) (sb!unix:unix-select 0 0 0 0 sec usec)) nil) diff --git a/src/compiler/target-main.lisp b/src/compiler/target-main.lisp index c650cbf..b1c0230 100644 --- a/src/compiler/target-main.lisp +++ b/src/compiler/target-main.lisp @@ -89,7 +89,8 @@ (values definition nil nil) (actually-compile name definition)) (cond (name - (if (macro-function name) + (if (and (symbolp name) + (macro-function name)) (setf (macro-function name) compiled-definition) (setf (fdefinition name) compiled-definition)) (values name warnings-p failure-p)) diff --git a/version.lisp-expr b/version.lisp-expr index 3891ef4..3218fda 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -18,4 +18,4 @@ ;;; for internal versions, especially for internal versions off the ;;; main CVS branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".) -"0.7.0.2" +"0.7.0.3" -- 1.7.10.4