mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-16 17:24:23 +00:00
* lisp/gnus/gnus-topic.el: Fix a backward incompatibility
(gnus-topic-insert-topic-line): Make the vars used in `gnus-topic-line-format-spec` dynamically scoped since it seems that they're sometimes accessed from functions called by `gnus-topic-line-format-spec` :-( * lisp/gnus/gnus-util.el (gnus--\,@): Move macro to here... * lisp/gnus/gnus-art.el (gnus--\,@): .. from here. * lisp/gnus/gnus.el (gnus-method-to-server): Apply DeMorgan.
This commit is contained in:
parent
1b0e6a16d3
commit
69943ae70c
4 changed files with 16 additions and 15 deletions
|
|
@ -4325,10 +4325,6 @@ If variable `gnus-use-long-file-name' is non-nil, it is
|
|||
(if (gnus-buffer-live-p gnus-original-article-buffer)
|
||||
(canlock-verify gnus-original-article-buffer)))
|
||||
|
||||
(defmacro gnus--\,@ (exp)
|
||||
(declare (debug t))
|
||||
`(progn ,@(eval exp t)))
|
||||
|
||||
(gnus--\,@
|
||||
(mapcar (lambda (func)
|
||||
`(defun ,(intern (format "gnus-%s" func))
|
||||
|
|
|
|||
|
|
@ -627,7 +627,14 @@ articles in the topic and its subtopics."
|
|||
|
||||
(defun gnus-topic-insert-topic-line (name visiblep shownp level entries
|
||||
&optional unread)
|
||||
(gnus--\,@
|
||||
(let ((vars '(indentation visible name level number-of-groups
|
||||
total-number-of-articles entries)))
|
||||
`((with-suppressed-warnings ((lexical ,@vars))
|
||||
,@(mapcar (lambda (s) `(defvar ,s)) vars)))))
|
||||
(let* ((visible (if visiblep "" "..."))
|
||||
(level level)
|
||||
(name name)
|
||||
(indentation (make-string (* gnus-topic-indent-level level) ? ))
|
||||
(total-number-of-articles unread)
|
||||
(number-of-groups (length entries))
|
||||
|
|
@ -640,14 +647,7 @@ articles in the topic and its subtopics."
|
|||
(add-text-properties
|
||||
(point)
|
||||
(prog1 (1+ (point))
|
||||
(eval gnus-topic-line-format-spec
|
||||
`((indentation . ,indentation)
|
||||
(visible . ,visible)
|
||||
(name . ,name)
|
||||
(level . ,level)
|
||||
(number-of-groups . ,number-of-groups)
|
||||
(total-number-of-articles . ,total-number-of-articles)
|
||||
(entries . ,entries))))
|
||||
(eval gnus-topic-line-format-spec t))
|
||||
(list 'gnus-topic name
|
||||
'gnus-topic-level level
|
||||
'gnus-topic-unread unread
|
||||
|
|
|
|||
|
|
@ -1068,6 +1068,11 @@ ARG is passed to the first function."
|
|||
|
||||
;;; Various
|
||||
|
||||
(defmacro gnus--\,@ (exp)
|
||||
"Splice EXP's value (a list of Lisp forms) into the code."
|
||||
(declare (debug t))
|
||||
`(progn ,@(eval exp t)))
|
||||
|
||||
(defvar gnus-group-buffer) ; Compiler directive
|
||||
(defun gnus-alive-p ()
|
||||
"Say whether Gnus is running or not."
|
||||
|
|
|
|||
|
|
@ -3212,9 +3212,9 @@ that that variable is buffer-local to the summary buffers."
|
|||
(format "%s" (car method))
|
||||
(format "%s:%s" (car method) (cadr method))))
|
||||
(name-method (cons name method)))
|
||||
(when (and (not no-enter-cache)
|
||||
(not (member name-method gnus-server-method-cache))
|
||||
(not (assoc (car name-method) gnus-server-method-cache)))
|
||||
(unless (or no-enter-cache
|
||||
(member name-method gnus-server-method-cache)
|
||||
(assoc (car name-method) gnus-server-method-cache))
|
||||
(push name-method gnus-server-method-cache))
|
||||
name)))
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue