/[emacs]/emacs/lisp/smerge-mode.el
ViewVC logotype

Diff of /emacs/lisp/smerge-mode.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.20 by monnier, Thu Oct 10 17:30:20 2002 UTC revision 1.21 by lektu, Tue Feb 4 12:05:02 2003 UTC
# Line 203  Can be nil if the style is undecided, or Line 203  Can be nil if the style is undecided, or
203               (save-excursion (goto-char (point-min))               (save-excursion (goto-char (point-min))
204                               (not (re-search-forward smerge-begin-re nil t))))                               (not (re-search-forward smerge-begin-re nil t))))
205      (smerge-mode -1)))      (smerge-mode -1)))
206        
207    
208  (defun smerge-keep-all ()  (defun smerge-keep-all ()
209    "Keep all three versions.    "Keep all three versions.
# Line 337  An error is raised if not inside a confl Line 337  An error is raised if not inside a confl
337    
338                 (_ (re-search-forward smerge-end-re))                 (_ (re-search-forward smerge-end-re))
339                 (_ (assert (< orig-point (match-end 0))))                 (_ (assert (< orig-point (match-end 0))))
340                  
341                 (other-end (match-beginning 0))                 (other-end (match-beginning 0))
342                 (end (match-end 0))                 (end (match-end 0))
343    
# Line 370  An error is raised if not inside a confl Line 370  An error is raised if not inside a confl
370             (setq base-end   mine-end)             (setq base-end   mine-end)
371             (setq mine-start other-start)             (setq mine-start other-start)
372             (setq mine-end   other-end)))             (setq mine-end   other-end)))
373                  
374            (store-match-data (list start end            (store-match-data (list start end
375                                    mine-start mine-end                                    mine-start mine-end
376                                    base-start base-end                                    base-start base-end
# Line 469  buffer names." Line 469  buffer names."
469        (buffer-enable-undo)        (buffer-enable-undo)
470        (set-buffer-modified-p nil)        (set-buffer-modified-p nil)
471        (funcall mode))        (funcall mode))
472        
473      (when base      (when base
474        (setq base (generate-new-buffer        (setq base (generate-new-buffer
475                    (or name-base (concat "*" filename " BASE*"))))                    (or name-base (concat "*" filename " BASE*"))))
# Line 482  buffer names." Line 482  buffer names."
482          (buffer-enable-undo)          (buffer-enable-undo)
483          (set-buffer-modified-p nil)          (set-buffer-modified-p nil)
484          (funcall mode)))          (funcall mode)))
485        
486      ;; the rest of the code is inspired from vc.el      ;; the rest of the code is inspired from vc.el
487      ;; Fire up ediff.      ;; Fire up ediff.
488      (set-buffer      (set-buffer
# Line 491  buffer names." Line 491  buffer names."
491            ;; nil 'ediff-merge-revisions-with-ancestor buffer-file-name)            ;; nil 'ediff-merge-revisions-with-ancestor buffer-file-name)
492         (ediff-merge-buffers mine other)))         (ediff-merge-buffers mine other)))
493          ;; nil 'ediff-merge-revisions buffer-file-name)))          ;; nil 'ediff-merge-revisions buffer-file-name)))
494        
495      ;; Ediff is now set up, and we are in the control buffer.      ;; Ediff is now set up, and we are in the control buffer.
496      ;; Do a few further adjustments and take precautions for exit.      ;; Do a few further adjustments and take precautions for exit.
497      (set (make-local-variable 'smerge-ediff-windows) config)      (set (make-local-variable 'smerge-ediff-windows) config)

Legend:
Removed from v.1.20  
changed lines
  Added in v.1.21

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26