comparison lisp/diff-mode.el @ 79843:8ac943071f87

(diff-end-of-hunk): Revert 2008-01-08 change.
author Glenn Morris <rgm@gnu.org>
date Tue, 15 Jan 2008 03:46:44 +0000
parents 8d4fc8948539
children f68e2df975f5
comparison
equal deleted inserted replaced
79842:b42de16944ab 79843:8ac943071f87
389 (when (looking-at diff-hunk-header-re) 389 (when (looking-at diff-hunk-header-re)
390 (unless style 390 (unless style
391 ;; Especially important for unified (because headers are ambiguous). 391 ;; Especially important for unified (because headers are ambiguous).
392 (setq style (cdr (assq (char-after) '((?@ . unified) (?* . context)))))) 392 (setq style (cdr (assq (char-after) '((?@ . unified) (?* . context))))))
393 (goto-char (match-end 0))) 393 (goto-char (match-end 0)))
394 ;; Some versions of diff replace all-blank context lines in unified
395 ;; format with empty lines. The use of \n below avoids matching such
396 ;; lines as headers.
397 ;; http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01990.html
398 (let ((end (and (re-search-forward (case style 394 (let ((end (and (re-search-forward (case style
399 ;; A `unified' header is ambiguous. 395 ;; A `unified' header is ambiguous.
400 (unified (concat "^[^-+# \\\n]\\|" 396 (unified (concat "^[^-+# \\]\\|"
401 diff-file-header-re)) 397 diff-file-header-re))
402 (context "^[^-+#! \\]") 398 (context "^[^-+#! \\]")
403 (normal "^[^<>#\\]") 399 (normal "^[^<>#\\]")
404 (t "^[^-+#!<> \\]")) 400 (t "^[^-+#!<> \\]"))
405 nil t) 401 nil t)