[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
feature/android d04731b5885 2/2: Update Android port
From: |
Po Lu |
Subject: |
feature/android d04731b5885 2/2: Update Android port |
Date: |
Wed, 15 Mar 2023 21:40:25 -0400 (EDT) |
branch: feature/android
commit d04731b5885957150b54efaa40fdf712b30170ff
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>
Update Android port
* lisp/loadup.el (current-load-list): Set to empty load list
after startup.
* src/lread.c (build_load_history): Revert earlier changes.
---
lisp/loadup.el | 7 +++++++
src/lread.c | 14 +++-----------
2 files changed, 10 insertions(+), 11 deletions(-)
diff --git a/lisp/loadup.el b/lisp/loadup.el
index 47565f809af..15267cca3be 100644
--- a/lisp/loadup.el
+++ b/lisp/loadup.el
@@ -666,6 +666,13 @@ lost after dumping")))
(setq load-file-name nil)
(eval top-level t)
+;; loadup.el is loaded at startup, but clobbers current-load-list.
+;; Set current-load-list to a list containing no definitions and only
+;; its name, to prevent invalid entries from ending up in
+;; Vload_history when running temacs interactively.
+
+(setq current-load-list (list "loadup.el"))
+
;; Local Variables:
;; no-byte-compile: t
diff --git a/src/lread.c b/src/lread.c
index c29c7ede6ac..fe48e614393 100644
--- a/src/lread.c
+++ b/src/lread.c
@@ -2317,7 +2317,7 @@ static void
build_load_history (Lisp_Object filename, bool entire)
{
Lisp_Object tail, prev, newelt;
- Lisp_Object tem, tem2, association;
+ Lisp_Object tem, tem2;
bool foundit = 0;
tail = Vload_history;
@@ -2366,16 +2366,8 @@ build_load_history (Lisp_Object filename, bool entire)
front of load-history, the most-recently-loaded position. Also
do this if we didn't find an existing member for the file. */
if (entire || !foundit)
- {
- association = Fnreverse (Vcurrent_load_list);
-
- if (!NILP (association) && STRINGP (XCAR (association)))
- /* readevalloop can be called with SOURCENAME set to some
- nonsense value, meaning the car of ASSOCIATION will be nil
- (or worse something else), leading to an invalid
- Vload_history. Ignore such invalid entries. */
- Vload_history = Fcons (association, Vload_history);
- }
+ Vload_history = Fcons (Fnreverse (Vcurrent_load_list),
+ Vload_history);
}
static void