]> code.delx.au - gnu-emacs/blobdiff - lisp/emacs-lisp/eieio-base.el
Merge from origin/emacs-24
[gnu-emacs] / lisp / emacs-lisp / eieio-base.el
index feb06711cb30b5fd607ce55b0df39db8ca82bfd3..1cc9f895f8a8e92a14dc436ceacad819d20134f3 100644 (file)
@@ -140,7 +140,7 @@ Multiple calls to `make-instance' will return this object."))
 A singleton is a class which will only ever have one instance."
   :abstract t)
 
-(cl-defmethod eieio-constructor ((class (subclass eieio-singleton)) &rest _slots)
+(cl-defmethod make-instance ((class (subclass eieio-singleton)) &rest _slots)
   "Constructor for singleton CLASS.
 NAME and SLOTS initialize the new object.
 This constructor guarantees that no matter how many you request,
@@ -219,7 +219,7 @@ for CLASS.  Optional ALLOW-SUBCLASS says that it is ok for
 being pedantic."
   (unless class
     (message "Unsafe call to `eieio-persistent-read'."))
-  (when class (eieio--check-type class-p class))
+  (when class (cl-check-type class class))
   (let ((ret nil)
        (buffstr nil))
     (unwind-protect
@@ -290,8 +290,7 @@ constructor functions are considered valid.
 Second, any text properties will be stripped from strings."
   (cond ((consp proposed-value)
         ;; Lists with something in them need special treatment.
-        (let ((slot-idx (eieio--slot-name-index class
-                                                 nil slot))
+        (let ((slot-idx (eieio--slot-name-index class slot))
               (type nil)
               (classtype nil))
           (setq slot-idx (- slot-idx
@@ -481,7 +480,7 @@ instance."
 
 (cl-defmethod eieio-object-set-name-string ((obj eieio-named) name)
   "Set the string which is OBJ's NAME."
-  (eieio--check-type stringp name)
+  (cl-check-type name string)
   (eieio-oset obj 'object-name name))
 
 (cl-defmethod clone ((obj eieio-named) &rest params)