]> code.delx.au - gnu-emacs/commitdiff
Improve commentary of prepare_to_modify_buffer_1
authorEli Zaretskii <eliz@gnu.org>
Thu, 26 Nov 2015 20:08:54 +0000 (22:08 +0200)
committerEli Zaretskii <eliz@gnu.org>
Thu, 26 Nov 2015 20:08:54 +0000 (22:08 +0200)
* src/insdel.c (prepare_to_modify_buffer_1): Mention in commentary
that this function runs Lisp.  Suggested by Richard Stallman
<rms@gnu.org>.

src/insdel.c

index 8b08c1e59b74bd84faa1ca0da8a4705783b98fc8..bb3171b14cebb6e9b9990e1a3a17e8115fa0ee8e 100644 (file)
@@ -1785,7 +1785,12 @@ run_undoable_change (void)
    any modification properties the text may have.
 
    If PRESERVE_PTR is nonzero, we relocate *PRESERVE_PTR
-   by holding its value temporarily in a marker.  */
+   by holding its value temporarily in a marker.
+
+   This function runs Lisp, which means it can GC, which means it can
+   compact buffers, including the current buffer being worked on here.
+   So don't you dare calling this function while manipulating the gap,
+   or during some other similar "critical section".  */
 
 void
 prepare_to_modify_buffer_1 (ptrdiff_t start, ptrdiff_t end,