From 7532f6393666b9e53f7ecc565392c59316d302ec Mon Sep 17 00:00:00 2001 From: kaoru Date: Sat, 2 Jan 2010 05:50:10 +0000 Subject: [PATCH] * elmo.el (elmo-folder-info-make-hashtb): Use `mapc' instead of `mapcar'; Suppress compile warning. * elmo-imap4.el (elmo-network-initialize-session-buffer) (elmo-imap4-search-internal-primitive): Ditto. * elmo-nntp.el (elmo-nntp-search-primitive): Ditto. * elmo-archive.el (elmo-archive-exec-msgs-subr2): Ditto. --- elmo/ChangeLog | 7 +++++++ elmo/elmo-archive.el | 30 ++++++++++++++++-------------- elmo/elmo-imap4.el | 4 ++-- elmo/elmo-nntp.el | 2 +- elmo/elmo.el | 2 +- 5 files changed, 27 insertions(+), 18 deletions(-) diff --git a/elmo/ChangeLog b/elmo/ChangeLog index c164ec6..41d3773 100644 --- a/elmo/ChangeLog +++ b/elmo/ChangeLog @@ -1,5 +1,12 @@ 2010-01-02 TAKAHASHI Kaoru + * elmo.el (elmo-folder-info-make-hashtb): Use `mapc' instead of + `mapcar'; Suppress compile warning. + * elmo-imap4.el (elmo-network-initialize-session-buffer) + (elmo-imap4-search-internal-primitive): Ditto. + * elmo-nntp.el (elmo-nntp-search-primitive): Ditto. + * elmo-archive.el (elmo-archive-exec-msgs-subr2): Ditto. + * elmo-imap4.el (elmo-imap4-parse-address-list) (elmo-imap4-parse-fetch-body-section, elmo-imap4-parse-body) (elmo-imap4-parse-acl, elmo-imap4-parse-body-extension) diff --git a/elmo/elmo-archive.el b/elmo/elmo-archive.el index 31b7c70..29a9d63 100644 --- a/elmo/elmo-archive.el +++ b/elmo/elmo-archive.el @@ -811,20 +811,22 @@ TYPE specifies the archiver's symbol." (setq sum 0) (catch 'done (while (and rest (<= i n)) - (mapcar '(lambda (x) - (let* ((len (length x)) - (files (member x (reverse rest)))) - ;; total(previous) + current + white space - (if (<= max-len (+ sum len 1)) - (progn - (unless - (elmo-archive-call-process - prog (append args files)) - (throw 'done nil)) - (setq sum 0) ;; reset - (setq rest (nthcdr i rest))) - (setq sum (+ sum len 1))) - (setq i (1+ i)))) msgs)) + (mapc + (lambda (x) + (let* ((len (length x)) + (files (member x (reverse rest)))) + ;; total(previous) + current + white space + (if (<= max-len (+ sum len 1)) + (progn + (unless + (elmo-archive-call-process + prog (append args files)) + (throw 'done nil)) + (setq sum 0) ;; reset + (setq rest (nthcdr i rest))) + (setq sum (+ sum len 1))) + (setq i (1+ i)))) + msgs)) (throw 'done (or (not rest) (elmo-archive-call-process prog (append args rest)))) diff --git a/elmo/elmo-imap4.el b/elmo/elmo-imap4.el index 9306c38..8a79d8b 100644 --- a/elmo/elmo-imap4.el +++ b/elmo/elmo-imap4.el @@ -963,7 +963,7 @@ If CHOP-LENGTH is not specified, message set is not chopped." elmo-network-initialize-session-buffer :after ((session elmo-imap4-session) buffer) (with-current-buffer buffer - (mapcar 'make-variable-buffer-local elmo-imap4-local-variables) + (mapc 'make-variable-buffer-local elmo-imap4-local-variables) (setq elmo-imap4-seqno 0) (setq elmo-imap4-status 'initial))) @@ -2224,7 +2224,7 @@ If optional argument REMOVE is non-nil, remove FLAG." (let* ((numbers (or from-msgs (elmo-folder-list-messages folder))) (rest (nthcdr (string-to-number (elmo-filter-value filter) ) numbers))) - (mapcar '(lambda (x) (delete x numbers)) rest) + (mapc (lambda (x) (delete x numbers)) rest) numbers)) ((string= "flag" search-key) (elmo-imap4-folder-list-flagged diff --git a/elmo/elmo-nntp.el b/elmo/elmo-nntp.el index 7d87353..cd91eb1 100644 --- a/elmo/elmo-nntp.el +++ b/elmo/elmo-nntp.el @@ -1080,7 +1080,7 @@ Returns a list of cons cells like (NUMBER . VALUE)" (let* ((numbers (or from-msgs (elmo-folder-list-messages spec))) (rest (nthcdr (string-to-number (elmo-filter-value condition) ) numbers))) - (mapcar '(lambda (x) (delete x numbers)) rest) + (mapc (lambda (x) (delete x numbers)) rest) numbers)) ((or (string= "since" search-key) (string= "before" search-key)) diff --git a/elmo/elmo.el b/elmo/elmo.el index ed890eb..9919a84 100644 --- a/elmo/elmo.el +++ b/elmo/elmo.el @@ -973,7 +973,7 @@ If optional argument IF-EXISTS is nil, load on demand. "Setup folder info hashtable by INFO-ALIST on HASHTB." (let* ((hashtb (or hashtb (elmo-make-hash (length info-alist))))) - (mapcar + (mapc (lambda (x) (let ((info (cadr x))) (and (intern-soft (car x) hashtb) -- 1.7.10.4