diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index 52bc20af173..edfd9491a2f 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el @@ -5141,7 +5141,8 @@ binding slots have been popped." (when (stringp doc) (setq rest (byte-compile--list-with-n rest 0 - (byte-compile--docstring doc (nth 0 form) name))))) + (byte-compile--docstring doc (nth 0 form) name))) + (setq form (nconc (take 3 form) rest)))) (pcase-let* ;; `macro' is non-nil if it defines a macro. ;; `fun' is the function part of `arg' (defaults to `arg').