diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2019-11-29 12:26:31 -0500 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2019-11-29 12:26:31 -0500 |
commit | b1a69505843c593a3a757a614dea16e2a7185579 (patch) | |
tree | 043919f98b2980e39924c5a52858da57f8cbb7bf /lisp/gnus/gnus-int.el | |
parent | 7fff418edf56244a1fcf54718523aa9b5cb3a854 (diff) | |
download | emacs-b1a69505843c593a3a757a614dea16e2a7185579.tar.gz emacs-b1a69505843c593a3a757a614dea16e2a7185579.tar.bz2 emacs-b1a69505843c593a3a757a614dea16e2a7185579.zip |
* lisp/gnus/gnus.el (gnus-info): Define with `cl-defstruct`
This makes the accessors into (inlined) functions (instead of macros),
which simplifies some uses, and it makes the gnus-info-set-<foo>
macros redundant since we can use `setf` instead. Remove them and
update all users.
(gnus-info-group, gnus-info-rank, gnus-info-read, gnus-info-marks)
(gnus-info-method, gnus-info-params): Auto-defined by defstruct.
(gnus-info-level, gnus-info-score): Define as a function. Add gv-setter.
(gnus-info-set-group, gnus-info-set-rank, gnus-info-set-read): Remove,
use `setf` instead.
(gnus-info-set-marks, gnus-info-set-method, gnus-info-set-params):
Define as a function.
(gnus-info-set-entry): Delete function.
(gnus-info--grow-entry): New function, extracted from it.
(gnus-info--set-level, gnus-info--set-score): New functions, extracted
from the `gnus-info-set-level` and `gnus-info-set-score` which they replace.
(gnus-get-info): Define as a function.
* lisp/gnus/gnus-group.el (gnus-group-edit-group-done):
Use the `extend` arg of `gnus-info-set-method`.
(gnus-group-sort-selected-flat): eta-reduce.
Diffstat (limited to 'lisp/gnus/gnus-int.el')
-rw-r--r-- | lisp/gnus/gnus-int.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/gnus/gnus-int.el b/lisp/gnus/gnus-int.el index 0abbfe6720b..a21bc258403 100644 --- a/lisp/gnus/gnus-int.el +++ b/lisp/gnus/gnus-int.el @@ -727,7 +727,7 @@ If GROUP is nil, all groups on GNUS-COMMAND-METHOD are scanned." (let* ((range (if (= min 2) 1 (cons 1 (1- min)))) (read (gnus-info-read info)) (new-read (gnus-range-add read (list range)))) - (gnus-info-set-read info new-read))) + (setf (gnus-info-read info) new-read))) info))))) (defun gnus-request-expire-articles (articles group &optional force) |