1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-03 10:31:37 -08:00

* lisp/emacs-lisp/advice.el (ad-make-advised-definition): Improve last fix.

This commit is contained in:
Stefan Monnier 2012-11-16 13:02:39 -05:00
parent 96e055075d
commit dd0c5bbb36
3 changed files with 12 additions and 1 deletions

View file

@ -2596,7 +2596,9 @@ in any of these classes."
(ad-has-redefining-advice function))
(let* ((origdef (ad-real-orig-definition function))
;; Construct the individual pieces that we need for assembly:
(orig-arglist (and origdef (ad-arglist origdef)))
(orig-arglist (let ((args (ad-arglist origdef)))
;; The arglist may still be unknown.
(if (listp args) args '(&rest args))))
(advised-arglist (or (ad-advised-arglist function)
orig-arglist))
(interactive-form (ad-advised-interactive-form function))