Mercurial > emacs
changeset 38336:d5f3a4fa3bc5
(ad-make-advised-definition): If the
original definition has an interactive form, but is Elp
instrumented, use the interactive form of the function called by
elp-wrapper.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Mon, 09 Jul 2001 13:06:11 +0000 |
parents | 3cbf1d961d08 |
children | e861bf91c070 |
files | lisp/emacs-lisp/advice.el |
diffstat | 1 files changed, 6 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/emacs-lisp/advice.el Mon Jul 09 12:14:45 2001 +0000 +++ b/lisp/emacs-lisp/advice.el Mon Jul 09 13:06:11 2001 +0000 @@ -3068,11 +3068,15 @@ (interactive-form (cond (orig-macro-p nil) (advised-interactive-form) - ((ad-interactive-form origdef)) + ((ad-interactive-form origdef) + (if (and (symbolp function) (get function 'elp-info)) + (interactive-form (aref (get function 'elp-info) 2)) + (ad-interactive-form origdef))) ;; 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 (interactive-form origdef)))) + (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.