changeset 87253:6df659d50dc9

Add declare-function compatibility definition. Require gnus-sum not just when compiling. (nnvirtual-find-group-art): Declare as a function.
author Glenn Morris <rgm@gnu.org>
date Tue, 11 Dec 2007 05:47:37 +0000
parents a48038ce7d61
children 1d21f80a768f
files lisp/gnus/gnus-cache.el
diffstat 1 files changed, 9 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/gnus/gnus-cache.el	Tue Dec 11 05:46:54 2007 +0000
+++ b/lisp/gnus/gnus-cache.el	Tue Dec 11 05:47:37 2007 +0000
@@ -27,13 +27,18 @@
 
 ;;; Code:
 
+;; For Emacs < 22.2.
+(eval-and-compile
+  (unless (fboundp 'declare-function) (defmacro declare-function (&rest r))))
+
 (eval-when-compile (require 'cl))
 
 (require 'gnus)
+(require 'gnus-sum)
+
 (eval-when-compile
   (unless (fboundp 'gnus-agent-load-alist)
-      (defun gnus-agent-load-alist (group)))
-  (require 'gnus-sum))
+    (defun gnus-agent-load-alist (group))))
 
 (defcustom gnus-cache-active-file
   (expand-file-name "active" gnus-cache-directory)
@@ -91,6 +96,8 @@
 (defvar gnus-cache-active-altered nil)
 (defvar gnus-cache-total-fetched-hashtb nil)
 
+(declare-function nnvirtual-find-group-art "nnvirtual" (group article))
+
 (eval-and-compile
   (autoload 'nnml-generate-nov-databases-directory "nnml")
   (autoload 'nnvirtual-find-group-art "nnvirtual"))