diff options
| author | Lars Ingebrigtsen | 2022-06-24 10:45:34 +0200 |
|---|---|---|
| committer | Lars Ingebrigtsen | 2022-06-24 11:04:51 +0200 |
| commit | 2ff5cb4cb4420e2b18ea8451ad0b29f1a69bdb6c (patch) | |
| tree | d22ab16c2fd7c47bff722bc4f2261b7d6824fc1c /src | |
| parent | bd1f20eea199d61a8b1db602392d8e17af624ff2 (diff) | |
| download | emacs-2ff5cb4cb4420e2b18ea8451ad0b29f1a69bdb6c.tar.gz emacs-2ff5cb4cb4420e2b18ea8451ad0b29f1a69bdb6c.zip | |
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.
Diffstat (limited to 'src')
| -rw-r--r-- | src/eval.c | 9 | ||||
| -rw-r--r-- | src/fns.c | 9 |
2 files changed, 14 insertions, 4 deletions
diff --git a/src/eval.c b/src/eval.c index 346dff8bdcc..141d2546f08 100644 --- a/src/eval.c +++ b/src/eval.c | |||
| @@ -2273,8 +2273,13 @@ it defines a macro. */) | |||
| 2273 | /* This is to make sure that loadup.el gives a clear picture | 2273 | /* This is to make sure that loadup.el gives a clear picture |
| 2274 | of what files are preloaded and when. */ | 2274 | of what files are preloaded and when. */ |
| 2275 | if (will_dump_p () && !will_bootstrap_p ()) | 2275 | if (will_dump_p () && !will_bootstrap_p ()) |
| 2276 | error ("Attempt to autoload %s while preparing to dump", | 2276 | { |
| 2277 | SDATA (SYMBOL_NAME (funname))); | 2277 | /* Avoid landing here recursively while outputting the |
| 2278 | backtrace from the error. */ | ||
| 2279 | gflags.will_dump_ = false; | ||
| 2280 | error ("Attempt to autoload %s while preparing to dump", | ||
| 2281 | SDATA (SYMBOL_NAME (funname))); | ||
| 2282 | } | ||
| 2278 | 2283 | ||
| 2279 | CHECK_SYMBOL (funname); | 2284 | CHECK_SYMBOL (funname); |
| 2280 | 2285 | ||
| @@ -3121,8 +3121,13 @@ FILENAME are suppressed. */) | |||
| 3121 | /* This is to make sure that loadup.el gives a clear picture | 3121 | /* This is to make sure that loadup.el gives a clear picture |
| 3122 | of what files are preloaded and when. */ | 3122 | of what files are preloaded and when. */ |
| 3123 | if (will_dump_p () && !will_bootstrap_p ()) | 3123 | if (will_dump_p () && !will_bootstrap_p ()) |
| 3124 | error ("(require %s) while preparing to dump", | 3124 | { |
| 3125 | SDATA (SYMBOL_NAME (feature))); | 3125 | /* Avoid landing here recursively while outputting the |
| 3126 | backtrace from the error. */ | ||
| 3127 | gflags.will_dump_ = false; | ||
| 3128 | error ("(require %s) while preparing to dump", | ||
| 3129 | SDATA (SYMBOL_NAME (feature))); | ||
| 3130 | } | ||
| 3126 | 3131 | ||
| 3127 | /* A certain amount of recursive `require' is legitimate, | 3132 | /* A certain amount of recursive `require' is legitimate, |
| 3128 | but if we require the same feature recursively 3 times, | 3133 | but if we require the same feature recursively 3 times, |