summaryrefslogtreecommitdiff
path: root/lisp/add-log.el
diff options
context:
space:
mode:
authorJim Blandy <jimb@redhat.com>1993-06-21 00:51:36 +0000
committerJim Blandy <jimb@redhat.com>1993-06-21 00:51:36 +0000
commit4fce88345f52c826793c1cbeb80c508877a9b3ab (patch)
treec7978244e05741bd2654a004200bab7d0b45e366 /lisp/add-log.el
parentf3be8c5316fa4595a221b53362c6e1d48c5e481c (diff)
downloademacs-4fce88345f52c826793c1cbeb80c508877a9b3ab.tar.gz
* add-log.el (add-log-current-defun): To find the name of the
function being defined in emacs-lisp-mode, lisp-mode, and scheme-mode, skip an opening paren and an s-expression, instead of just one word. This allows us to properly recognize things like define-key and define-macro.
Diffstat (limited to 'lisp/add-log.el')
-rw-r--r--lisp/add-log.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/add-log.el b/lisp/add-log.el
index d121a76cdf6..6c468a919ec 100644
--- a/lisp/add-log.el
+++ b/lisp/add-log.el
@@ -267,7 +267,9 @@ Has a preference of looking backwards."
(progn (forward-sexp -1)
(>= location (point))))
(progn
- (forward-word 1)
+ (if (looking-at "\\s(")
+ (forward-char 1))
+ (forward-sexp 1)
(skip-chars-forward " ")
(buffer-substring (point)
(progn (forward-sexp 1) (point))))))