emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/cus-edit.el


From: Richard M. Stallman
Subject: [Emacs-diffs] Changes to emacs/lisp/cus-edit.el
Date: Tue, 27 Nov 2001 00:25:55 -0500

Index: emacs/lisp/cus-edit.el
diff -u emacs/lisp/cus-edit.el:1.137 emacs/lisp/cus-edit.el:1.138
--- emacs/lisp/cus-edit.el:1.137        Thu Nov  8 04:57:20 2001
+++ emacs/lisp/cus-edit.el      Tue Nov 27 00:25:55 2001
@@ -1832,14 +1832,22 @@
              ((and (boundp 'preloaded-file-list)
                    (member load preloaded-file-list)))
              ((assoc load load-history))
-             ((assoc (locate-library load) load-history))
+             ;; This was just (assoc (locate-library load) load-history)
+             ;; but has been optimized not to load locate-library
+             ;; if not necessary.
+             ((let (found (regexp (regexp-quote load)))
+                (dolist (loaded load-history)
+                  (and (string-match regexp (car loaded))
+                       (eq (locate-library load) (car loaded))
+                       (setq found t)))
+                found))
+             ;; Without this, we would load cus-edit recursively.
+             ;; We are still loading it when we call this,
+             ;; and it is not in load-history yet.
+             ((equal load "cus-edit"))
              (t
               (condition-case nil
-                  ;; Without this, we would load cus-edit recursively.
-                  ;; We are still loading it when we call this,
-                  ;; and it is not in load-history yet.
-                  (or (equal load "cus-edit")
-                      (load-library load))
+                  (load-library load)
                 (error nil))))))))
 
 (defun custom-load-widget (widget)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]