projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
759d114
)
* lisp/emacs-lisp/eieio.el (defclass): Fix bug#51068
author
Stefan Monnier
<monnier@iro.umontreal.ca>
Fri, 23 Sep 2022 21:42:55 +0000
(17:42 -0400)
committer
Stefan Monnier
<monnier@iro.umontreal.ca>
Fri, 23 Sep 2022 21:42:55 +0000
(17:42 -0400)
Accept (defclass <class> <superclasses> (.. <slotname> ..)) without
having to wrap the slot name within parentheses.
lisp/emacs-lisp/eieio.el
patch
|
blob
|
history
diff --git
a/lisp/emacs-lisp/eieio.el
b/lisp/emacs-lisp/eieio.el
index 984166b593aea1d97c97e1741806db95bcbffdc5..a6c900a3355c3c6dd6b45812ba246a47569041ee 100644
(file)
--- a/
lisp/emacs-lisp/eieio.el
+++ b/
lisp/emacs-lisp/eieio.el
@@
-136,6
+136,7
@@
and reference them using the function `class-option'."
(accessors ()))
;; Collect the accessors we need to define.
+ (setq slots (mapcar (lambda (x) (if (consp x) x (list x))) slots))
(pcase-dolist (`(,sname . ,soptions) slots)
(let* ((acces (plist-get soptions :accessor))
(initarg (plist-get soptions :initarg))