Commit 74b097b6 authored by Stefan Monnier's avatar Stefan Monnier

* lisp/mh-e: Use cl-lib

Also, use underscore prefixes and defvar in preparation for lexical binding

* lisp/mh-e/mh-acros.el: Require cl-lib instead of cl.
Rename all cl.el uses by adding `cl-` prefix.
(mh-require-cl): Remove.  Not needed any more.  Remove all calls.
(mh-defstruct): Remove.  Replace all uses with cl-defstruct.
(mh-dlet*): New macro.

* lisp/mh-e/mh-comp.el (mh-user-agent-compose): Fold all ignored
optional args into the &rest arg.

* lisp/mh-e/mh-e.el: Require cl-lib instead of using mh-require-cl.
(mh-variants): Don't add-to-list on a local var.

* lisp/mh-e/mh-folder.el (mh-restore-desktop-buffer): Use shorter arg
names that don't collide with global vars.

* lisp/mh-e/mh-mime.el (mh-insert-mime-button):
(mh-insert-mime-security-button): Use mh-dlet*.

* lisp/mh-e/mh-search.el (mh-swish-next-result, mh-grep-next-result)
(mh-namazu-next-result): Use `or`.

* lisp/mh-e/mh-thread.el (mh-thread-generate)
(mh-thread-prune-containers): Use underscore rather than declare+ignore.

* lisp/mh-e/mh-tool-bar.el (mh-tool-bar-define): Use mh-dlet*.
(mh-tool-bar-define): Prefer the more precise \`...\' regexp ops.
Prefer Elisp's `eval-and-compile` over `cl-eval-when`.

* lisp/mh-e/mh-xface.el (mh-picon-get-image): Don't use
mh-funcall-if-exists for ietf-drums-parse-address.
Avoid the use of `cl-return` and hence use plain `defun`.
Replace some `cl-loop` with `dolist`.
parent b06917a4
Pipeline #2771 failed with stage
in 75 minutes and 21 seconds
......@@ -40,30 +40,12 @@
;;; Code:
(require 'cl)
(require 'cl-lib)
;;; Compatibility
;; TODO: Replace `cl' with `cl-lib'.
;; `cl' is deprecated in Emacs 24.3. Use `cl-lib' instead. However,
;; we'll likely have to insert `cl-' before each use of a Common Lisp
;; function.
;;;###mh-autoload
(defmacro mh-require-cl ()
"Macro to load \"cl\" if needed.
Emacs coding conventions require that the \"cl\" package not be
required at runtime. However, the \"cl\" package in Emacs 21.4
and earlier left \"cl\" routines in their macro expansions. In
particular, the expansion of (setf (gethash ...) ...) used
functions in \"cl\" at run time. This macro recognizes that and
loads \"cl\" appropriately."
(if (eq (car (macroexpand '(setf (gethash foo bar) baz))) 'cl-puthash)
'(require 'cl)
'(eval-when-compile (require 'cl))))
;;;###mh-autoload
(defmacro mh-do-in-gnu-emacs (&rest body)
"Execute BODY if in GNU Emacs."
......@@ -81,6 +63,9 @@ loads \"cl\" appropriately."
;;;###mh-autoload
(defmacro mh-funcall-if-exists (function &rest args)
"Call FUNCTION with ARGS as parameters if it exists."
;; FIXME: Not clear when this should be used. If the function happens
;; not to exist at compile-time (e.g. because the corresponding package
;; wasn't loaded), then it won't ever be used :-(
(when (fboundp function)
`(when (fboundp ',function)
(funcall ',function ,@args))))
......@@ -135,53 +120,6 @@ check if variable `transient-mark-mode' is active."
'(and (boundp 'transient-mark-mode) transient-mark-mode
(boundp 'mark-active) mark-active))))
;; Shush compiler.
(mh-do-in-xemacs
(defvar struct)
(defvar x)
(defvar y))
;;;###mh-autoload
(defmacro mh-defstruct (name-spec &rest fields)
;; FIXME: Use `cl-defstruct' instead: shouldn't emit warnings any
;; more nor depend on run-time CL functions.
"Replacement for `defstruct' from the \"cl\" package.
The `defstruct' in the \"cl\" library produces compiler warnings,
and generates code that uses functions present in \"cl\" at
run-time. This is a partial replacement, that avoids these
issues.
NAME-SPEC declares the name of the structure, while FIELDS
describes the various structure fields. Lookup `defstruct' for
more details."
(let* ((struct-name (if (atom name-spec) name-spec (car name-spec)))
(conc-name (or (and (consp name-spec)
(cadr (assoc :conc-name (cdr name-spec))))
(format "%s-" struct-name)))
(predicate (intern (format "%s-p" struct-name)))
(constructor (or (and (consp name-spec)
(cadr (assoc :constructor (cdr name-spec))))
(intern (format "make-%s" struct-name))))
(fields (mapcar (lambda (x)
(if (atom x)
(list x nil)
(list (car x) (cadr x))))
fields))
(field-names (mapcar #'car fields))
(struct (gensym "S"))
(x (gensym "X"))
(y (gensym "Y")))
`(progn
(defun* ,constructor (&key ,@fields)
(list (quote ,struct-name) ,@field-names))
(defun ,predicate (arg)
(and (consp arg) (eq (car arg) (quote ,struct-name))))
,@(loop for x from 1
for y in field-names
collect `(defmacro ,(intern (format "%s%s" conc-name y)) (z)
(list 'nth ,x z)))
(quote ,struct-name))))
;;;###mh-autoload
(defmacro with-mh-folder-updating (save-modification-flag &rest body)
"Format is (with-mh-folder-updating (SAVE-MODIFICATION-FLAG) &body BODY).
......@@ -327,6 +265,16 @@ MH-E functions."
,@body))))))))
(put 'mh-iterate-on-range 'lisp-indent-hook 'defun)
(defmacro mh-dlet* (binders &rest body)
"Like `let*' but always dynamically scoped."
(declare (debug let) (indent 1))
;; Works in both lexical and non-lexical mode.
`(progn
,@(mapcar (lambda (binder)
`(defvar ,(if (consp binder) (car binder) binder)))
binders)
(let* ,binders ,@body)))
(provide 'mh-acros)
;; Local Variables:
......
......@@ -30,8 +30,6 @@
(require 'mh-e)
(mh-require-cl)
(require 'goto-addr)
(defvar mh-alias-alist 'not-read
......@@ -308,7 +306,7 @@ Blind aliases or users from /etc/passwd are not expanded."
(if (not mh-alias-expand-aliases-flag)
mh-alias-alist
(lambda (string pred action)
(case action
(cl-case action
((nil)
(let ((res (try-completion string mh-alias-alist pred)))
(if (or (eq res t)
......
......@@ -217,7 +217,7 @@ TO, CC, and SUBJECT arguments are used."
(defvar mh-error-if-no-draft nil) ;raise error over using old draft
;;;###autoload
(defun mh-smail-batch (&optional to subject other-headers &rest ignored)
(defun mh-smail-batch (&optional to subject _other-headers &rest _ignored)
"Compose a message with the MH mail system.
This function does not prompt the user for any header fields, and
......@@ -239,10 +239,7 @@ applications should use `mh-user-agent-compose'."
'mh-before-send-letter-hook)
;;;###autoload
(defun mh-user-agent-compose (&optional to subject other-headers continue
switch-function yank-action
send-actions return-action
&rest ignored)
(defun mh-user-agent-compose (&optional to subject other-headers &rest _ignored)
"Set up mail composition draft with the MH mail system.
This is the `mail-user-agent' entry point to MH-E. This function
conforms to the contract specified by `define-mail-user-agent'
......@@ -256,8 +253,7 @@ OTHER-HEADERS is an alist specifying additional header fields.
Elements look like (HEADER . VALUE) where both HEADER and VALUE
are strings.
CONTINUE, SWITCH-FUNCTION, YANK-ACTION, SEND-ACTIONS, and
RETURN-ACTION and any additional arguments are IGNORED."
Any additional arguments are IGNORED."
(mh-find-path)
(let ((mh-error-if-no-draft t))
(mh-send to "" subject)
......@@ -266,9 +262,7 @@ RETURN-ACTION and any additional arguments are IGNORED."
(cdr (car other-headers)))
(setq other-headers (cdr other-headers)))))
;; Shush compiler.
(mh-do-in-xemacs
(defvar sendmail-coding-system))
(defvar sendmail-coding-system)
;;;###autoload
(defun mh-send-letter (&optional arg)
......@@ -1297,10 +1291,10 @@ discarded."
"Check if current buffer is entirely composed of ASCII.
The function doesn't work for XEmacs since `find-charset-region'
doesn't exist there."
(loop for charset in (mh-funcall-if-exists
find-charset-region (point-min) (point-max))
unless (eq charset 'ascii) return nil
finally return t))
(cl-loop for charset in (mh-funcall-if-exists
find-charset-region (point-min) (point-max))
unless (eq charset 'ascii) return nil
finally return t))
(provide 'mh-comp)
......
......@@ -143,7 +143,7 @@ introduced in Emacs 22."
`(face-background ,face ,frame ,inherit)))
(defun-mh mh-font-lock-add-keywords font-lock-add-keywords
(mode keywords &optional how)
(_mode _keywords &optional _how)
"XEmacs does not have `font-lock-add-keywords'.
This function returns nil on that system.")
......@@ -243,7 +243,7 @@ compatibility with versions of Emacs that lack the variable
(delete image-directory (copy-sequence (or path load-path))))))
(defun-mh mh-image-search-load-path
image-search-load-path (file &optional path)
image-search-load-path (_file &optional _path)
"Emacs 21 and XEmacs don't have `image-search-load-path'.
This function returns nil on those systems."
nil)
......@@ -292,7 +292,7 @@ introduced in Emacs 24."
`(make-obsolete-variable ,obsolete-name ,current-name ,when ,access-type))))
(defun-mh mh-match-string-no-properties
match-string-no-properties (num &optional string)
match-string-no-properties (num &optional _string)
"Return string of text matched by last search, without text properties.
This function is used by XEmacs that lacks `match-string-no-properties'.
The function `buffer-substring-no-properties' is used instead.
......@@ -301,7 +301,7 @@ The argument STRING is ignored."
(match-beginning num) (match-end num)))
(defun-mh mh-replace-regexp-in-string replace-regexp-in-string
(regexp rep string &optional fixedcase literal subexp start)
(regexp rep string &optional _fixedcase literal _subexp _start)
"Replace REGEXP with REP everywhere in STRING and return result.
This function is used by XEmacs that lacks `replace-regexp-in-string'.
The function `replace-in-string' is used instead.
......@@ -311,7 +311,7 @@ The arguments FIXEDCASE, SUBEXP, and START, used by
(replace-in-string string regexp rep literal)))
(defun-mh mh-test-completion
test-completion (string collection &optional predicate)
test-completion (_string _collection &optional _predicate)
"Return non-nil if STRING is a valid completion.
XEmacs does not have `test-completion'. This function returns nil
on that system." nil)
......@@ -352,7 +352,7 @@ The arguments RETURN-TO and EXIT-ACTION are ignored."
(view-mode 1))
(defun-mh mh-window-full-height-p
window-full-height-p (&optional WINDOW)
window-full-height-p (&optional _window)
"Return non-nil if WINDOW is not the result of a vertical split.
This function is defined in XEmacs as it lacks
`window-full-height-p'. The values of the functions
......
......@@ -91,7 +91,7 @@
;; for if it does it will introduce a require loop.
(require 'mh-loaddefs)
(mh-require-cl)
(require 'cl-lib)
(require 'mh-buffers)
(require 'mh-compat)
......@@ -496,7 +496,7 @@ all the strings have been used."
(push (buffer-substring-no-properties (point)
(mh-line-end-position))
arg-list)
(incf count)
(cl-incf count)
(forward-line))
(apply #'call-process cmd nil (list out nil) nil
(nreverse arg-list))))
......@@ -509,8 +509,8 @@ all the strings have been used."
Adds double-quotes around entire string and quotes the characters
\\, `, and $ with a backslash."
(concat "\""
(loop for x across string
concat (format (if (memq x '(?\\ ?` ?$)) "\\%c" "%c") x))
(cl-loop for x across string
concat (format (if (memq x '(?\\ ?` ?$)) "\\%c" "%c") x))
"\""))
(defun mh-exec-cmd (command &rest args)
......@@ -527,7 +527,7 @@ parsed by MH-E."
(save-excursion
(goto-char start)
(insert "Errors when executing: " command)
(loop for arg in args do (insert " " arg))
(cl-loop for arg in args do (insert " " arg))
(insert "\n"))
(save-window-excursion
(switch-to-buffer-other-window mh-log-buffer)
......@@ -583,7 +583,7 @@ ARGS are passed to COMMAND as command line arguments."
(push elem process-environment))
(apply #'mh-exec-cmd-daemon command filter args)))
(defun mh-process-daemon (process output)
(defun mh-process-daemon (_process output)
"PROCESS daemon that puts OUTPUT into a temporary buffer.
Any output from the process is displayed in an asynchronous
pop-up window."
......@@ -683,11 +683,11 @@ ARGS is returned unchanged."
`(if (boundp 'customize-package-emacs-version-alist)
,args
(let (seen)
(loop for keyword in ,args
if (cond ((eq keyword ':package-version) (setq seen t) nil)
(seen (setq seen nil) nil)
(t t))
collect keyword))))
(cl-loop for keyword in ,args
if (cond ((eq keyword ':package-version) (setq seen t) nil)
(seen (setq seen nil) nil)
(t t))
collect keyword))))
(defmacro defgroup-mh (symbol members doc &rest args)
"Declare SYMBOL as a customization group containing MEMBERS.
......@@ -740,14 +740,14 @@ is described by the variable `mh-variants'."
(let ((list-unique))
;; Make a unique list of directories, keeping the given order.
;; We don't want the same MH variant to be listed multiple times.
(loop for dir in (append mh-path mh-sys-path exec-path) do
(setq dir (file-chase-links (directory-file-name dir)))
(add-to-list 'list-unique dir))
(loop for dir in (nreverse list-unique) do
(when (and dir (file-accessible-directory-p dir))
(let ((variant (mh-variant-info dir)))
(if variant
(add-to-list 'mh-variants variant)))))
(cl-loop for dir in (append mh-path mh-sys-path exec-path) do
(setq dir (file-chase-links (directory-file-name dir)))
(cl-pushnew dir list-unique :test #'equal))
(cl-loop for dir in (nreverse list-unique) do
(when (and dir (file-accessible-directory-p dir))
(let ((variant (mh-variant-info dir)))
(if variant
(add-to-list 'mh-variants variant)))))
mh-variants)))
(defun mh-variant-info (dir)
......@@ -858,22 +858,22 @@ variant."
mh-progs progs
mh-variant-in-use variant))))
((symbolp variant) ;e.g. 'nmh (pick the first match)
(loop for variant-list in (mh-variants)
when (eq variant (cadr (assoc 'variant (cdr variant-list))))
return (let* ((version (car variant-list))
(alist (cdr variant-list))
(lib-progs (cadr (assoc 'mh-lib-progs alist)))
(lib (cadr (assoc 'mh-lib alist)))
(progs (cadr (assoc 'mh-progs alist)))
(flists (cadr (assoc 'flists alist))))
;;(set-default mh-variant flavor)
(setq mh-x-mailer-string nil
mh-flists-present-flag flists
mh-lib-progs lib-progs
mh-lib lib
mh-progs progs
mh-variant-in-use version)
t)))))
(cl-loop for variant-list in (mh-variants)
when (eq variant (cadr (assoc 'variant (cdr variant-list))))
return (let* ((version (car variant-list))
(alist (cdr variant-list))
(lib-progs (cadr (assoc 'mh-lib-progs alist)))
(lib (cadr (assoc 'mh-lib alist)))
(progs (cadr (assoc 'mh-progs alist)))
(flists (cadr (assoc 'flists alist))))
;;(set-default mh-variant flavor)
(setq mh-x-mailer-string nil
mh-flists-present-flag flists
mh-lib-progs lib-progs
mh-lib lib
mh-progs progs
mh-variant-in-use version)
t)))))
(defun mh-variant-p (&rest variants)
"Return t if variant is any of VARIANTS.
......@@ -1706,9 +1706,9 @@ The function is always called with SYMBOL bound to
(set symbol value) ;XXX shouldn't this be set-default?
(setq mh-junk-choice
(or value
(loop for element in mh-junk-function-alist
until (executable-find (symbol-name (car element)))
finally return (car element)))))
(cl-loop for element in mh-junk-function-alist
until (executable-find (symbol-name (car element)))
finally return (car element)))))
(defcustom-mh mh-junk-background nil
"If on, spam programs are run in background.
......@@ -2885,9 +2885,9 @@ removed and entries from `mh-invisible-header-fields' are added."
(when mh-invisible-header-fields-default
;; Remove entries from `mh-invisible-header-fields-default'
(setq fields
(loop for x in fields
unless (member x mh-invisible-header-fields-default)
collect x)))
(cl-loop for x in fields
unless (member x mh-invisible-header-fields-default)
collect x)))
(when (and (boundp 'mh-invisible-header-fields)
mh-invisible-header-fields)
(dolist (x mh-invisible-header-fields)
......@@ -3605,16 +3605,17 @@ specified colors."
new-spec)
;; Remove entries with min-colors, or delete them if we have
;; fewer colors than they specify.
(loop for entry in (reverse spec) do
(let ((requirement (if (eq (car entry) t)
nil
(assq 'min-colors (car entry)))))
(if requirement
(when (>= cells (nth 1 requirement))
(setq new-spec (cons (cons (delq requirement (car entry))
(cdr entry))
new-spec)))
(setq new-spec (cons entry new-spec)))))
(cl-loop
for entry in (reverse spec) do
(let ((requirement (if (eq (car entry) t)
nil
(assq 'min-colors (car entry)))))
(if requirement
(when (>= cells (nth 1 requirement))
(setq new-spec (cons (cons (delq requirement (car entry))
(cdr entry))
new-spec)))
(setq new-spec (cons entry new-spec)))))
new-spec))))
(defface-mh mh-folder-address
......
......@@ -31,7 +31,6 @@
(require 'mh-e)
(require 'mh-scan)
(mh-require-cl)
;; Dynamically-created functions not found in mh-loaddefs.el.
(autoload 'mh-tool-bar-folder-buttons-init "mh-tool-bar")
......@@ -80,16 +79,14 @@ the MH mail system."
(add-to-list 'desktop-buffer-mode-handlers
'(mh-folder-mode . mh-restore-desktop-buffer)))
(defun mh-restore-desktop-buffer (desktop-buffer-file-name
desktop-buffer-name
desktop-buffer-misc)
(defun mh-restore-desktop-buffer (_file-name name _misc)
"Restore an MH folder buffer specified in a desktop file.
When desktop creates a buffer, DESKTOP-BUFFER-FILE-NAME holds the
file name to visit, DESKTOP-BUFFER-NAME holds the desired buffer
name, and DESKTOP-BUFFER-MISC holds a list of miscellaneous info
When desktop creates a buffer, FILE-NAME holds the
file name to visit, NAME holds the desired buffer
name, and MISC holds a list of miscellaneous info
used by the `desktop-buffer-mode-handlers' functions."
(mh-find-path)
(mh-visit-folder desktop-buffer-name)
(mh-visit-folder name)
(current-buffer))
......@@ -932,9 +929,9 @@ many unread messages to skip."
(setq count (1- count)))
(not (car unread-sequence)))
(message "No more unread messages"))
(t (loop for msg in unread-sequence
when (mh-goto-msg msg t) return nil
finally (message "No more unread messages"))))))
(t (cl-loop for msg in unread-sequence
when (mh-goto-msg msg t) return nil
finally (message "No more unread messages"))))))
;;;###mh-autoload
(defun mh-page-msg (&optional lines)
......@@ -1030,9 +1027,9 @@ many unread messages to skip."
(setq count (1- count)))
(not (car unread-sequence)))
(message "No more unread messages"))
(t (loop for msg in unread-sequence
when (mh-goto-msg msg t) return nil
finally (message "No more unread messages"))))))
(t (cl-loop for msg in unread-sequence
when (mh-goto-msg msg t) return nil
finally (message "No more unread messages"))))))
;;;###mh-autoload
(defun mh-quit ()
......@@ -1503,7 +1500,7 @@ function doesn't recenter the folder buffer."
(let ((lines-from-end 2))
(save-excursion
(while (> (point-max) (progn (forward-line) (point)))
(incf lines-from-end)))
(cl-incf lines-from-end)))
(recenter (- lines-from-end))))
;; '(4) is the same as C-u prefix argument.
(t (recenter (or arg '(4))))))
......@@ -1587,10 +1584,11 @@ after the commands are processed."
;; Preserve sequences in destination folder...
(when mh-refile-preserves-sequences-flag
(clrhash dest-map)
(loop for i from (1+ (or last 0))
for msg in (sort (copy-sequence msgs) #'<)
do (loop for seq-name in (gethash msg seq-map)
do (push i (gethash seq-name dest-map))))
(cl-loop
for i from (1+ (or last 0))
for msg in (sort (copy-sequence msgs) #'<)
do (cl-loop for seq-name in (gethash msg seq-map)
do (push i (gethash seq-name dest-map))))
(maphash
#'(lambda (seq msgs)
;; Can't be run in the background, since the
......@@ -1639,10 +1637,10 @@ after the commands are processed."
(mh-delete-scan-msgs mh-whitelist)
(when mh-whitelist-preserves-sequences-flag
(clrhash white-map)
(loop for i from (1+ (or last 0))
for msg in (sort (copy-sequence mh-whitelist) #'<)
do (loop for seq-name in (gethash msg seq-map)
do (push i (gethash seq-name white-map))))
(cl-loop for i from (1+ (or last 0))
for msg in (sort (copy-sequence mh-whitelist) #'<)
do (cl-loop for seq-name in (gethash msg seq-map)
do (push i (gethash seq-name white-map))))
(maphash
#'(lambda (seq msgs)
;; Can't be run in background, since the current
......@@ -1922,10 +1920,11 @@ exist."
(from (or (message-fetch-field "from") ""))
folder-name)
(setq folder-name
(loop for list in mh-default-folder-list
when (string-match (nth 0 list) (if (nth 2 list) to/cc from))
return (nth 1 list)
finally return nil))
(cl-loop for list in mh-default-folder-list
when (string-match (nth 0 list)
(if (nth 2 list) to/cc from))
return (nth 1 list)
finally return nil))
;; Make sure a result from `mh-default-folder-list' begins with "+"
;; since 'mh-expand-file-name below depends on it
......@@ -2026,8 +2025,8 @@ If MSG is nil then act on the message at point"
(t
(dolist (folder-msg-list mh-refile-list)
(setf (cdr folder-msg-list) (remove msg (cdr folder-msg-list))))
(setq mh-refile-list (loop for x in mh-refile-list
unless (null (cdr x)) collect x))))
(setq mh-refile-list (cl-loop for x in mh-refile-list
unless (null (cdr x)) collect x))))
(mh-notate nil ? mh-cmd-note)))
;;;###mh-autoload
......
......@@ -123,7 +123,7 @@ folder. This is useful for folders that are easily regenerated."
(message "Folder %s removed" folder))
(message "Folder not removed")))
(defun mh-rmf-daemon (process output)
(defun mh-rmf-daemon (_process output)
"The rmf PROCESS puts OUTPUT in temporary buffer.
Display the results only if something went wrong."
(set-buffer (get-buffer-create mh-temp-buffer))
......
......@@ -79,7 +79,7 @@
;; Function from mm-decode.el used in PGP messages. Just define it with older
;; Gnus to avoid compiler warning.
(defun-mh mh-mm-possibly-verify-or-decrypt
mm-possibly-verify-or-decrypt (parts ctl)
mm-possibly-verify-or-decrypt (_parts _ctl)
nil)
;; Copy of macro in mm-decode.el.
......@@ -110,16 +110,16 @@
(and (> (current-column) length)
(current-column))))
(defun-mh mh-mm-keep-viewer-alive-p mm-keep-viewer-alive-p (handle)
(defun-mh mh-mm-keep-viewer-alive-p mm-keep-viewer-alive-p (_handle)
;; Released Gnus doesn't keep handles associated with externally displayed
;; MIME parts. So this will always return nil.
nil)
(defun-mh mh-mm-destroy-parts mm-destroy-parts (list)
(defun-mh mh-mm-destroy-parts mm-destroy-parts (_list)
"Older versions of Emacs don't have this function."
nil)
(defun-mh mh-mm-uu-dissect-text-parts mm-uu-dissect-text-parts (handles)
(defun-mh mh-mm-uu-dissect-text-parts mm-uu-dissect-text-parts (_handles)
"Emacs 21 and XEmacs don't have this function."
nil)
......
......@@ -205,7 +205,7 @@ See `mh-identity-list'."
(setq mh-identity-local identity))))
;;;###mh-autoload
(defun mh-identity-handler-gpg-identity (field action &optional value)
(defun mh-identity-handler-gpg-identity (_field action &optional value)
"Process header FIELD \":pgg-default-user-id\".
The ACTION is one of `remove' or `add'. If `add', the VALUE is added.
The buffer-local variable `mh-identity-pgg-default-user-id' is set to
......@@ -219,7 +219,7 @@ VALUE when action `add' is selected."
(setq mh-identity-pgg-default-user-id value))))
;;;###mh-autoload
(defun mh-identity-handler-signature (field action &optional value)
(defun mh-identity-handler-signature (_field action &optional value)
"Process header FIELD \":signature\".
The ACTION is one of `remove' or `add'. If `add', the VALUE is
added."
......@@ -250,7 +250,7 @@ added."
"Marker for the end of the attribution verb.")
;;;###mh-autoload
(defun mh-identity-handler-attribution-verb (field action &optional value)
(defun mh-identity-handler-attribution-verb (_field action &optional value)
"Process header FIELD \":attribution-verb\".
The ACTION is one of `remove' or `add'. If `add', the VALUE is
added."
......
......@@ -33,7 +33,6 @@
;;; Code:
(require 'mh-e)
(mh-require-cl)
(defvar mh-inc-spool-map-help nil
"Help text for `mh-inc-spool-map'.")
......@@ -51,13 +50,13 @@
"Make all commands and defines keys for contents of `mh-inc-spool-list'."
(setq mh-inc-spool-map-help nil)
(when mh-inc-spool-list
(loop for elem in mh-inc-spool-list
do (let ((spool (nth 0 elem))
(folder (nth 1 elem))
(key (nth 2 elem)))
(progn
(mh-inc-spool-generator folder spool)
(mh-inc-spool-def-key key folder))))))
(cl-loop for elem in mh-inc-spool-list
do (let ((spool (nth 0 elem))
(folder (nth 1 elem))
(key (nth 2 elem)))
(progn
(mh-inc-spool-generator folder spool)
(mh-inc-spool-def-key key folder))))))
(defalias 'mh-inc-spool-make-no-autoload 'mh-inc-spool-make)
......
......@@ -32,7 +32,6 @@
(require 'mh-e)
(require 'mh-scan)
(mh-require-cl)
;;;###mh-autoload
(defun mh-junk-blacklist (range)
......
......@@ -30,7 +30,6 @@
;;; Code: