Skip to content

Commit

Permalink
0.8.1.49:
Browse files Browse the repository at this point in the history
        * Fix bug 262: LOAD-DEFMETHOD-INTERNAL checks whether GF has
          any methods before calling FIND-METHOD;
        ... late condition slot installers do not overwrite GF lambda
        list.
  • Loading branch information
Alexey Dejneka committed Jul 20, 2003
1 parent 26341a4 commit 28b4b70
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 28 deletions.
34 changes: 9 additions & 25 deletions BUGS
Expand Up @@ -1067,31 +1067,6 @@ WORKAROUND:

Urgh... It's time to write IR1-copier.

262:
In 0.8.1.32:

* (ensure-generic-function 'foo)
#<STANDARD-GENERIC-FUNCTION FOO (0)>
* (defmethod foo (x) x)
debugger invoked on condition of type SIMPLE-ERROR:
The generic function #<STANDARD-GENERIC-FUNCTION FOO (0)> takes 0 required
arguments; was asked to find a method with specializers (#<BUILT-IN-CLASS T>)

AMOP seems to say that it should work (first ADD-METHOD initializes
GF lambda list).

264:
(reported by <dsk> on #lisp 2003-07-16)

(progv '(foo) '(1)
(eval '(symbol-macrolet ((foo 3))
(declare (special foo))
foo)))

does not signal an error.

(fixed in 0.8.1.37)

265:
SB-EXT:RUN-PROGRAM is currently non-functional on Linux/PPC;
attempting to use it leads to segmentation violations. This is
Expand All @@ -1117,6 +1092,15 @@ WORKAROUND:
is allowed to by CLHS 3.2.2.3. CMUCL, however, does perform this
optimization.

268: "wrong free declaration scope"
The following code must signal type error:

(locally (declare (optimize (safety 3)))
(flet ((foo (x &optional (y (car x)))
(declare (optimize (safety 0)))
(list x y)))
(funcall (eval #'foo) 1)))

DEFUNCT CATEGORIES OF BUGS
IR1-#:
These labels were used for bugs related to the old IR1 interpreter.
Expand Down
4 changes: 2 additions & 2 deletions src/code/late-condition.lisp
Expand Up @@ -15,11 +15,11 @@
(fmakunbound 'install-condition-slot-writer)
(defun install-condition-slot-reader (name condition slot-name)
(unless (fboundp name)
(ensure-generic-function name :lambda-list '(condition)))
(ensure-generic-function name))
(eval `(defmethod ,name ((.condition. ,condition))
(condition-reader-function .condition. ',slot-name))))
(defun install-condition-slot-writer (name condition slot-name)
(unless (fboundp name)
(ensure-generic-function name :lambda-list '(new-value condition)))
(ensure-generic-function name))
(eval `(defmethod ,name (new-value (.condition. ,condition))
(condition-writer-function .condition. new-value ',slot-name))))
1 change: 1 addition & 0 deletions src/pcl/boot.lisp
Expand Up @@ -1362,6 +1362,7 @@ bootstrapping.
(fboundp gf-spec))
(let* ((gf (fdefinition gf-spec))
(method (and (generic-function-p gf)
(generic-function-methods gf)
(find-method gf
qualifiers
(parse-specializers specializers)
Expand Down
7 changes: 7 additions & 0 deletions tests/clos.impure.lisp
Expand Up @@ -676,5 +676,12 @@
(let ((f (compile nil `(lambda () (make-instance ',class-name)))))
(assert (typep (funcall f) class-name))))

;;; bug 262: DEFMETHOD failed on a generic function without a lambda
;;; list
(ensure-generic-function 'bug262)
(defmethod bug262 (x y)
(list x y))
(assert (equal (bug262 1 2) '(1 2)))

;;;; success
(sb-ext:quit :unix-status 104)
2 changes: 1 addition & 1 deletion version.lisp-expr
Expand Up @@ -17,4 +17,4 @@
;;; 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.1.48"
"0.8.1.49"

0 comments on commit 28b4b70

Please sign in to comment.