summaryrefslogtreecommitdiff
path: root/lisp/diff.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1992-09-20 20:58:22 +0000
committerRichard M. Stallman <rms@gnu.org>1992-09-20 20:58:22 +0000
commit55711467c6dc37b140b0b2cadb6cb399e095fb2b (patch)
treefb386d9fc022417184fffd3cc9994dbdb58d11cd /lisp/diff.el
parent05b216993847f3e076fc908c8d7b57ae5dd094e4 (diff)
downloademacs-55711467c6dc37b140b0b2cadb6cb399e095fb2b.tar.gz
entered into RCS
Diffstat (limited to 'lisp/diff.el')
-rw-r--r--lisp/diff.el13
1 files changed, 9 insertions, 4 deletions
diff --git a/lisp/diff.el b/lisp/diff.el
index ae49cf1f371..4e8d54afcd9 100644
--- a/lisp/diff.el
+++ b/lisp/diff.el
@@ -24,7 +24,7 @@
(require 'compile)
-(defvar diff-switches nil
+(defvar diff-switches "-c"
"*A string or list of strings specifying switches to be be passed to diff.")
(defvar diff-regexp-alist
@@ -93,9 +93,14 @@ is nil, REGEXP matches only half a section.")
(function (lambda (file subexpr)
(setq compilation-error-list
(cons
- (cons (set-marker (make-marker)
- (match-beginning subexpr)
- (current-buffer))
+ (cons (save-excursion
+ ;; Report location of message
+ ;; at beginning of line.
+ (goto-char
+ (match-beginning subexpr))
+ (beginning-of-line)
+ (point-marker))
+ ;; Report location of corresponding text.
(let ((line (string-to-int
(buffer-substring
(match-beginning subexpr)