changeset 2452:d1a7c8a5b835

Emacs: use delete-region instead of kill-* functions. This patch eliminates `kill-line' which taints kill-ring, and `kill-entire-line' which is specific for XEmacs.
author FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
date Sat, 17 Jun 2006 00:06:28 +0900
parents 134227b82a96
children b5902db74ba3
files contrib/mercurial.el
diffstat 1 files changed, 4 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/mercurial.el	Sat Jun 17 18:36:04 2006 +0200
+++ b/contrib/mercurial.el	Sat Jun 17 00:06:28 2006 +0900
@@ -712,7 +712,8 @@
     (let ((pos (point)))
       (insert (documentation 'hg-mode))
       (goto-char pos)
-      (kill-line))))
+      (end-of-line 1)
+      (delete-region pos (point)))))
 
 (defun hg-add (path)
   "Add PATH to the Mercurial repository on the next commit.
@@ -959,8 +960,8 @@
 (defun hg-log-mode ()
   "Mode for viewing a Mercurial change log."
   (goto-char (point-min))
-  (when (looking-at "^searching for changes")
-    (kill-entire-line))
+  (when (looking-at "^searching for changes.*$")
+    (delete-region (match-beginning 0) (match-end 0)))
   (run-hooks 'hg-log-mode-hook))
 
 (defun hg-log (path &optional rev1 rev2 log-limit)