[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size duri
From: |
Juanma Barranquero |
Subject: |
bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap |
Date: |
Sun, 16 Jun 2019 07:57:20 +0200 |
> Well, does the same command fails in the same way when invoked from
> the command line?
Once I remove the .elc files, any invocation of
./temacs --batch
(with or without explicitly loading loadup.el or passing the --temacs
arg) produces the same error, because it automatically loads
loadup.el.
> If so, just invoke it with the appropriate --eval
> argument that increases the value of max-specpdl-size.
AFAICS, setting max-specpdl-size in an --eval doesn't work, because
temacs loads loadup.el before processing the --eval. If I instrument
loadup.el to show its value, I get:
$ ./temacs --eval "(setq max-specpdl-size 1450)" --batch
Loading loadup.el (source)...
> (loadup.el) max-specpdl-size = 1300
dump mode: nil
Obviously, the problem disappears if I bind max-specpdl-size to a
bigger value around the load of cl-generic, or if I set it explicitly
in the conditional code at the beginning of loadup.el that also sets
max-lisp-eval-depth
(if (or (member dump-mode '("bootstrap" "pbootstrap"))
;; FIXME this is irritatingly fragile.
(and (stringp (nth 4 command-line-args))
(string-match "^unidata-gen\\(\\.elc?\\)?$"
(nth 4 command-line-args)))
(member (nth 7 command-line-args) '("unidata-gen-file"
"unidata-gen-charprop"))
(null dump-mode))
(progn
[...etc etc...]
(setq max-specpdl-size 1450) ;;; <=== THIS WORKS
;; During bootstrapping the byte-compiler is run interpreted
;; when compiling itself, which uses a lot more stack
;; than usual.
(setq max-lisp-eval-depth 2200)))
I wonder if it wouldn't just make sense to borrow the same trick
loadup.el uses with pcase.el to disable eager macroexpansion, i.e.,
something like
diff --git i/lisp/loadup.el w/lisp/loadup.el
index 67e8aa7d40..9f08b19043 100644
--- i/lisp/loadup.el
+++ w/lisp/loadup.el
@@ -246,7 +246,10 @@
(load "language/cham")
(load "indent")
-(load "emacs-lisp/cl-generic")
+(if (byte-code-function-p (symbol-function 'macroexpand-all))
+ (load "emacs-lisp/cl-generic")
+ (let ((macroexp--pending-eager-loads '(skip)))
+ (load "emacs-lisp/cl-generic")))
(load "frame")
(load "startup")
(load "term/tty-colors")
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Juanma Barranquero, 2019/06/14
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Eli Zaretskii, 2019/06/15
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Juanma Barranquero, 2019/06/15
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Eli Zaretskii, 2019/06/15
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap,
Juanma Barranquero <=
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Juanma Barranquero, 2019/06/16
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Eli Zaretskii, 2019/06/16
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Juanma Barranquero, 2019/06/16
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Eli Zaretskii, 2019/06/16
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Stefan Monnier, 2019/06/16
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Juanma Barranquero, 2019/06/16
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Juanma Barranquero, 2019/06/16
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Juanma Barranquero, 2019/06/27
- bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Stefan Monnier, 2019/06/16
bug#36216: 27.0.50; Variable binding depth exceeds max-specpld-size during bootstrap, Lars Ingebrigtsen, 2019/06/15