Mercurial > emacs
comparison lisp/help.el @ 39099:847a84fe7c2b
(describe-function-1): Save precomputed `file-name' rather
than recomputing it (incorrectly) with `symbol-file'.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Tue, 04 Sep 2001 01:06:43 +0000 |
parents | 92af2bb73b51 |
children | a8abe33e09d1 |
comparison
equal
deleted
inserted
replaced
39098:ee6a2760c8dc | 39099:847a84fe7c2b |
---|---|
708 (princ "'") | 708 (princ "'") |
709 ;; Make a hyperlink to the library. | 709 ;; Make a hyperlink to the library. |
710 (with-current-buffer "*Help*" | 710 (with-current-buffer "*Help*" |
711 (save-excursion | 711 (save-excursion |
712 (re-search-backward "`\\([^`']+\\)'" nil t) | 712 (re-search-backward "`\\([^`']+\\)'" nil t) |
713 (help-xref-button | 713 (help-xref-button |
714 1 | 714 1 |
715 #'(lambda (arg) | 715 #'(lambda (fun file) |
716 (require 'find-func) | 716 (require 'find-func) |
717 ;; Don't use find-function-noselect because it follows | |
718 ;; aliases (which fails for built-in functions). | |
717 (let* ((location (find-function-search-for-symbol | 719 (let* ((location (find-function-search-for-symbol |
718 arg nil (symbol-file arg)))) | 720 fun nil file))) |
719 (pop-to-buffer (car location)) | 721 (pop-to-buffer (car location)) |
720 (goto-char (cdr location)))) | 722 (goto-char (cdr location)))) |
721 function | 723 (list function file-name) |
722 "mouse-2, RET: find function's definition"))))) | 724 "mouse-2, RET: find function's definition"))))) |
723 (if need-close (princ ")")) | 725 (if need-close (princ ")")) |
724 (princ ".") | 726 (princ ".") |
725 (terpri) | 727 (terpri) |
726 ;; Handle symbols aliased to other symbols. | 728 ;; Handle symbols aliased to other symbols. |