[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 27c93778ef: Fix bug with M-x compile-defun in a defconst/defvar
From: |
Alan Mackenzie |
Subject: |
master 27c93778ef: Fix bug with M-x compile-defun in a defconst/defvar |
Date: |
Wed, 2 Feb 2022 13:04:33 -0500 (EST) |
branch: master
commit 27c93778ef15c887a9d26ba198fddbe322d58284
Author: Alan Mackenzie <acm@muc.de>
Commit: Alan Mackenzie <acm@muc.de>
Fix bug with M-x compile-defun in a defconst/defvar
* lisp/emacs-lisp/bytecomp.el (compile-defun): Have symbols-with-pos-enabled
bound to non-nil when the eval takes place.
---
lisp/emacs-lisp/bytecomp.el | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el
index 9c664ff8fe..ff372151e1 100644
--- a/lisp/emacs-lisp/bytecomp.el
+++ b/lisp/emacs-lisp/bytecomp.el
@@ -2198,20 +2198,20 @@ With argument ARG, insert value in current buffer after
the form."
(save-excursion
(end-of-defun)
(beginning-of-defun)
- (let* ((print-symbols-bare t)
+ (let* ((print-symbols-bare t) ; For the final `message'.
(byte-compile-current-file (current-buffer))
(byte-compile-current-buffer (current-buffer))
(start-read-position (point))
(byte-compile-last-warned-form 'nothing)
+ (symbols-with-pos-enabled t)
(value (eval
- (let ((symbols-with-pos-enabled t))
- (displaying-byte-compile-warnings
- (byte-compile-sexp
- (let ((form (read-positioning-symbols
(current-buffer))))
- (push form byte-compile-form-stack)
- (eval-sexp-add-defvars
- form
- start-read-position)))))
+ (displaying-byte-compile-warnings
+ (byte-compile-sexp
+ (let ((form (read-positioning-symbols (current-buffer))))
+ (push form byte-compile-form-stack)
+ (eval-sexp-add-defvars
+ form
+ start-read-position))))
lexical-binding)))
(cond (arg
(message "Compiling from buffer... done.")
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master 27c93778ef: Fix bug with M-x compile-defun in a defconst/defvar,
Alan Mackenzie <=