summaryrefslogtreecommitdiff
path: root/src/indent.c
diff options
context:
space:
mode:
authorGregory Heytings <gregory@heytings.org>2023-03-28 23:06:55 +0000
committerGregory Heytings <gregory@heytings.org>2023-03-29 01:12:36 +0200
commit7e26a5c774e7c71782d89abe1d4be125d8422a4b (patch)
tree7e9ab1f0c27dc2945ff89cd595a30450925e0227 /src/indent.c
parent85ed1c9ca6b786763740766d77b1f806c2f301a1 (diff)
downloademacs-7e26a5c774e7c71782d89abe1d4be125d8422a4b.tar.gz
emacs-7e26a5c774e7c71782d89abe1d4be125d8422a4b.tar.bz2
emacs-7e26a5c774e7c71782d89abe1d4be125d8422a4b.zip
Remove labeled restrictions before calling Fwiden
* src/editfns.c (labeled_restrictions_remove_in_current_buffer): New function. * src/lisp.h: Make it externally visible. * src/xdisp.c (display_count_lines_logically): * src/lread.c (readevalloop): * src/indent.c (line_number_display_width): * src/fileio.c (write_region): * src/callproc.c (Fcall_process_region): * src/buffer.c (Ferase_buffer): Use it.
Diffstat (limited to 'src/indent.c')
-rw-r--r--src/indent.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/indent.c b/src/indent.c
index 08d2bf5ea28..aef394dab88 100644
--- a/src/indent.c
+++ b/src/indent.c
@@ -2065,6 +2065,7 @@ line_number_display_width (struct window *w, int *width, int *pixel_width)
{
record_unwind_protect (save_restriction_restore,
save_restriction_save ());
+ labeled_restrictions_remove_in_current_buffer ();
Fwiden ();
saved_restriction = true;
}