summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGlenn Morris <rgm@gnu.org>2018-03-22 21:40:24 -0700
committerGlenn Morris <rgm@gnu.org>2018-03-22 21:40:24 -0700
commitdfea6d5a4aac5fd1679a917c5e84ce17a6c6a3d8 (patch)
treea45928650165acb6e449df72755875da993a7492
parent97b7e58c4d34722e8b0eb73b3ed315fdc9671264 (diff)
downloademacs-dfea6d5a4aac5fd1679a917c5e84ce17a6c6a3d8.tar.gz
emacs-dfea6d5a4aac5fd1679a917c5e84ce17a6c6a3d8.tar.bz2
emacs-dfea6d5a4aac5fd1679a917c5e84ce17a6c6a3d8.zip
Quieten cl-lib related compiler warnings
* lisp/completion.el (cl-set-difference): * lisp/files.el (map-merge-with, map-merge): * lisp/emacs-lisp/radix-tree.el (map-apply): Declare. * lisp/emacs-lisp/thunk.el: Load cl-lib at run-time, not cl-macs at compile. * lisp/gnus/gnus-group.el: Load cl-lib at run-time, not cl at compile. * lisp/emacs-lisp/checkdoc.el, lisp/emacs-lisp/package.el * lisp/gnus/gnus-sum.el, lisp/gnus/message.el, lisp/net/shr.el: Load cl-lib at run-time. * lisp/gnus/mml-sec.el (mml-signencrypt-style) (mml-secure-cust-record-keys): Replace cl with cl-lib, and load it at run-time. * lisp/cedet/ede/linux.el, lisp/vc/vc-hg.el: Reorder requires.
-rw-r--r--lisp/cedet/ede/linux.el3
-rw-r--r--lisp/completion.el2
-rw-r--r--lisp/emacs-lisp/checkdoc.el2
-rw-r--r--lisp/emacs-lisp/package.el2
-rw-r--r--lisp/emacs-lisp/radix-tree.el2
-rw-r--r--lisp/emacs-lisp/thunk.el2
-rw-r--r--lisp/files.el3
-rw-r--r--lisp/gnus/gnus-group.el7
-rw-r--r--lisp/gnus/gnus-sum.el2
-rw-r--r--lisp/gnus/message.el3
-rw-r--r--lisp/gnus/mml-sec.el8
-rw-r--r--lisp/net/shr.el2
-rw-r--r--lisp/vc/vc-hg.el4
13 files changed, 23 insertions, 19 deletions
diff --git a/lisp/cedet/ede/linux.el b/lisp/cedet/ede/linux.el
index 862a9e597aa..84ce7ee6ef9 100644
--- a/lisp/cedet/ede/linux.el
+++ b/lisp/cedet/ede/linux.el
@@ -32,10 +32,9 @@
;; * Add texinfo lookup options.
;; * Add website
-(eval-when-compile (require 'cl))
-
(require 'ede)
(require 'ede/make)
+(eval-when-compile (require 'cl))
(declare-function semanticdb-file-table-object "semantic/db")
(declare-function semanticdb-needs-refresh-p "semantic/db")
diff --git a/lisp/completion.el b/lisp/completion.el
index 9666ca60b04..ff942940861 100644
--- a/lisp/completion.el
+++ b/lisp/completion.el
@@ -2225,6 +2225,8 @@ TYPE is the type of the wrapper to be added. Can be :before or :under."
(modify-syntax-entry char "_" table))
table))
+(declare-function cl-set-difference "cl-seq" (cl-list1 cl-list2 &rest cl-keys))
+
(defun completion-lisp-mode-hook ()
(require 'cl-lib)
(setq completion-syntax-table completion-lisp-syntax-table)
diff --git a/lisp/emacs-lisp/checkdoc.el b/lisp/emacs-lisp/checkdoc.el
index 59b7831fb58..300a3908c14 100644
--- a/lisp/emacs-lisp/checkdoc.el
+++ b/lisp/emacs-lisp/checkdoc.el
@@ -171,7 +171,7 @@
(defvar checkdoc-version "0.6.1"
"Release version of checkdoc you are currently running.")
-(eval-when-compile (require 'cl-lib))
+(require 'cl-lib)
(require 'help-mode) ;; for help-xref-info-regexp
(require 'thingatpt) ;; for handy thing-at-point-looking-at
diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el
index 1edc06d024d..67533679b99 100644
--- a/lisp/emacs-lisp/package.el
+++ b/lisp/emacs-lisp/package.el
@@ -143,8 +143,8 @@
;;; Code:
+(require 'cl-lib)
(eval-when-compile (require 'subr-x))
-(eval-when-compile (require 'cl-lib))
(eval-when-compile (require 'epg)) ;For setf accessors.
(require 'seq)
diff --git a/lisp/emacs-lisp/radix-tree.el b/lisp/emacs-lisp/radix-tree.el
index 8946560d3ba..e3c5800efb1 100644
--- a/lisp/emacs-lisp/radix-tree.el
+++ b/lisp/emacs-lisp/radix-tree.el
@@ -235,6 +235,8 @@ PREFIX is only used internally."
(radix-tree-iter-mappings tree (lambda (_k _v) (setq i (1+ i))))
i))
+(declare-function map-apply "map" (function map))
+
(defun radix-tree-from-map (map)
;; Aka (cl-defmethod map-into (map (type (eql radix-tree)))) ...)
(require 'map)
diff --git a/lisp/emacs-lisp/thunk.el b/lisp/emacs-lisp/thunk.el
index bbdd7d61f6c..823d4960aa0 100644
--- a/lisp/emacs-lisp/thunk.el
+++ b/lisp/emacs-lisp/thunk.el
@@ -48,7 +48,7 @@
;;; Code:
-(eval-when-compile (require 'cl-macs))
+(require 'cl-lib)
(defmacro thunk-delay (&rest body)
"Delay the evaluation of BODY."
diff --git a/lisp/files.el b/lisp/files.el
index 46a105a36f0..bad2639fa62 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -4012,6 +4012,9 @@ This function returns either:
;; No cache entry.
locals-dir)))
+(declare-function map-merge-with "map" (type function &rest maps))
+(declare-function map-merge "map" (type &rest maps))
+
(defun dir-locals-read-from-dir (dir)
"Load all variables files in DIR and register a new class and instance.
DIR is the absolute name of a directory which must contain at
diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el
index 3e655cc56cd..4dd5fec6df3 100644
--- a/lisp/gnus/gnus-group.el
+++ b/lisp/gnus/gnus-group.el
@@ -24,10 +24,7 @@
;;; Code:
-(eval-when-compile
- (require 'cl))
-(defvar tool-bar-mode)
-
+(require 'cl-lib)
(require 'gnus)
(require 'gnus-start)
(require 'nnmail)
@@ -46,6 +43,8 @@
(unless (boundp 'gnus-cache-active-hashtb)
(defvar gnus-cache-active-hashtb nil)))
+(defvar tool-bar-mode)
+
(autoload 'gnus-agent-total-fetched-for "gnus-agent")
(autoload 'gnus-cache-total-fetched-for "gnus-cache")
diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el
index 468f2b195e2..a5756b1a202 100644
--- a/lisp/gnus/gnus-sum.el
+++ b/lisp/gnus/gnus-sum.el
@@ -24,7 +24,7 @@
;;; Code:
-(eval-when-compile (require 'cl))
+(require 'cl-lib)
(defvar tool-bar-mode)
(defvar gnus-tmp-header)
diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el
index e452c80e262..37b994de99c 100644
--- a/lisp/gnus/message.el
+++ b/lisp/gnus/message.el
@@ -28,8 +28,7 @@
;;; Code:
-(eval-when-compile (require 'cl-lib))
-
+(require 'cl-lib)
(require 'mailheader)
(require 'gmm-utils)
(require 'mail-utils)
diff --git a/lisp/gnus/mml-sec.el b/lisp/gnus/mml-sec.el
index dc10763da86..9a64853edf6 100644
--- a/lisp/gnus/mml-sec.el
+++ b/lisp/gnus/mml-sec.el
@@ -23,7 +23,7 @@
;;; Code:
-(eval-when-compile (require 'cl))
+(require 'cl-lib)
(require 'gnus-util)
(require 'epg)
@@ -167,9 +167,9 @@ You can also customize or set `mml-signencrypt-style-alist' instead."
(if (or (eq style 'separate)
(eq style 'combined))
;; valid style setting?
- (setf (second style-item) style)
+ (setf (cadr style-item) style)
;; otherwise, just return the current value
- (second style-item))
+ (cadr style-item))
(message "Warning, attempt to set invalid signencrypt style"))))
;;; Security functions
@@ -554,7 +554,7 @@ customized in this variable."
"For CONTEXT, USAGE, and NAME record fingerprint(s) of KEYS.
If optional SAVE is not nil, save customized fingerprints.
Return keys."
- (assert keys)
+ (cl-assert keys)
(let* ((usage-prefs (mml-secure-cust-usage-lookup context usage))
(curr-fprs (cdr (assoc name (cdr usage-prefs))))
(key-fprs (mapcar 'mml-secure-fingerprint keys))
diff --git a/lisp/net/shr.el b/lisp/net/shr.el
index a6b8693dd74..69063abf033 100644
--- a/lisp/net/shr.el
+++ b/lisp/net/shr.el
@@ -30,7 +30,7 @@
;;; Code:
-(eval-when-compile (require 'cl-lib))
+(require 'cl-lib)
(eval-when-compile (require 'url)) ;For url-filename's setf handler.
(require 'browse-url)
(eval-when-compile (require 'subr-x))
diff --git a/lisp/vc/vc-hg.el b/lisp/vc/vc-hg.el
index ad817fd9b9c..9dafaef7aaf 100644
--- a/lisp/vc/vc-hg.el
+++ b/lisp/vc/vc-hg.el
@@ -101,12 +101,12 @@
;;; Code:
+(require 'cl-lib)
+
(eval-when-compile
(require 'vc)
(require 'vc-dir))
-(require 'cl-lib)
-
(declare-function vc-compilation-mode "vc-dispatcher" (backend))
;;; Customization options