* gnus.el: Remove gnus-functionp throughout.
authorLars Magne Ingebrigtsen <larsi@gnus.org>
Sun, 27 Apr 2003 04:30:32 +0000 (04:30 +0000)
committerLars Magne Ingebrigtsen <larsi@gnus.org>
Sun, 27 Apr 2003 04:30:32 +0000 (04:30 +0000)
* gnus-util.el (gnus-functionp): Removed.

* gnus-msg.el (gnus-summary-wide-reply-with-original): Doc fix.

lisp/ChangeLog
lisp/gnus-agent.el
lisp/gnus-art.el
lisp/gnus-kill.el
lisp/gnus-msg.el
lisp/gnus-score.el
lisp/gnus-start.el
lisp/gnus-sum.el
lisp/gnus-util.el
lisp/gnus-win.el
lisp/mm-view.el

index 93db33f..e0f1d36 100644 (file)
@@ -1,5 +1,11 @@
 2003-04-27  Lars Magne Ingebrigtsen  <larsi@gnus.org>
 
+       * gnus.el: Remove gnus-functionp throughout.
+
+       * gnus-util.el (gnus-functionp): Removed.
+
+       * gnus-msg.el (gnus-summary-wide-reply-with-original): Doc fix. 
+
        * message.el (message-required-headers): Add In-Reply-To.
 
 2003-04-27  Marshall T. Vandegrift  <vandem2@rpi.edu>
index 366237e..5b3f965 100644 (file)
@@ -2370,7 +2370,7 @@ The following commands are available:
   (cond
    ;; Functions are just returned as is.
    ((or (symbolp predicate)
-       (gnus-functionp predicate))
+       (functionp predicate))
     `(,(or (cdr (assq predicate gnus-category-predicate-alist))
           predicate)))
    ;; More complex predicate.
@@ -2407,7 +2407,7 @@ return only unread articles."
          nil)
         ((not function)
          nil)
-        ((gnus-functionp function)
+        ((functionp function)
          'ignore)
         ((memq (car function) '(or and not))
          (apply (car function)
index d455089..b6b592c 100644 (file)
@@ -2035,7 +2035,7 @@ unfolded."
            ;; We display the face.
            (if (symbolp gnus-article-x-face-command)
                ;; The command is a lisp function, so we call it.
-               (if (gnus-functionp gnus-article-x-face-command)
+               (if (functionp gnus-article-x-face-command)
                    (funcall gnus-article-x-face-command face)
                  (error "%s is not a function" gnus-article-x-face-command))
              ;; The command is a string, so we interpret the command
@@ -2305,7 +2305,7 @@ If READ-CHARSET, ask for a coding system."
            (when entry
              (setq func (cdr entry)))
            (cond
-            ((gnus-functionp func)
+            ((functionp func)
              (funcall func))
             (t
              (apply (car func) (cdr func))))))))))
@@ -2579,7 +2579,7 @@ Point is left at the beginning of the narrowed-to region."
                       (< (- (point-max) (point)) limit))
                  (and (floatp limit)
                       (< (count-lines (point) (point-max)) limit))
-                 (and (gnus-functionp limit)
+                 (and (functionp limit)
                       (funcall limit))
                  (and (stringp limit)
                       (not (re-search-forward limit nil t))))
@@ -2781,7 +2781,7 @@ should replace the \"Date:\" one, or should be added below it."
                                  gnus-article-time-format)
                              (error nil))
                            gnus-article-time-format)))
-           (if (gnus-functionp format)
+           (if (functionp format)
                (funcall format time)
              (concat "Date: " (format-time-string format time)))))
         ;; ISO 8601.
index 41965a9..b7329bd 100644 (file)
@@ -598,7 +598,7 @@ COMMAND must be a lisp expression or a string representing a key sequence."
                     (setq did-kill (string-match regexp value)))
                   (cond ((stringp form) ;Keyboard macro.
                          (execute-kbd-macro form))
-                        ((gnus-functionp form)
+                        ((functionp form)
                          (funcall form))
                         (t
                          (eval form)))))
@@ -617,7 +617,7 @@ COMMAND must be a lisp expression or a string representing a key sequence."
                    (setq did-kill (re-search-forward regexp nil t)))
              (cond ((stringp form)     ;Keyboard macro.
                     (execute-kbd-macro form))
-                   ((gnus-functionp form)
+                   ((functionp form)
                     (funcall form))
                    (t
                     (eval form)))))))
index 2bd4a12..5f90549 100644 (file)
@@ -512,7 +512,7 @@ Gcc: header for archiving purposes."
        (while (setq elem (pop alist))
          (when (or (and (stringp (car elem))
                         (string-match (car elem) group))
-                   (and (gnus-functionp (car elem))
+                   (and (functionp (car elem))
                         (funcall (car elem) group))
                    (and (symbolp (car elem))
                         (symbol-value (car elem))))
@@ -1204,7 +1204,8 @@ automatically."
 
 (defun gnus-summary-wide-reply-with-original (n)
   "Start composing a wide reply mail to the current message.
-The original article will be yanked."
+The original article will be yanked.
+Uses the process/prefix convention."
   (interactive "P")
   (gnus-summary-reply-with-original n t))
 
@@ -1705,7 +1706,7 @@ this is a reply."
       (message-narrow-to-headers)
       (let* ((group gnus-outgoing-message-group)
             (gcc (cond
-                  ((gnus-functionp group)
+                  ((functionp group)
                    (funcall group))
                   ((or (stringp group) (list group))
                    group))))
@@ -1746,7 +1747,7 @@ this is a reply."
           ((and (listp var) (stringp (car var)))
            ;; A list of groups.
            var)
-          ((gnus-functionp var)
+          ((functionp var)
            ;; A function.
            (funcall var group))
           (t
@@ -1759,7 +1760,7 @@ this is a reply."
                                 ;; Regexp.
                                 (when (string-match (caar var) group)
                                   (cdar var)))
-                               ((gnus-functionp (car var))
+                               ((functionp (car var))
                                 ;; Function.
                                 (funcall (car var) group))
                                (t
@@ -1844,9 +1845,9 @@ this is a reply."
                         (and header
                              (string-match (pop style) header))))))
               ((or (symbolp match)
-                   (gnus-functionp match))
+                   (functionp match))
                (cond
-                ((gnus-functionp match)
+                ((functionp match)
                  ;; Function to be called.
                  (funcall match))
                 ((boundp match)
@@ -1884,8 +1885,8 @@ this is a reply."
                   ((stringp value)
                    value)
                   ((or (symbolp value)
-                       (gnus-functionp value))
-                   (cond ((gnus-functionp value)
+                       (functionp value))
+                   (cond ((functionp value)
                           (funcall value))
                          ((boundp value)
                           (symbol-value value))))
index 3b37a0f..b2188ed 100644 (file)
@@ -2776,7 +2776,7 @@ The list is determined from the variable `gnus-score-file-alist'."
       ;; Go through all the functions for finding score files (or actual
       ;; scores) and add them to a list.
       (while funcs
-       (when (gnus-functionp (car funcs))
+       (when (functionp (car funcs))
          (setq score-files
                (append score-files
                        (nreverse (funcall (car funcs) group)))))
@@ -2879,7 +2879,7 @@ If ADAPT, return the home adaptive file instead."
             ((stringp elem)
              elem)
             ;; Function.
-            ((gnus-functionp elem)
+            ((functionp elem)
              (funcall elem group))
             ;; Regexp-file cons.
             ((consp elem)
index 65b6241..8649ba7 100644 (file)
@@ -1013,7 +1013,7 @@ If LEVEL is non-nil, the news will be set up at level LEVEL."
   "Call METHOD to subscribe GROUP.
 If no function returns `non-nil', call `gnus-subscribe-zombies'."
   (unless (cond
-          ((gnus-functionp method)
+          ((functionp method)
            (funcall method group))
           ((listp method)
            (catch 'found
index 93372e0..456125b 100644 (file)
@@ -3616,7 +3616,7 @@ If NO-DISPLAY, don't generate a summary buffer."
    ((eq gnus-auto-select-subject 'first)
     ;; Do nothing.
     )
-   ((gnus-functionp gnus-auto-select-subject)
+   ((functionp gnus-auto-select-subject)
     (funcall gnus-auto-select-subject))))
 
 (defun gnus-summary-prepare ()
@@ -8541,8 +8541,8 @@ If ARG (the prefix) is a number, show the article with the charset
 defined in `gnus-summary-show-article-charset-alist', or the charset
 input.
 If ARG (the prefix) is non-nil and not a number, show the raw article
-without any article massaging functions being run.  Normally, the key strokes
-are `C-u g'."
+without any article massaging functions being run.  Normally, the key
+strokes are `C-u g'."
   (interactive "P")
   (cond
    ((numberp arg)
@@ -10397,7 +10397,7 @@ Returns nil if no thread was there to be shown."
             gnus-thread-hide-subtree)
     (gnus-summary-hide-all-threads
      (if (or (consp gnus-thread-hide-subtree)
-            (gnus-functionp gnus-thread-hide-subtree))
+            (functionp gnus-thread-hide-subtree))
         (gnus-make-predicate gnus-thread-hide-subtree)
        nil))))
 
@@ -10813,7 +10813,7 @@ save those articles instead."
                    ;; Regular expression.
                    (ignore-errors
                      (re-search-forward match nil t)))
-                  ((gnus-functionp match)
+                  ((functionp match)
                    ;; Function.
                    (save-restriction
                      (widen)
index 69d029e..f2d399d 100644 (file)
       (substring str 0 width)
     str))
 
-;; Fixme: This is incomplete, but why not just use functionp?  In
-;; fact, that is used in various places.
-(defsubst gnus-functionp (form)
-  "Return non-nil if FORM is funcallable."
-  (or (and (symbolp form) (fboundp form))
-      (and (listp form) (eq (car form) 'lambda))
-      (byte-code-function-p form)))
-
 (defsubst gnus-goto-char (point)
   (and point (goto-char point)))
 
@@ -591,7 +583,7 @@ If N, return the Nth ancestor instead."
   "Return a composite sort condition based on the functions in FUNC."
   (cond
    ;; Just a simple function.
-   ((gnus-functionp funs) funs)
+   ((functionp funs) funs)
    ;; No functions at all.
    ((null funs) funs)
    ;; A list of functions.
@@ -616,7 +608,7 @@ If N, return the Nth ancestor instead."
        (setq function (cadr function)
              first 't2
              last 't1))
-       ((gnus-functionp function)
+       ((functionp function)
        ;; Do nothing.
        )
        (t
index 71d3dba..e17f2a8 100644 (file)
@@ -305,7 +305,7 @@ See the Gnus manual for an explanation of the syntax used.")
     ;; The SPLIT might be something that is to be evaled to
     ;; return a new SPLIT.
     (while (and (not (assq (car split) gnus-window-to-buffer))
-               (gnus-functionp (car split)))
+               (functionp (car split)))
       (setq split (eval split)))
     (let* ((type (car split))
           (subs (cddr split))
@@ -368,7 +368,7 @@ See the Gnus manual for an explanation of the syntax used.")
          (while subs
            (setq sub (append (pop subs) nil))
            (while (and (not (assq (car sub) gnus-window-to-buffer))
-                       (gnus-functionp (car sub)))
+                       (functionp (car sub)))
              (setq sub (eval sub)))
            (when sub
              (push sub comp-subs)
@@ -507,7 +507,7 @@ should have point."
       ;; The SPLIT might be something that is to be evaled to
       ;; return a new SPLIT.
       (while (and (not (assq (car split) gnus-window-to-buffer))
-                 (gnus-functionp (car split)))
+                 (functionp (car split)))
        (setq split (eval split)))
 
       (setq type (elt split 0))
index 47daf7c..05c4df8 100644 (file)
@@ -327,7 +327,7 @@ map.")))
     (if entry
        (setq func (cdr entry)))
     (cond
-     ((gnus-functionp func)
+     ((functionp func)
       (funcall func handle))
      (t
       (apply (car func) handle (cdr func))))))