[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 2ff5cb4cb4 2/6: Make warning about require/autoload while bootstr
From: |
Lars Ingebrigtsen |
Subject: |
master 2ff5cb4cb4 2/6: Make warning about require/autoload while bootstrapping not error out |
Date: |
Fri, 24 Jun 2022 05:04:59 -0400 (EDT) |
branch: master
commit 2ff5cb4cb4420e2b18ea8451ad0b29f1a69bdb6c
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>
Make warning about require/autoload while bootstrapping not error out
* src/fns.c (Frequire):
* src/eval.c (Fautoload_do_load): Avoid further errors while
outputting the error about not being able to autoload/require
while bootstrapping.
---
src/eval.c | 9 +++++++--
src/fns.c | 9 +++++++--
2 files changed, 14 insertions(+), 4 deletions(-)
diff --git a/src/eval.c b/src/eval.c
index 346dff8bdc..141d2546f0 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -2273,8 +2273,13 @@ it defines a macro. */)
/* This is to make sure that loadup.el gives a clear picture
of what files are preloaded and when. */
if (will_dump_p () && !will_bootstrap_p ())
- error ("Attempt to autoload %s while preparing to dump",
- SDATA (SYMBOL_NAME (funname)));
+ {
+ /* Avoid landing here recursively while outputting the
+ backtrace from the error. */
+ gflags.will_dump_ = false;
+ error ("Attempt to autoload %s while preparing to dump",
+ SDATA (SYMBOL_NAME (funname)));
+ }
CHECK_SYMBOL (funname);
diff --git a/src/fns.c b/src/fns.c
index 4a9954ce90..5ee8482d00 100644
--- a/src/fns.c
+++ b/src/fns.c
@@ -3121,8 +3121,13 @@ FILENAME are suppressed. */)
/* This is to make sure that loadup.el gives a clear picture
of what files are preloaded and when. */
if (will_dump_p () && !will_bootstrap_p ())
- error ("(require %s) while preparing to dump",
- SDATA (SYMBOL_NAME (feature)));
+ {
+ /* Avoid landing here recursively while outputting the
+ backtrace from the error. */
+ gflags.will_dump_ = false;
+ error ("(require %s) while preparing to dump",
+ SDATA (SYMBOL_NAME (feature)));
+ }
/* A certain amount of recursive `require' is legitimate,
but if we require the same feature recursively 3 times,
- master updated (c148bfc229 -> e193ea3c34), Lars Ingebrigtsen, 2022/06/24
- master 2ff5cb4cb4 2/6: Make warning about require/autoload while bootstrapping not error out,
Lars Ingebrigtsen <=
- master f2b7525e38 5/6: Preload seq, Lars Ingebrigtsen, 2022/06/24
- master bed9fd41ef 4/6: Allow read-multiple-choice to do long-form answers, Lars Ingebrigtsen, 2022/06/24
- master e193ea3c34 6/6: Allow `kill-buffer' query to save the buffer first, Lars Ingebrigtsen, 2022/06/24
- master bd1f20eea1 1/6: Make debug-early-backtrace more resilient, Lars Ingebrigtsen, 2022/06/24
- master 49910adf87 3/6: Fix cl-generic bootstrap problems, Lars Ingebrigtsen, 2022/06/24