changeset 37056:543952c0704a

(ad-make-advised-definition): Call interactive-form to obtain the interactive spec of subrs.
author Gerd Moellmann <gerd@gnu.org>
date Thu, 29 Mar 2001 14:09:35 +0000
parents 4cb750b910d1
children 5522dea1343b
files lisp/emacs-lisp/advice.el
diffstat 1 files changed, 2 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emacs-lisp/advice.el	Thu Mar 29 14:08:58 2001 +0000
+++ b/lisp/emacs-lisp/advice.el	Thu Mar 29 14:09:35 2001 +0000
@@ -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 @@
 		    ;; 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.