# HG changeset patch # User Masatake YAMATO # Date 1117476362 0 # Node ID af6dffb5d18085571235aaa00dc8a4bbcd344d07 # Parent 88db2adda4b70c55b7062bf310a3571df19a8c6f * emacs-lisp/find-func.el (find-function-noselect): Handle subroutines. * help-fns.el (help-C-file-name): Added autoload mark for `find-function-noselect'. diff -r 88db2adda4b7 -r af6dffb5d180 lisp/ChangeLog --- a/lisp/ChangeLog Mon May 30 17:13:58 2005 +0000 +++ b/lisp/ChangeLog Mon May 30 18:06:02 2005 +0000 @@ -1,3 +1,11 @@ +2005-05-31 Masatake YAMATO + + * emacs-lisp/find-func.el (find-function-noselect): Handle + subroutines. + + * help-fns.el (help-C-file-name): Added autoload mark for + `find-function-noselect'. + 2005-05-30 Glenn Morris * calendar/diary-lib.el (mark-included-diary-files): Only kill diff -r 88db2adda4b7 -r af6dffb5d180 lisp/emacs-lisp/find-func.el --- a/lisp/emacs-lisp/find-func.el Mon May 30 17:13:58 2005 +0000 +++ b/lisp/emacs-lisp/find-func.el Mon May 30 18:06:02 2005 +0000 @@ -246,8 +246,6 @@ in `load-path'." (if (not function) (error "You didn't specify a function")) - (and (subrp (symbol-function function)) - (error "%s is a primitive function" function)) (let ((def (symbol-function function)) aliases) (while (symbolp def) @@ -265,6 +263,8 @@ (let ((library (cond ((eq (car-safe def) 'autoload) (nth 1 def)) + ((subrp def) + (help-C-file-name def 'subr)) ((symbol-file function 'defun))))) (find-function-search-for-symbol function nil library)))) diff -r 88db2adda4b7 -r af6dffb5d180 lisp/help-fns.el --- a/lisp/help-fns.el Mon May 30 17:13:58 2005 +0000 +++ b/lisp/help-fns.el Mon May 30 18:06:02 2005 +0000 @@ -224,7 +224,7 @@ ;;; (symbol-file (if (symbolp subr-or-var) subr-or-var ;;; (subr-name subr-or-var)) ;;; (if (eq kind 'var) 'defvar 'defun))) - +;;;###autoload (defun help-C-file-name (subr-or-var kind) "Return the name of the C file where SUBR-OR-VAR is defined. KIND should be `var' for a variable or `subr' for a subroutine."