1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-02 11:21:42 +00:00

(add-log-current-defun): In Lisp, if we don't find a

real defun, return nil, not "".
This commit is contained in:
Richard M. Stallman 1996-02-09 19:09:22 +00:00
parent 9695bac622
commit 947b27432d

View File

@ -340,7 +340,8 @@ Has a preference of looking backwards."
(or (eobp) (forward-char 1))
(beginning-of-defun)
;; Make sure we are really inside the defun found, not after it.
(if (and (progn (end-of-defun)
(if (and (looking-at "\\s(")
(progn (end-of-defun)
(< location (point)))
(progn (forward-sexp -1)
(>= location (point))))