mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
* 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.
This commit is contained in:
parent
ca3c59146b
commit
5f6c08ef2c
13 changed files with 72 additions and 151 deletions
|
|
@ -1162,15 +1162,15 @@ This command does not work if you use short group names."
|
|||
(with-temp-buffer
|
||||
(insert-buffer-substring buf b e)
|
||||
(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 nnfolder-add-nov (group article headers)
|
||||
"Add a nov line for the GROUP base."
|
||||
(with-current-buffer (nnfolder-open-nov group)
|
||||
(goto-char (point-max))
|
||||
(mail-header-set-number headers article)
|
||||
(setf (mail-header-number headers) article)
|
||||
(nnheader-insert-nov headers)))
|
||||
|
||||
(provide 'nnfolder)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue