;;;; -*- coding: utf-8; fill-column: 78 -*-
+changes relative to sbcl-1.1.13:
+ * enhancement: Top-level defmethod without defgeneric no longer causes
+ undefined-function warnings in subsequent forms. (lp#503095)
+
changes in sbcl-1.1.13 relative to sbcl-1.1.12:
* optimization: better distribution of SXHASH over small conses of related
values. (lp#309443)
from the same location. (patch by Douglas Katzman, lp#1042405)
* bug fix: Create vectors of proper internal length when reading literal
vectors from FASLs. (Reported by Jan Moringen)
- * bug fix: COMPILE can now succefully compile setf functions.
+ * bug fix: COMPILE can now successfully compile setf functions.
(Reported by Douglas Katzman)
* bug fix: run-program performs more correct escaping of arguments on
Windows. (lp#1239242)
(multiple-value-bind (qualifiers lambda-list body)
(parse-defmethod args)
`(progn
+ (eval-when (:compile-toplevel :load-toplevel :execute)
+ (compile-or-load-defgeneric ',name))
;; KLUDGE: this double expansion is quite a monumental
;; workaround: it comes about because of a fantastic interaction
;; between the processing rules of CLHS 3.2.3.1 and the
--- /dev/null
+(defmethod gf503095-2 ()
+ (gf503095-2))
+
+(defun f503095-2 ()
+ (gf503095-2))
--- /dev/null
+(defmethod gf503095 ()
+ (gf503095))
+
+(defun f503095 ()
+ (gf503095))
;; DEFMETHOD
(sb-cltl2:macroexpand-all '(defmethod x (a) (macro))))
+(with-test (:name (:defmethod-undefined-function :bug-503095))
+ (flet ((test-load (file)
+ (let (implicit-gf-warning)
+ (handler-bind
+ ((sb-ext:implicit-generic-function-warning
+ (lambda (x)
+ (setf implicit-gf-warning x)
+ (muffle-warning x)))
+ ((or warning error) #'error))
+ (load file))
+ (assert implicit-gf-warning))))
+ (multiple-value-bind (fasl warnings errorsp) (compile-file "bug-503095.lisp")
+ (unwind-protect
+ (progn (assert (and fasl (not warnings) (not errorsp)))
+ (test-load fasl))
+ (and fasl (delete-file fasl))))
+ (test-load "bug-503095-2.lisp")))
;;;; success