Q: are there breaking changes to eieio
in Emacs 27?
I just upgraded to the Emacs 27 snapshot, and I'm getting a peculiar break in code that works in previous versions of Emacs.
walkthrough
Here's a toy class and a toy :after
method:
(defclass simple-class ()
((value
:initarg :value
:initform nil
:documentation "Test slot"))
"Test class.")
This works:
(simple-class :value "some value") ;; ==> #s(simple-class "some value")
Now I'd like to define an :after
method on initialize-instance
:
(cl-defmethod initialize-instance :after ((sc simple-class) &key)
(with-slots (value) sc
(setf value (upcase value))))
Now it's broken:
(simple-class :value "some value") ;; ==> (error "Keyword argument nil not one of nil")
NB: it's nothing about the content of the :after
method: I can
define an empty method and I get the same error.
(cl-defmethod initialize-instance :after ((sc simple-class) &key))
what happened?
So: have there been changes to eieio
(specifically,
cl-defmethod
) in Emacs 27 that break previous code? Or is there
something bizarre about the snapshot?