emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master bc5d96a 1/3: Drop docstrings from cl-defsubst produ


From: Noam Postavsky
Subject: [Emacs-diffs] master bc5d96a 1/3: Drop docstrings from cl-defsubst produced inline bodies (Bug#27748)
Date: Wed, 30 Aug 2017 20:42:00 -0400 (EDT)

branch: master
commit bc5d96a0b2a1dccf7eeeec459e40d21b54c977f4
Author: Noam Postavsky <address@hidden>
Commit: Noam Postavsky <address@hidden>

    Drop docstrings from cl-defsubst produced inline bodies (Bug#27748)
    
    * lisp/emacs-lisp/cl-macs.el (cl-defsubst): Use macroexp-parse-progn
    to drop the docstring.  Add a simple docstring to the compiler-macro.
---
 lisp/emacs-lisp/cl-macs.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index b1ada00..20a956b 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -2503,8 +2503,9 @@ The function's arguments should be treated as immutable.
              ,(if (memq '&key args)
                   `(&whole cl-whole &cl-quote ,@args)
                 (cons '&cl-quote args))
+             ,(format "compiler-macro for inlining `%s'." name)
              (cl--defsubst-expand
-              ',argns '(cl-block ,name ,@body)
+              ',argns '(cl-block ,name ,@(cdr (macroexp-parse-body body)))
               ;; We used to pass `simple' as
               ;; (not (or unsafe (cl-expr-access-order pbody argns)))
               ;; But this is much too simplistic since it



reply via email to

[Prev in Thread] Current Thread [Next in Thread]