emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/diff-mode.el


From: Kai Großjohann
Subject: [Emacs-diffs] Changes to emacs/lisp/diff-mode.el
Date: Sun, 13 Jun 2004 12:54:30 -0400

Index: emacs/lisp/diff-mode.el
diff -c emacs/lisp/diff-mode.el:1.63 emacs/lisp/diff-mode.el:1.64
*** emacs/lisp/diff-mode.el:1.63        Thu May  6 18:41:32 2004
--- emacs/lisp/diff-mode.el     Sun Jun 13 16:48:44 2004
***************
*** 1248,1256 ****
  (defun diff-current-defun ()
    "Find the name of function at point.
  For use in `add-log-current-defun-function'."
    (destructuring-bind (buf line-offset pos src dst &optional switched)
        (diff-find-source-location)
-     (save-excursion
        (beginning-of-line)
        (or (when (memq (char-after) '(?< ?-))
            ;; Cursor is pointing at removed text.  This could be a removed
--- 1248,1259 ----
  (defun diff-current-defun ()
    "Find the name of function at point.
  For use in `add-log-current-defun-function'."
+     (save-excursion
+       (when (looking-at diff-hunk-header-re)
+       (forward-line 1)
+       (while (and (looking-at " ") (not (zerop (forward-line 1))))))
    (destructuring-bind (buf line-offset pos src dst &optional switched)
        (diff-find-source-location)
        (beginning-of-line)
        (or (when (memq (char-after) '(?< ?-))
            ;; Cursor is pointing at removed text.  This could be a removed




reply via email to

[Prev in Thread] Current Thread [Next in Thread]