diff options
| author | Lars Ingebrigtsen | 2019-06-17 15:46:09 +0200 |
|---|---|---|
| committer | Lars Ingebrigtsen | 2019-06-17 15:46:09 +0200 |
| commit | 1250a24f8ec2338d742d89bcaf83601496cee72a (patch) | |
| tree | f31463bc68b46580d6a17606c4c0f3ebb5faa223 | |
| parent | a07c647a2a0426e3e7380d279f4d469fcd3e913c (diff) | |
| download | emacs-1250a24f8ec2338d742d89bcaf83601496cee72a.tar.gz emacs-1250a24f8ec2338d742d89bcaf83601496cee72a.zip | |
New function eieio-declare-slots
* lisp/emacs-lisp/eieio-core.el (eieio-declare-slots): New
function to suppress compiler warnings about unknown slots.
| -rw-r--r-- | lisp/emacs-lisp/eieio-core.el | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lisp/emacs-lisp/eieio-core.el b/lisp/emacs-lisp/eieio-core.el index 01a821ed2a1..b6acab2a25a 100644 --- a/lisp/emacs-lisp/eieio-core.el +++ b/lisp/emacs-lisp/eieio-core.el | |||
| @@ -1085,6 +1085,10 @@ method invocation orders of the involved classes." | |||
| 1085 | These match if the argument is the name of a subclass of CLASS." | 1085 | These match if the argument is the name of a subclass of CLASS." |
| 1086 | (list eieio--generic-subclass-generalizer)) | 1086 | (list eieio--generic-subclass-generalizer)) |
| 1087 | 1087 | ||
| 1088 | (defun eieio-declare-slots (&rest slots) | ||
| 1089 | "Declare that SLOTS are known eieio object slot names." | ||
| 1090 | (setq eieio--known-slot-names (append slots eieio--known-slot-names))) | ||
| 1091 | |||
| 1088 | (provide 'eieio-core) | 1092 | (provide 'eieio-core) |
| 1089 | 1093 | ||
| 1090 | ;;; eieio-core.el ends here | 1094 | ;;; eieio-core.el ends here |