From: Stefan Monnier Date: Thu, 7 Mar 2024 20:26:12 +0000 (-0500) Subject: * lisp/emacs-lisp/oclosure.el (oclosure): Make it a subtype of `function` X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=6466ffe00659114e03c5fc7b0055663ccf3642f3;p=emacs.git * lisp/emacs-lisp/oclosure.el (oclosure): Make it a subtype of `function` (cherry picked from commit 76e9c761a45e0157a8ca43eaaf928385d8e0c228) --- diff --git a/lisp/emacs-lisp/oclosure.el b/lisp/emacs-lisp/oclosure.el index 26cd8594dfc..977d5735171 100644 --- a/lisp/emacs-lisp/oclosure.el +++ b/lisp/emacs-lisp/oclosure.el @@ -139,12 +139,15 @@ (:include cl--class) (:copier nil)) "Metaclass for OClosure classes." + ;; The `allparents' slot is used for the predicate that checks if a given + ;; object is an OClosure of a particular type. (allparents nil :read-only t :type (list-of symbol))) (setf (cl--find-class 'oclosure) (oclosure--class-make 'oclosure - "The root parent of all OClosure classes" - nil nil '(oclosure))) + "The root parent of all OClosure types" + nil (list (cl--find-class 'function)) + '(oclosure))) (defun oclosure--p (oclosure) (not (not (oclosure-type oclosure))))