diff options
| author | Noam Postavsky | 2016-07-10 21:52:23 -0400 |
|---|---|---|
| committer | Noam Postavsky | 2016-07-14 20:01:39 -0400 |
| commit | 9ba51edf62b25c678508a316ec78a09b18d3bf9e (patch) | |
| tree | 99f1e4e776bc3814a41164d41a8c10dbfe425b0d /src/buffer.c | |
| parent | 452aa949bc4de77b1fba103de6b61e55b2ca8c0b (diff) | |
| download | emacs-9ba51edf62b25c678508a316ec78a09b18d3bf9e.tar.gz emacs-9ba51edf62b25c678508a316ec78a09b18d3bf9e.zip | |
Document buffer-swap-text+save-excursion interaction
* doc/lispref/buffers.texi (Swapping Text):
* src/buffer.c (Fbuffer_swap_text): Add warning about interaction of
`buffer-swap-text' and `save-excursion' (Bug #4655).
Diffstat (limited to 'src/buffer.c')
| -rw-r--r-- | src/buffer.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/buffer.c b/src/buffer.c index e4269c0046a..89f4479740a 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -2231,7 +2231,9 @@ advance_to_char_boundary (ptrdiff_t byte_pos) | |||
| 2231 | 2231 | ||
| 2232 | DEFUN ("buffer-swap-text", Fbuffer_swap_text, Sbuffer_swap_text, | 2232 | DEFUN ("buffer-swap-text", Fbuffer_swap_text, Sbuffer_swap_text, |
| 2233 | 1, 1, 0, | 2233 | 1, 1, 0, |
| 2234 | doc: /* Swap the text between current buffer and BUFFER. */) | 2234 | doc: /* Swap the text between current buffer and BUFFER. |
| 2235 | Using this function from `save-excursion' might produce surprising | ||
| 2236 | results, see Info node `(elisp)Swapping Text'. */) | ||
| 2235 | (Lisp_Object buffer) | 2237 | (Lisp_Object buffer) |
| 2236 | { | 2238 | { |
| 2237 | struct buffer *other_buffer; | 2239 | struct buffer *other_buffer; |