0.7.12.13:
authorChristophe Rhodes <csr21@cam.ac.uk>
Fri, 31 Jan 2003 09:28:35 +0000 (09:28 +0000)
committerChristophe Rhodes <csr21@cam.ac.uk>
Fri, 31 Jan 2003 09:28:35 +0000 (09:28 +0000)
Fix (DEFCLASS #:FOO () ())
... relax restriction on function names, allowing lists of
length two headed by SB!PCL::CLASS-PREDICATE
... OA(more-or-less)OOify function name logic

NEWS
src/code/early-extensions.lisp
src/compiler/info-functions.lisp
src/compiler/ir1-translators.lisp
src/pcl/defs.lisp
tests/clos.impure.lisp
version.lisp-expr

diff --git a/NEWS b/NEWS
index 1fbab30..1c984cb 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1516,6 +1516,10 @@ changes in sbcl-0.7.13 relative to sbcl-0.7.12:
     COMPILE or FUNCTION.
   * fixed a bug in DEFSTRUCT: predicates for :NAMED structures with
     :TYPE will no longer signal errors on innocuous objects.
+  * fixed bug 231b: SETQ is better at respecting type declarations in
+    the lexical environment.
+  * fixed a bug in DEFCLASS: classes named by symbols with no or
+    unprintable packages can now be defined.
   * fixed some bugs revealed by Paul Dietz' test suite:
     ** ARRAY-IN-BOUNDS-P now allows arbitrary integers as arguments,
        not just nonnegative fixnums;
index a3c401c..c342e86 100644 (file)
 (defun legal-fun-name-p (name)
   (or (symbolp name)
       (and (consp name)
-           (eq (car name) 'setf)
+           (or (eq (car name) 'setf)
+              (eq (car name) 'sb!pcl::class-predicate))
            (consp (cdr name))
            (symbolp (cadr name))
            (null (cddr name)))))
index 18ff9b5..8d51a97 100644 (file)
@@ -26,9 +26,7 @@
 (defun check-fun-name (name)
   (typecase name
     (list
-     (unless (and (consp name) (consp (cdr name))
-                 (null (cddr name)) (eq (car name) 'setf)
-                 (symbolp (cadr name)))
+     (unless (legal-fun-name-p name)
        (compiler-error "illegal function name: ~S" name)))
     (symbol
      (when (eq (info :function :kind name) :special-form)
index 30e27c8..4c5a861 100644 (file)
                          thing
                          :debug-name (debug-namify "#'~S" thing)
                          :allow-debug-catch-tag t)))
-       ((setf)
+       ((setf sb!pcl::class-predicate)
         (let ((var (find-lexically-apparent-fun
                     thing "as the argument to FUNCTION")))
           (reference-leaf start cont var)))
index 02f7edc..322563d 100644 (file)
 (defvar *standard-method-combination*)
 \f
 (defun make-class-predicate-name (name)
-  (intern (format nil "~A::~A class predicate"
-                 (package-name (symbol-package name))
-                 name)
-         *pcl-package*))
-
+  (list 'class-predicate name))
+  
 (defun plist-value (object name)
   (getf (object-plist object) name))
 
index 41b2049..e3efc72 100644 (file)
 (bug234-b)
 (assert (= *bug234-b* 1))
 \f
+;;; we should be able to make classes with uninterned names:
+(defclass #:class-with-uninterned-name () ())
+\f
 ;;;; success
 (sb-ext:quit :unix-status 104)
index 9acf614..145255d 100644 (file)
@@ -18,4 +18,4 @@
 ;;; versions, especially for internal versions off the main CVS
 ;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
 
-"0.7.12.12"
+"0.7.12.13"