diff options
| author | Richard M. Stallman | 2006-06-16 15:18:03 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 2006-06-16 15:18:03 +0000 |
| commit | 76f008da70bce146ca1827bd68f9339f5d1b3004 (patch) | |
| tree | 2664fc48c7e346f369b87c3cb207dba95a7ef250 | |
| parent | ac2c512030ddd83b1bb8d9dbf05caabe5bf52f14 (diff) | |
| download | emacs-76f008da70bce146ca1827bd68f9339f5d1b3004.tar.gz emacs-76f008da70bce146ca1827bd68f9339f5d1b3004.zip | |
(Using Interactive): Explain problem of markers, etc., in command-history.
| -rw-r--r-- | lispref/commands.texi | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/lispref/commands.texi b/lispref/commands.texi index a75c0c89fec..e494d0dfc5a 100644 --- a/lispref/commands.texi +++ b/lispref/commands.texi | |||
| @@ -233,6 +233,20 @@ reading the keyboard input: | |||
| 233 | (let ((string (read-string "Foo: " nil 'my-history))) | 233 | (let ((string (read-string "Foo: " nil 'my-history))) |
| 234 | (list (region-beginning) (region-end) string))) | 234 | (list (region-beginning) (region-end) string))) |
| 235 | @end smallexample | 235 | @end smallexample |
| 236 | |||
| 237 | @strong{Warning:} the argument values should not include any data | ||
| 238 | types that can't be printed and then read. Some facilities save | ||
| 239 | @code{command-history} in a file to be read in the subsequent | ||
| 240 | sessions; if a command's arguments contain a data type that prints | ||
| 241 | using @samp{#<@dots{}>} syntax, those facilities won't work. | ||
| 242 | |||
| 243 | There are, however, a few exceptions: it is ok to use a limited set of | ||
| 244 | expressions such as @code{(point)}, @code{(mark)}, | ||
| 245 | @code{(region-beginning)}, and @code{(region-end)}, because Emacs | ||
| 246 | recognizes them specially and puts the expression (rather than its | ||
| 247 | value) into the command history. To see whether the expression you | ||
| 248 | wrote is one of these exceptions, run the command, then examine | ||
| 249 | @code{(car command-history)}. | ||
| 236 | @end itemize | 250 | @end itemize |
| 237 | 251 | ||
| 238 | @cindex examining the @code{interactive} form | 252 | @cindex examining the @code{interactive} form |