diff options
-rw-r--r-- | lisp/add-log.el | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/add-log.el b/lisp/add-log.el index 07468ff1366..0791fe1fe30 100644 --- a/lisp/add-log.el +++ b/lisp/add-log.el @@ -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)))) |