Mercurial > emacs
diff lisp/help-fns.el @ 58069:42823717f9da
* help-fns.el (help-C-file-name): File name must be in build-files
to be returned.
author | Jan Djärv <jan.h.d@swipnet.se> |
---|---|
date | Tue, 09 Nov 2004 08:20:44 +0000 |
parents | 2f9fe20953a6 |
children | 3a6978b560e9 cb7f41387eb3 |
line wrap: on
line diff
--- a/lisp/help-fns.el Tue Nov 09 08:19:51 2004 +0000 +++ b/lisp/help-fns.el Tue Nov 09 08:20:44 2004 +0000 @@ -228,9 +228,14 @@ (if (eobp) (insert-file-contents-literally (expand-file-name internal-doc-file-name doc-directory))) - (search-forward (concat "" name "\n")) + (let ((file (catch 'loop + (while t + (let ((pnt (search-forward (concat "" name "\n")))) (re-search-backward "S\\(.*\\)") (let ((file (match-string 1))) + (if (member file build-files) + (throw 'loop file) + (goto-char pnt)))))))) (if (string-match "\\.\\(o\\|obj\\)\\'" file) (setq file (replace-match ".c" t t file))) (if (string-match "\\.c\\'" file)