447 |
for (; list; list = list->next) |
for (; list; list = list->next) |
448 |
{ |
{ |
449 |
Lisp_Object overlay, start, end, old_overlay; |
Lisp_Object overlay, start, end, old_overlay; |
450 |
int charpos; |
EMACS_INT charpos; |
451 |
|
|
452 |
XSETMISC (old_overlay, list); |
XSETMISC (old_overlay, list); |
453 |
charpos = marker_position (OVERLAY_START (old_overlay)); |
charpos = marker_position (OVERLAY_START (old_overlay)); |
1630 |
{ |
{ |
1631 |
char *err; |
char *err; |
1632 |
|
|
1633 |
|
if (EQ (buffer, Fwindow_buffer (selected_window))) |
1634 |
|
/* Basically a NOP. Avoid signalling an error if the selected window |
1635 |
|
is dedicated, or a minibuffer, ... */ |
1636 |
|
return Fset_buffer (buffer); |
1637 |
|
|
1638 |
err = no_switch_window (selected_window); |
err = no_switch_window (selected_window); |
1639 |
if (err) error (err); |
if (err) error (err); |
1640 |
|
|
4103 |
overlay = Qnil; |
overlay = Qnil; |
4104 |
tail = NULL; |
tail = NULL; |
4105 |
|
|
4106 |
|
/* We used to run the functions as soon as we found them and only register |
4107 |
|
them in last_overlay_modification_hooks for the purpose of the `after' |
4108 |
|
case. But running elisp code as we traverse the list of overlays is |
4109 |
|
painful because the list can be modified by the elisp code so we had to |
4110 |
|
copy at several places. We now simply do a read-only traversal that |
4111 |
|
only collects the functions to run and we run them afterwards. It's |
4112 |
|
simpler, especially since all the code was already there. -stef */ |
4113 |
|
|
4114 |
if (!after) |
if (!after) |
4115 |
{ |
{ |
4116 |
/* We are being called before a change. |
/* We are being called before a change. |