]> git.eshelyaron.com Git - emacs.git/commitdiff
(ad-make-advised-definition): Call
authorGerd Moellmann <gerd@gnu.org>
Thu, 29 Mar 2001 14:11:46 +0000 (14:11 +0000)
committerGerd Moellmann <gerd@gnu.org>
Thu, 29 Mar 2001 14:11:46 +0000 (14:11 +0000)
interactive-form to obtain the interactive spec of subrs.

lisp/ChangeLog
lisp/emacs-lisp/advice.el

index 05ffc2d2bf1b6b09bc84381811729f85f2066560..6801e15190c0ca23688bbd4a220d2fd03f75dbb0 100644 (file)
@@ -1,3 +1,10 @@
+2001-03-29  Gerd Moellmann  <gerd@gnu.org>
+
+       * emacs-lisp/advice.el (ad-make-advised-definition): Call
+       interactive-form to obtain the interactive spec of subrs.
+
+       * subr.el (interactive-form): New function.
+
 2001-03-29  Andre Spiegel  <spiegel@gnu.org>
 
        * vc-sccs.el (vc-sccs-register): Use relative file names.
index 4d32929ee9b6fa288b9649b2cd855ea064ed8a8c..0333c51df643b05fca2f9cd564a4e26cd5599a9d 100644 (file)
@@ -1,6 +1,6 @@
 ;;; advice.el --- an overloading mechanism for Emacs Lisp functions
 
-;; Copyright (C) 1993,1994,2000  Free Software Foundation, Inc.
+;; Copyright (C) 1993,1994,2000, 2001  Free Software Foundation, Inc.
 
 ;; Author: Hans Chalupsky <hans@cs.buffalo.edu>
 ;; Maintainer: FSF
@@ -3072,12 +3072,7 @@ Example: `(ad-map-arglists '(a &rest args) '(w x y z))' will return
                    ;; Otherwise we must have a subr: make it interactive if
                    ;; we have to and initialize required arguments in case
                    ;; it is called interactively:
-                   (orig-interactive-p
-                    (let ((reqargs (car (ad-parse-arglist advised-arglist))))
-                      (if reqargs
-                          (` (interactive
-                              '(, (make-list (length reqargs) nil))))
-                          '(interactive))))))
+                   (orig-interactive-p (interactive-form origdef))))
             (orig-form
              (cond ((or orig-special-form-p orig-macro-p)
                     ;; Special forms and macros will be advised into macros.