From ed6bc44680e7de1180b720995923d7d14542f008 Mon Sep 17 00:00:00 2001 From: Jesper Harder Date: Sun, 26 Sep 2004 17:16:24 +0000 Subject: [PATCH] (message-cite-original-without-signature) (message-cite-original): Use mapc. (message-do-actions, message-make-forward-subject): Use dolist. --- lisp/ChangeLog | 6 ++++++ lisp/message.el | 28 ++++++++++++---------------- 2 files changed, 18 insertions(+), 16 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7c72101ed..27b4141eb 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2004-09-26 Jesper Harder + + * message.el (message-cite-original-without-signature) + (message-cite-original): Use mapc. + (message-do-actions, message-make-forward-subject): Use dolist. + 2004-09-25 Kevin Greiner * gnus-agent.el (gnus-agent-check-overview-buffer): Fixed range of diff --git a/lisp/message.el b/lisp/message.el index 9926ed7ea..a9012430f 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -3257,8 +3257,7 @@ prefix, and don't delete any headers." ;; Insert a blank line if it is peeled off. (insert "\n"))) (goto-char start) - (while functions - (funcall (pop functions))) + (mapc 'funcall functions) (when message-citation-line-function (unless (bolp) (insert "\n")) @@ -3295,8 +3294,7 @@ prefix, and don't delete any headers." 0 0 "")))) (mml-quote-region start end) (goto-char start) - (while functions - (funcall (pop functions))) + (mapc 'funcall functions) (when message-citation-line-function (unless (bolp) (insert "\n")) @@ -3631,16 +3629,15 @@ not have PROP." (defun message-do-actions (actions) "Perform all actions in ACTIONS." ;; Now perform actions on successful sending. - (while actions + (dolist (action actions) (ignore-errors (cond ;; A simple function. - ((functionp (car actions)) - (funcall (car actions))) + ((functionp action) + (funcall action)) ;; Something to be evaled. (t - (eval (car actions))))) - (pop actions))) + (eval action)))))) (defun message-send-mail-partially () "Send mail as message/partial." @@ -5259,7 +5256,7 @@ they are." ;; When sending via news, make sure the total folded length will ;; be less than 998 characters. This is to cater to broken INN ;; 2.3 which counts the total number of characters in a header - ;; rather than the physical line length of each line, as it shuld. + ;; rather than the physical line length of each line, as it should. ;; ;; This hack should be removed when it's believed than INN 2.3 is ;; no longer widely used. @@ -6152,18 +6149,17 @@ the message." subject (mail-decode-encoded-word-string subject)) "")) - (if message-wash-forwarded-subjects - (setq subject (message-wash-subject subject))) + (when message-wash-forwarded-subjects + (setq subject (message-wash-subject subject))) ;; Make sure funcs is a list. (and funcs (not (listp funcs)) (setq funcs (list funcs))) ;; Apply funcs in order, passing subject generated by previous ;; func to the next one. - (while funcs - (when (functionp (car funcs)) - (setq subject (funcall (car funcs) subject))) - (setq funcs (cdr funcs))) + (dolist (func funcs) + (when (functionp func) + (setq subject (funcall func subject)))) subject)))) (eval-when-compile -- 2.34.1