tags 27718 + patch quit npostavs@users.sourceforge.net writes: > ~/src/emacs$ .../emacs -Q -batch -f batch-byte-compile cl-typep-subclass.el > ~/src/emacs$ .../emacs -Q -batch -l cl-typep-subclass.el > (cl-typep eitest-ab ’class-a) => t > ~/src/emacs$ .../emacs -Q -batch -l cl-typep-subclass.elc > (cl-typep eitest-ab ’class-a) => nil lisp/emacs-lisp/eieio.el:260: (defmacro defclass (name superclasses slots &rest options-and-doc) ... ;; When using typep, (typep OBJ 'myclass) returns t for objects which ;; are subclasses of myclass. For our predicates, however, it is ;; important for EIEIO to be backwards compatible, where ;; myobject-p, and myobject-child-p are different. ;; "cl" uses this technique to specify symbols with specific typep ;; test, so we can let typep have the CLOS documented behavior ;; while keeping our above predicate clean. (put ',name 'cl-deftype-satisfies #',testsym2) The problem is that the `put' doesn't take effect until runtime, so the compiler inlines `cl-typep' incorrectly. Using `function-put' here (and `function-get' in `cl-typep') solves it (requires also the patches for #27016[1]), although it seems a bit coincidental that `class-a' happens to be a function as well, so I'm not sure if this is the right thing. Stefan, any thoughts?