diff options
author | Glenn Morris <rgm@gnu.org> | 2013-01-02 16:43:46 -0800 |
---|---|---|
committer | Glenn Morris <rgm@gnu.org> | 2013-01-02 16:43:46 -0800 |
commit | ad235a8b88e353d6e51dafc62d020d8ff647857f (patch) | |
tree | a7748ee7f41afe1909df1e9282ebb8219d34b6e5 /lisp/emacs-lisp | |
parent | d8fb8cce84b923a3289b69549e30958710ac3ebb (diff) | |
download | emacs-ad235a8b88e353d6e51dafc62d020d8ff647857f.tar.gz emacs-ad235a8b88e353d6e51dafc62d020d8ff647857f.tar.bz2 emacs-ad235a8b88e353d6e51dafc62d020d8ff647857f.zip |
defun fix for cl declarations + interactive forms
* lisp/emacs-lisp/byte-run.el (defun):
Place cl declarations after any interactive spec.
Fixes: debbugs:13265
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r-- | lisp/emacs-lisp/byte-run.el | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/byte-run.el b/lisp/emacs-lisp/byte-run.el index e3179a66070..7322c0fbe6f 100644 --- a/lisp/emacs-lisp/byte-run.el +++ b/lisp/emacs-lisp/byte-run.el @@ -195,7 +195,13 @@ The return value is undefined. (memq (car x) ;C.f. cl-do-proclaim. '(special inline notinline optimize warn))) (push (list 'declare x) - (if (stringp docstring) (cdr body) body)) + (if (stringp docstring) + (if (eq (car-safe (cadr body)) 'interactive) + (cddr body) + (cdr body)) + (if (eq (car-safe (car body)) 'interactive) + (cdr body) + body))) nil) (t (message "Warning: Unknown defun property `%S' in %S" (car x) name))))) |