]> git.eshelyaron.com Git - emacs.git/commitdiff
Simplify set-goal-column
authorLars Ingebrigtsen <larsi@gnus.org>
Sun, 5 Jun 2022 20:29:08 +0000 (22:29 +0200)
committerLars Ingebrigtsen <larsi@gnus.org>
Sun, 5 Jun 2022 20:29:08 +0000 (22:29 +0200)
* lisp/simple.el (set-goal-column): Simplify the code.

lisp/simple.el

index c749e6e41d62bd6634d15d6e614f8145cfdc87b0..ac41b394a78d9036f1c77eed86850b8dcc9037c9 100644 (file)
@@ -8096,18 +8096,10 @@ a buffer-local setting."
         (setq goal-column nil)
         (message "No goal column"))
     (setq goal-column (current-column))
-    ;; The older method below can be erroneous if `set-goal-column' is bound
-    ;; to a sequence containing %
-    ;;(message (substitute-command-keys
-    ;;"Goal column %d (use \\[set-goal-column] with an arg to unset it)")
-    ;;goal-column)
-    (message "%s"
-            (concat
-             (format "Goal column %d " goal-column)
-             (substitute-command-keys
-              "(use \\[set-goal-column] with an arg to unset it)")))
-
-    )
+    (message "Goal column %d %s"
+             goal-column
+            (substitute-command-keys
+             "(use \\[set-goal-column] with an arg to unset it)")))
   nil)
 \f
 ;;; Editing based on visual lines, as opposed to logical lines.