summaryrefslogtreecommitdiff
path: root/lisp/help.el
diff options
context:
space:
mode:
authorGerd Moellmann <gerd@gnu.org>2001-01-11 14:24:22 +0000
committerGerd Moellmann <gerd@gnu.org>2001-01-11 14:24:22 +0000
commit50ca4be0b9764baaa8bf0f49ba02b6b638053d7d (patch)
tree3d13b4cd5dcd7214a10eb81b6d7df8af3bee2082 /lisp/help.el
parent422717d17bf62d24e977ce728fe9d50abaa96a13 (diff)
downloademacs-50ca4be0b9764baaa8bf0f49ba02b6b638053d7d.tar.gz
(load-symbol-file-load-history): New function extracted
from function symbol-file. (symbol-file): Use it.
Diffstat (limited to 'lisp/help.el')
-rw-r--r--lisp/help.el20
1 files changed, 13 insertions, 7 deletions
diff --git a/lisp/help.el b/lisp/help.el
index 935b3c05bf9..982d007676d 100644
--- a/lisp/help.el
+++ b/lisp/help.el
@@ -569,12 +569,10 @@ If that doesn't give a function, return nil."
That file records the part of `load-history' for preloaded files,
which is cleared out before dumping to make Emacs smaller.")
-(defun symbol-file (function)
- "Return the input source from which FUNCTION was loaded.
-The value is normally a string that was passed to `load':
-either an absolute file name, or a library name
-\(with no directory name and no `.el' or `.elc' at the end).
-It can also be nil, if the definition is not associated with any file."
+(defun load-symbol-file-load-history ()
+ "Load the file `fns-VERSION.el' in `exec-directory' if not already done.
+That file records the part of `load-history' for preloaded files,
+which is cleared out before dumping to make Emacs smaller."
(unless symbol-file-load-history-loaded
(load (expand-file-name
;; fns-XX.YY.ZZ.el does not work on DOS filesystem.
@@ -584,7 +582,15 @@ It can also be nil, if the definition is not associated with any file."
exec-directory)
;; The file name fns-%s.el already has a .el extension.
nil nil t)
- (setq symbol-file-load-history-loaded t))
+ (setq symbol-file-load-history-loaded t)))
+
+(defun symbol-file (function)
+ "Return the input source from which FUNCTION was loaded.
+The value is normally a string that was passed to `load':
+either an absolute file name, or a library name
+\(with no directory name and no `.el' or `.elc' at the end).
+It can also be nil, if the definition is not associated with any file."
+ (load-symbol-file-load-history)
(let ((files load-history)
file functions)
(while files