Mercurial > emacs
comparison src/buffer.c @ 26056:9c4556ef15de
(Fget_buffer_create, Fmake_indirect_buffer, Fkill_buffer):
Don't initialize prompt_end_charpos field.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Sun, 17 Oct 1999 12:53:14 +0000 |
parents | 8b89b961f7d1 |
children | b7aa6ac26872 |
comparison
equal
deleted
inserted
replaced
26055:cf5dd9e8bf79 | 26056:9c4556ef15de |
---|---|
371 *(BUF_GPT_ADDR (b)) = *(BUF_Z_ADDR (b)) = 0; /* Put an anchor '\0'. */ | 371 *(BUF_GPT_ADDR (b)) = *(BUF_Z_ADDR (b)) = 0; /* Put an anchor '\0'. */ |
372 | 372 |
373 b->newline_cache = 0; | 373 b->newline_cache = 0; |
374 b->width_run_cache = 0; | 374 b->width_run_cache = 0; |
375 b->width_table = Qnil; | 375 b->width_table = Qnil; |
376 b->prompt_end_charpos = Qnil; | |
377 b->prevent_redisplay_optimizations_p = 1; | 376 b->prevent_redisplay_optimizations_p = 1; |
378 | 377 |
379 /* Put this on the chain of all buffers including killed ones. */ | 378 /* Put this on the chain of all buffers including killed ones. */ |
380 b->next = all_buffers; | 379 b->next = all_buffers; |
381 all_buffers = b; | 380 all_buffers = b; |
451 BUF_PT_BYTE (b) = BUF_PT_BYTE (b->base_buffer); | 450 BUF_PT_BYTE (b) = BUF_PT_BYTE (b->base_buffer); |
452 | 451 |
453 b->newline_cache = 0; | 452 b->newline_cache = 0; |
454 b->width_run_cache = 0; | 453 b->width_run_cache = 0; |
455 b->width_table = Qnil; | 454 b->width_table = Qnil; |
456 b->prompt_end_charpos = Qnil; | |
457 | 455 |
458 /* Put this on the chain of all buffers including killed ones. */ | 456 /* Put this on the chain of all buffers including killed ones. */ |
459 b->next = all_buffers; | 457 b->next = all_buffers; |
460 all_buffers = b; | 458 all_buffers = b; |
461 | 459 |
1220 { | 1218 { |
1221 free_region_cache (b->width_run_cache); | 1219 free_region_cache (b->width_run_cache); |
1222 b->width_run_cache = 0; | 1220 b->width_run_cache = 0; |
1223 } | 1221 } |
1224 b->width_table = Qnil; | 1222 b->width_table = Qnil; |
1225 b->prompt_end_charpos = Qnil; | |
1226 UNBLOCK_INPUT; | 1223 UNBLOCK_INPUT; |
1227 b->undo_list = Qnil; | 1224 b->undo_list = Qnil; |
1228 | 1225 |
1229 return Qt; | 1226 return Qt; |
1230 } | 1227 } |
1702 Any narrowing restriction in effect (see `narrow-to-region') is removed,\n\ | 1699 Any narrowing restriction in effect (see `narrow-to-region') is removed,\n\ |
1703 so the buffer is truly empty after this.") | 1700 so the buffer is truly empty after this.") |
1704 () | 1701 () |
1705 { | 1702 { |
1706 Fwiden (); | 1703 Fwiden (); |
1707 | 1704 |
1708 if (INTEGERP (current_buffer->prompt_end_charpos)) | 1705 del_range (BEG, Z); |
1709 del_range (XINT (current_buffer->prompt_end_charpos), Z); | |
1710 else | |
1711 del_range (BEG, Z); | |
1712 | 1706 |
1713 current_buffer->last_window_start = 1; | 1707 current_buffer->last_window_start = 1; |
1714 /* Prevent warnings, or suspension of auto saving, that would happen | 1708 /* Prevent warnings, or suspension of auto saving, that would happen |
1715 if future size is less than past size. Use of erase-buffer | 1709 if future size is less than past size. Use of erase-buffer |
1716 implies that the future text is not really related to the past text. */ | 1710 implies that the future text is not really related to the past text. */ |