summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp/advice.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2012-11-16 13:02:39 -0500
committerStefan Monnier <monnier@iro.umontreal.ca>2012-11-16 13:02:39 -0500
commitdd0c5bbb364c8a7f6c663c7bd93d048206b2e707 (patch)
tree6ca3bd9064c154c6a85f49689f2090b8966795eb /lisp/emacs-lisp/advice.el
parent96e055075d7c73cf189038db1b15f9369888ea41 (diff)
downloademacs-dd0c5bbb364c8a7f6c663c7bd93d048206b2e707.tar.gz
emacs-dd0c5bbb364c8a7f6c663c7bd93d048206b2e707.tar.bz2
emacs-dd0c5bbb364c8a7f6c663c7bd93d048206b2e707.zip
* lisp/emacs-lisp/advice.el (ad-make-advised-definition): Improve last fix.
Diffstat (limited to 'lisp/emacs-lisp/advice.el')
-rw-r--r--lisp/emacs-lisp/advice.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/advice.el b/lisp/emacs-lisp/advice.el
index 60c1a846a79..c2ebb3bbdc6 100644
--- a/lisp/emacs-lisp/advice.el
+++ b/lisp/emacs-lisp/advice.el
@@ -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))