diff options
author | Alan Mackenzie <acm@muc.de> | 2022-01-14 19:06:04 +0000 |
---|---|---|
committer | Alan Mackenzie <acm@muc.de> | 2022-01-14 19:06:04 +0000 |
commit | 57b698f15913385aec7bc9745016b961c0aa5c55 (patch) | |
tree | d4d28817491a96dafa71ef22409087995d65caa2 /lisp/help.el | |
parent | 2128cd8c08da84ab40608ac5db0fecfce733cfad (diff) | |
download | emacs-57b698f15913385aec7bc9745016b961c0aa5c55.tar.gz emacs-57b698f15913385aec7bc9745016b961c0aa5c55.tar.bz2 emacs-57b698f15913385aec7bc9745016b961c0aa5c55.zip |
Commit fixes and enhancements to the scratch/correct-warning-pos branch
No longer strip positions from symbols before each use of a form, instead
relying on the low level C routines to do the right thing. Instead strip them
from miscellaneous places where this is needed. Stip them alson in
`function-put'.
Push forms onto byte-compile-form-stack and pop them "by hand" rather than by
binding the variable at each pushing, so that it will still have its data
after an error has been thrown and caught by a condition case. This gives an
source position to the ensuing error message.
* lisp/emacs-lisp/byte-run.el (byte-run--ssp-seen, byte-run--circular-list-p)
(byte-run--strip-s-p-1, byte-run-strip-symbol-positions): New functions and
variables, which together implement stripping of symbol positions. The latest
(?final) version modifies the argument in place rather than making a copy.
(function-put): Strip symbol positions from all of the arguments before doing
the `put'.
* lisp/emacs-lisp/bytecomp.el (byte-compile--form-stack): has been renamed to
byte-compile-form-stack and moved to macroexp.el.
(byte-compile-initial-macro-environment (eval-and-compile)): Replace
macroexpand-all-toplevel with macroexpand--all-toplevel.
(displaying-byte-compile-warnings): bind byte-compile-form-stack here.
(byte-compile-toplevel-file-form, byte-compile-form): Push the top level form
onto byte-compile-form-stack (whereas formally the variable was bound at each
pushing). Manually pop this from of the variable at the end of the function.
* lisp/emacs-lisp/cl-macs.el (cl-define-compiler-macro): Remove the symbol
stripping.
* lisp/emacs-lisp/comp.el (comp--native-compile): Set max-specpdl-size to at
least 5000 (previously it was 2500). Bind print-symbols-bare to t.
* lisp/emacs-lisp/macroexp.el (byte-compile-form-stack): Definition move here
from bytecomp.el for easier compilation.
(byte-compile-strip-symbol-positions and associated functions): Removed.
(macro--expand-all): push argument FORM onto byte-compile-form-stack at the
start of this function, and pop it off at the end.
(internal-macroexpand-for-load): No longer strip symbol positions. Bind
symbols-with-pos-enabled and print-symbols-bare to t.
* lisp/help.el (help--make-usage): Strip any position from argument ARG.
* src/fns.c (Fput): No longer strip symbol positions from any of the
arguments.
Diffstat (limited to 'lisp/help.el')
-rw-r--r-- | lisp/help.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/help.el b/lisp/help.el index b142cce845c..983f39479cb 100644 --- a/lisp/help.el +++ b/lisp/help.el @@ -2069,7 +2069,7 @@ the same names as used in the original source code, when possible." ((symbolp arg) (let ((name (symbol-name arg))) (cond - ((string-match "\\`&" name) arg) + ((string-match "\\`&" name) (bare-symbol arg)) ((string-match "\\`_." name) (intern (upcase (substring name 1)))) (t (intern (upcase name)))))) |