X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tests%2Fclos.impure.lisp;h=56fb8c374a5370f9c7dcc4ce650799528535b67b;hb=0a15b6bbf9d5d3a64b5ac08bb96b6e5ec221d2ae;hp=e08f7a7b584227e4a6646712227bace3eefa84f2;hpb=ab7aedfb1e4c0245814beb998e74e099b71092a6;p=sbcl.git diff --git a/tests/clos.impure.lisp b/tests/clos.impure.lisp index e08f7a7..56fb8c3 100644 --- a/tests/clos.impure.lisp +++ b/tests/clos.impure.lisp @@ -1112,7 +1112,9 @@ (assert (= (method-on-defined-type-and-class 3) 4))))) ;; bug 281 -(let ((sb-pcl::*max-emf-precomputation-methods* 0)) +(let (#+nil ; no more sb-pcl::*max-emf-precomputation-methods* as of + ; sbcl-1.0.41.x + (sb-pcl::*max-emf-precomputation-methods* 0)) (eval '(defgeneric bug-281 (x) (:method-combination +) (:method ((x symbol)) 1) @@ -1862,4 +1864,28 @@ (cacheing-initargs-redefinitions-check-fun :slot2) (let ((thing (cacheing-initargs-redefinitions-check-fun :slot))) (assert (not (slot-boundp thing 'slot))))) + +(with-test (:name :defmethod-specializer-builtin-class-alias) + (let ((alias (gensym))) + (setf (find-class alias) (find-class 'symbol)) + (eval `(defmethod lp-618387 ((s ,alias)) + (symbol-name s))) + (assert (equal "FOO" (funcall 'lp-618387 :foo))))) + +(with-test (:name :pcl-spurious-ignore-warnings) + (defgeneric no-spurious-ignore-warnings (req &key key)) + (handler-bind ((warning (lambda (x) (error "~A" x)))) + (eval + '(defmethod no-spurious-ignore-warnings ((req number) &key key) + (declare (ignore key)) + (check-type req integer)))) + (defgeneric should-get-an-ignore-warning (req &key key)) + (let ((warnings 0)) + (handler-bind ((warning (lambda (c) (setq warnings 1) (muffle-warning c)))) + (eval '(defmethod should-get-an-ignore-warning ((req integer) &key key) + (check-type req integer)))) + (assert (= warnings 1)))) + + + ;;;; success