diff options
| author | Stefan Monnier | 2010-11-12 08:35:36 -0500 |
|---|---|---|
| committer | Stefan Monnier | 2010-11-12 08:35:36 -0500 |
| commit | 4e9e1584fd08ee318589e70049dd22429fd7e9c3 (patch) | |
| tree | c05558bb08f19ee31b43fd8615f1aec79d6cd07a | |
| parent | 4490f87580a8f9ade324ea1d3a095dddca8ecf1d (diff) | |
| download | emacs-4e9e1584fd08ee318589e70049dd22429fd7e9c3.tar.gz emacs-4e9e1584fd08ee318589e70049dd22429fd7e9c3.zip | |
* lisp/vc/smerge-mode.el (smerge-refine): Choose better default part to
highlight when one of them is empty.
| -rw-r--r-- | lisp/ChangeLog | 3 | ||||
| -rw-r--r-- | lisp/vc/smerge-mode.el | 4 |
2 files changed, 7 insertions, 0 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 64c52eebc7b..4b1e880e547 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,5 +1,8 @@ | |||
| 1 | 2010-11-12 Stefan Monnier <monnier@iro.umontreal.ca> | 1 | 2010-11-12 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 2 | ||
| 3 | * vc/smerge-mode.el (smerge-refine): Choose better default part to | ||
| 4 | highlight when one of them is empty. | ||
| 5 | |||
| 3 | * skeleton.el (skeleton-read): Don't use `newline' since it may strip | 6 | * skeleton.el (skeleton-read): Don't use `newline' since it may strip |
| 4 | trailing space. | 7 | trailing space. |
| 5 | (skeleton-newline): New function. | 8 | (skeleton-newline): New function. |
diff --git a/lisp/vc/smerge-mode.el b/lisp/vc/smerge-mode.el index 6e72071b6a0..32f829f814e 100644 --- a/lisp/vc/smerge-mode.el +++ b/lisp/vc/smerge-mode.el | |||
| @@ -1009,6 +1009,10 @@ repeating the command will highlight other two parts." | |||
| 1009 | (setq part (cond ((null (match-end 2)) 2) | 1009 | (setq part (cond ((null (match-end 2)) 2) |
| 1010 | ((eq (match-end 1) (match-end 3)) 1) | 1010 | ((eq (match-end 1) (match-end 3)) 1) |
| 1011 | ((integerp part) part) | 1011 | ((integerp part) part) |
| 1012 | ;; If one of the parts is empty, any refinement using | ||
| 1013 | ;; it will be trivial and uninteresting. | ||
| 1014 | ((eq (match-end 1) (match-beginning 1)) 1) | ||
| 1015 | ((eq (match-end 3) (match-beginning 3)) 3) | ||
| 1012 | (t 2))) | 1016 | (t 2))) |
| 1013 | (let ((n1 (if (eq part 1) 2 1)) | 1017 | (let ((n1 (if (eq part 1) 2 1)) |
| 1014 | (n2 (if (eq part 3) 2 3))) | 1018 | (n2 (if (eq part 3) 2 3))) |