]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/progmodes/meta-mode.el: (meta-indent-line): Simplify.
authorGlenn Morris <rgm@gnu.org>
Tue, 9 Nov 2010 08:00:46 +0000 (00:00 -0800)
committerGlenn Morris <rgm@gnu.org>
Tue, 9 Nov 2010 08:00:46 +0000 (00:00 -0800)
lisp/ChangeLog
lisp/progmodes/meta-mode.el

index 16beffe989e4ad5c4eb1b2d1a6b1454e995a79dd..33d50961912640188ee00b3742e94938b4230eb6 100644 (file)
@@ -1,6 +1,7 @@
 2010-11-09  Glenn Morris  <rgm@gnu.org>
 
        * progmodes/meta-mode.el: Remove leading `*' from defcustom docs.
+       (meta-indent-line): Simplify.
 
        * vc/emerge.el (emerge-line-number-in-buf):
        * textmodes/ispell.el (ispell-region):
index d40e0d77ef30d12f7268dfd0cedf8adf178d9a3d..294c75c9ccf50f60253749f571482967efc41860 100644 (file)
@@ -575,12 +575,11 @@ If the list was changed, sort the list and remove duplicates first."
   "Indent the line containing point as Metafont or MetaPost source."
   (interactive)
   (let ((indent (meta-indent-calculate)))
-    (save-excursion
-      (if (/= (current-indentation) indent)
-          (let ((beg (line-beginning-position))
-                (end (progn (back-to-indentation) (point))))
-            (delete-region beg end)
-            (indent-to indent))))
+    (if (/= (current-indentation) indent)
+        (save-excursion
+          (delete-region (line-beginning-position)
+                         (progn (back-to-indentation) (point)))
+          (indent-to indent)))
     (if (< (current-column) indent)
         (back-to-indentation))))