* gnus-art.el (gnus-article-browse-html-parts): Decode CTE.
[gnus] / lisp / pgg.el
index 74b6ed7..2691197 100644 (file)
 ;;;
 
 (eval-when-compile
-  (unless (featurep 'xemacs)
-    (defalias 'pgg-run-at-time 'run-at-time)
-    (defalias 'pgg-cancel-timer 'cancel-timer))
-
-  (when (featurep 'xemacs)
-    (defmacro pgg-run-at-time-1 (time repeat function args)
+  ;; Define it as a null macro for Emacs in order to suppress a byte
+  ;; compile warning that Emacs 21 issues.
+  (defmacro pgg-run-at-time-1 (time repeat function args)
+    (when (featurep 'xemacs)
       (if (condition-case nil
              (let ((delete-itimer 'delete-itimer)
                    (itimer-driver-start 'itimer-driver-start)
                        itimer
                        (append (list itimer function) args)))))
                 1e-9 (if time (max time 1e-9) 1e-9)
-                nil t itimers ,repeat ,function ,args))))
+                nil t itimers ,repeat ,function ,args))))))
 
-    (defun pgg-run-at-time (time repeat function &rest args)
-      "Emulating function run as `run-at-time'.
+(eval-and-compile
+  (if (featurep 'xemacs)
+      (progn
+       (defun pgg-run-at-time (time repeat function &rest args)
+         "Emulating function run as `run-at-time'.
 TIME should be nil meaning now, or a number of seconds from now.
 Return an itimer object which can be used in either `delete-itimer'
 or `cancel-timer'."
-      (pgg-run-at-time-1 time repeat function args))
-    (defun pgg-cancel-timer (timer)
-      "Emulate cancel-timer for xemacs."
-      (let ((delete-itimer 'delete-itimer))
-        (funcall delete-itimer timer)))
-    ))
+         (pgg-run-at-time-1 time repeat function args))
+       (defun pgg-cancel-timer (timer)
+         "Emulate cancel-timer for xemacs."
+         (let ((delete-itimer 'delete-itimer))
+           (funcall delete-itimer timer))))
+    (defalias 'pgg-run-at-time 'run-at-time)
+    (defalias 'pgg-cancel-timer 'cancel-timer)))
 
 (defun pgg-invoke (func scheme &rest args)
   (progn