summaryrefslogtreecommitdiff
path: root/lisp/gnus/nnmail.el
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>2006-03-09 07:11:51 +0000
committerMiles Bader <miles@gnu.org>2006-03-09 07:11:51 +0000
commit61e66a158a521e1ebdaa2e547dcc98d383674a75 (patch)
tree3ec3b148d31daa853ae597aacacdf678bcdfe29e /lisp/gnus/nnmail.el
parent66d43aea54f1d7ad2f489a99112856a3ad108bcc (diff)
downloademacs-61e66a158a521e1ebdaa2e547dcc98d383674a75.tar.gz
Revision: emacs@sv.gnu.org/emacs--devo--0--patch-143
Merge from gnus--rel--5.10 Patches applied: * gnus--rel--5.10 (patch 52-55) - Merge from emacs--devo--0 - Update from CVS: Makefile.in (release-*): New targets. - Update from CVS
Diffstat (limited to 'lisp/gnus/nnmail.el')
-rw-r--r--lisp/gnus/nnmail.el21
1 files changed, 14 insertions, 7 deletions
diff --git a/lisp/gnus/nnmail.el b/lisp/gnus/nnmail.el
index edffd6f709a..f4275fa8ed5 100644
--- a/lisp/gnus/nnmail.el
+++ b/lisp/gnus/nnmail.el
@@ -1425,11 +1425,12 @@ See the documentation for the variable `nnmail-split-fancy' for details."
;; Not in cache, compute a regexp for the field/value pair.
(t
- (let* ((field (nth 0 split))
- (value (nth 1 split))
- partial-front
- partial-rear
- regexp)
+ (let ((field (nth 0 split))
+ (value (nth 1 split))
+ (split-rest (cddr split))
+ partial-front
+ partial-rear
+ regexp)
(if (symbolp value)
(setq value (cdr (assq value nnmail-split-abbrev-alist))))
(if (and (>= (length value) 2)
@@ -1441,7 +1442,13 @@ See the documentation for the variable `nnmail-split-fancy' for details."
(string= ".*" (substring value -2)))
(setq value (substring value 0 -2)
partial-rear ""))
- (when nnmail-split-fancy-match-partial-words
+ ;; Invert the match-partial-words behavior if the optional
+ ;; last element is specified.
+ (while (eq (car split-rest) '-)
+ (setq split-rest (cddr split-rest)))
+ (when (if (cadr split-rest)
+ (not nnmail-split-fancy-match-partial-words)
+ nnmail-split-fancy-match-partial-words)
(setq partial-front ""
partial-rear ""))
(setq regexp (concat "^\\(\\("
@@ -1456,7 +1463,7 @@ See the documentation for the variable `nnmail-split-fancy' for details."
(or partial-rear "\\>")))
(push (cons split regexp) nnmail-split-cache)
;; Now that it's in the cache, just call nnmail-split-it again
- ;; on the same split, which will find it immediately in the cache.
+ ;; on the same split, which will find it immediately in the cache.
(nnmail-split-it split))))))
(defun nnmail-expand-newtext (newtext)