summaryrefslogtreecommitdiff
path: root/lisp/gnus/nndiary.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2019-05-16 21:50:16 -0400
committerStefan Monnier <monnier@iro.umontreal.ca>2019-05-16 21:50:16 -0400
commit5f6c08ef2c52c7fe526cbe4f9a684438f6a72007 (patch)
tree4d8904ab5cdd8f520e96a95bf00620b5dda41f71 /lisp/gnus/nndiary.el
parentca3c59146bd5c0effdc7602718b91f1ee41f866a (diff)
downloademacs-5f6c08ef2c52c7fe526cbe4f9a684438f6a72007.tar.gz
* lisp/gnus/nnheader.el (mail-header-*): Define via cl-defstruct
This also has the side effect that the accessors are now defined as proper functions rather than as macros, so they can be passed to `mapcar` etc.. * lisp/gnus/nnheader.el (mail-header-number, mail-header-subject) (mail-header-from, mail-header-date, mail-header-id) (mail-header-references, mail-header-chars, mail-header-lines) (mail-header-xref, mail-header-extra): Define via cl-defstruct. (mail-header-set-number, mail-header-set-subject) (mail-header-set-from, mail-header-set-date, mail-header-set-id) (mail-header-set-message-id, mail-header-set-references) (mail-header-set-chars, mail-header-set-lines, mail-header-set-xref) (mail-header-set-extra): Remove, use `setf` instead. All callers adjusted. * lisp/gnus/gnus-sum.el (gnus-select-newsgroup) (gnus-summary-pop-limit, gnus-summary-limit-mark-excluded-as-read) (gnus-summary-find-matching, gnus-find-matching-articles): * lisp/gnus/gnus-kill.el (gnus-apply-kill-file-internal, gnus-execute): * lisp/gnus/gnus-score.el (gnus-score-adaptive): Eta-reduce, now that mail-header-FIELD are functions.
Diffstat (limited to 'lisp/gnus/nndiary.el')
-rw-r--r--lisp/gnus/nndiary.el6
1 files changed, 3 insertions, 3 deletions
diff --git a/lisp/gnus/nndiary.el b/lisp/gnus/nndiary.el
index c8b7eed9870..aca29fea570 100644
--- a/lisp/gnus/nndiary.el
+++ b/lisp/gnus/nndiary.el
@@ -979,7 +979,7 @@ all. This may very well take some time.")
"Add a nov line for the GROUP base."
(with-current-buffer (nndiary-open-nov group)
(goto-char (point-max))
- (mail-header-set-number headers article)
+ (setf (mail-header-number headers) article)
(nnheader-insert-nov headers)))
(defsubst nndiary-header-value ()
@@ -994,8 +994,8 @@ all. This may very well take some time.")
(goto-char (point-min))
(if (search-forward "\n\n" nil t) (1- (point)) (point-max))))
(let ((headers (nnheader-parse-naked-head)))
- (mail-header-set-chars headers chars)
- (mail-header-set-number headers number)
+ (setf (mail-header-chars headers) chars)
+ (setf (mail-header-number headers) number)
headers))))
(defun nndiary-open-nov (group)