]> code.delx.au - gnu-emacs/commitdiff
Treat “instead” strings as docstrings
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 31 Aug 2015 07:04:11 +0000 (00:04 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 31 Aug 2015 07:05:31 +0000 (00:05 -0700)
* lisp/emacs-lisp/bytecomp.el (byte-compile-form):
* lisp/emacs-lisp/macroexp.el (macroexp--obsolete-warning):
Substitute quotes in instead strings.

lisp/emacs-lisp/bytecomp.el
lisp/emacs-lisp/macroexp.el

index 8b8b667f596a248f4a8701050453bccf93f05ce1..7182c0b6372dea833b0493db46b0a3a63e1f4cd7 100644 (file)
@@ -2989,7 +2989,9 @@ for symbols generated by the byte compiler itself."
          (byte-compile-warn "‘%s’ is for interactive use only%s"
                             fn
                             (cond ((stringp interactive-only)
-                                   (format "; %s" interactive-only))
+                                   (format "; %s"
+                                           (substitute-command-keys
+                                            interactive-only)))
                                   ((and (symbolp 'interactive-only)
                                         (not (eq interactive-only t)))
                                    (format-message "; use ‘%s’ instead."
index ff359e6096ed7b5b217bc9ecfdcfe46be9b2b92e..6189976e866c2a25f2778c0479b25629ce306f4e 100644 (file)
@@ -149,7 +149,7 @@ and also to avoid outputting the warning during normal execution."
     (format-message
      "‘%s’ is an obsolete %s%s%s" fun type
      (if asof (concat " (as of " asof ")") "")
-     (cond ((stringp instead) (concat "; " instead))
+     (cond ((stringp instead) (concat "; " (substitute-command-keys instead)))
            (instead (format-message "; use ‘%s’ instead." instead))
            (t ".")))))