summaryrefslogtreecommitdiff
path: root/lisp/kmacro.el
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2019-02-01 08:40:53 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2019-02-01 08:40:53 -0800
commit3e99077ab39fac1ab1f3794b211f2c0c480c6e6e (patch)
tree6b7e0492dbb35c55de9757fd062a4f0a55ee6bdc /lisp/kmacro.el
parentb80e3308d690e53b7c6300f030d99281b6894b8c (diff)
parent6c6b540711d0dd8a8eac9547968ed4dfb493fd1c (diff)
downloademacs-3e99077ab39fac1ab1f3794b211f2c0c480c6e6e.tar.gz
Merge from origin/emacs-26
6c6b540711 Correct the docs of inserting kmacro counter 32555daf4c * doc/misc/calc.texi (Algebraic Tutorial): Fix a typo. (B...
Diffstat (limited to 'lisp/kmacro.el')
-rw-r--r--lisp/kmacro.el12
1 files changed, 8 insertions, 4 deletions
diff --git a/lisp/kmacro.el b/lisp/kmacro.el
index 701437f9d20..fc34e167084 100644
--- a/lisp/kmacro.el
+++ b/lisp/kmacro.el
@@ -256,7 +256,10 @@ Can be set directly via `kmacro-set-format', which see.")
(defun kmacro-insert-counter (arg)
"Insert current value of `kmacro-counter', then increment it by ARG.
Interactively, ARG defaults to 1. With \\[universal-argument], insert
-current value of `kmacro-counter', but do not increment it."
+the previous value of `kmacro-counter', and do not increment the
+current value.
+The previous value of the counter is the one it had before
+the last increment."
(interactive "P")
(if kmacro-initial-counter-value
(setq kmacro-counter kmacro-initial-counter-value
@@ -685,9 +688,10 @@ the current value of `kmacro-counter').
When used during defining/executing a macro, inserts the current value
of `kmacro-counter' and increments the counter value by ARG (or by 1 if no
-prefix argument). With just \\[universal-argument], inserts the current value
-of `kmacro-counter', but does not modify the counter; this is the
-same as incrementing the counter by zero.
+prefix argument). With just \\[universal-argument], inserts the previous
+value of `kmacro-counter', and does not modify the counter; this is
+different from incrementing the counter by zero. (The previous value
+of the counter is the one it had before the last increment.)
The macro counter can be set directly via \\[kmacro-set-counter] and \\[kmacro-add-counter].
The format of the inserted value of the counter can be controlled