aboutsummaryrefslogtreecommitdiffstats
path: root/src/buffer.c
diff options
context:
space:
mode:
authorJim Blandy1992-01-13 21:48:08 +0000
committerJim Blandy1992-01-13 21:48:08 +0000
commit265a9e559da4ac72d154ecd638c51801b3e97847 (patch)
tree633e4dc50761c2cd5201a7874e23eee9e51aecea /src/buffer.c
parentd427b66a664c0e1ffc818dfa5b87b45b4857d2ae (diff)
downloademacs-265a9e559da4ac72d154ecd638c51801b3e97847.tar.gz
emacs-265a9e559da4ac72d154ecd638c51801b3e97847.zip
*** empty log message ***
Diffstat (limited to 'src/buffer.c')
-rw-r--r--src/buffer.c111
1 files changed, 54 insertions, 57 deletions
diff --git a/src/buffer.c b/src/buffer.c
index 68575d845f0..55d85f979ba 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -25,9 +25,6 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
25#define MAXPATHLEN 1024 25#define MAXPATHLEN 1024
26#endif /* not MAXPATHLEN */ 26#endif /* not MAXPATHLEN */
27 27
28#ifdef NULL
29#undef NULL
30#endif
31#include "config.h" 28#include "config.h"
32#include "lisp.h" 29#include "lisp.h"
33#include "window.h" 30#include "window.h"
@@ -163,7 +160,7 @@ If there is no such live buffer, return nil.")
163 if (XTYPE (buf) != Lisp_Buffer) continue; 160 if (XTYPE (buf) != Lisp_Buffer) continue;
164 if (XTYPE (XBUFFER (buf)->filename) != Lisp_String) continue; 161 if (XTYPE (XBUFFER (buf)->filename) != Lisp_String) continue;
165 tem = Fstring_equal (XBUFFER (buf)->filename, filename); 162 tem = Fstring_equal (XBUFFER (buf)->filename, filename);
166 if (!NULL (tem)) 163 if (!NILP (tem))
167 return buf; 164 return buf;
168 } 165 }
169 return Qnil; 166 return Qnil;
@@ -185,7 +182,7 @@ The value is never nil.")
185 register struct buffer *b; 182 register struct buffer *b;
186 183
187 buf = Fget_buffer (name); 184 buf = Fget_buffer (name);
188 if (!NULL (buf)) 185 if (!NILP (buf))
189 return buf; 186 return buf;
190 187
191 b = (struct buffer *) malloc (sizeof (struct buffer)); 188 b = (struct buffer *) malloc (sizeof (struct buffer));
@@ -227,14 +224,14 @@ The value is never nil.")
227 b->name = name; 224 b->name = name;
228 225
229 function = buffer_defaults.major_mode; 226 function = buffer_defaults.major_mode;
230 if (NULL (function)) 227 if (NILP (function))
231 { 228 {
232 tem = Fget (current_buffer->major_mode, Qmode_class); 229 tem = Fget (current_buffer->major_mode, Qmode_class);
233 if (EQ (tem, Qnil)) 230 if (EQ (tem, Qnil))
234 function = current_buffer->major_mode; 231 function = current_buffer->major_mode;
235 } 232 }
236 233
237 if (NULL (function) || EQ (function, Qfundamental_mode)) 234 if (NILP (function) || EQ (function, Qfundamental_mode))
238 return buf; 235 return buf;
239 236
240 /* To select a nonfundamental mode, 237 /* To select a nonfundamental mode,
@@ -327,7 +324,7 @@ until an unused name is found, and then return that name.")
327 CHECK_STRING (name, 0); 324 CHECK_STRING (name, 0);
328 325
329 tem = Fget_buffer (name); 326 tem = Fget_buffer (name);
330 if (NULL (tem)) 327 if (NILP (tem))
331 return name; 328 return name;
332 329
333 count = 1; 330 count = 1;
@@ -336,7 +333,7 @@ until an unused name is found, and then return that name.")
336 sprintf (number, "<%d>", ++count); 333 sprintf (number, "<%d>", ++count);
337 gentemp = concat2 (name, build_string (number)); 334 gentemp = concat2 (name, build_string (number));
338 tem = Fget_buffer (gentemp); 335 tem = Fget_buffer (gentemp);
339 if (NULL (tem)) 336 if (NILP (tem))
340 return gentemp; 337 return gentemp;
341 } 338 }
342} 339}
@@ -348,7 +345,7 @@ With no argument or nil as argument, return the name of the current buffer.")
348 (buffer) 345 (buffer)
349 register Lisp_Object buffer; 346 register Lisp_Object buffer;
350{ 347{
351 if (NULL (buffer)) 348 if (NILP (buffer))
352 return current_buffer->name; 349 return current_buffer->name;
353 CHECK_BUFFER (buffer, 0); 350 CHECK_BUFFER (buffer, 0);
354 return XBUFFER (buffer)->name; 351 return XBUFFER (buffer)->name;
@@ -360,7 +357,7 @@ No argument or nil as argument means use the current buffer.")
360 (buffer) 357 (buffer)
361 register Lisp_Object buffer; 358 register Lisp_Object buffer;
362{ 359{
363 if (NULL (buffer)) 360 if (NILP (buffer))
364 return current_buffer->filename; 361 return current_buffer->filename;
365 CHECK_BUFFER (buffer, 0); 362 CHECK_BUFFER (buffer, 0);
366 return XBUFFER (buffer)->filename; 363 return XBUFFER (buffer)->filename;
@@ -378,7 +375,7 @@ No argument or nil as argument means use current buffer as BUFFER.")
378 register struct buffer *buf; 375 register struct buffer *buf;
379 register Lisp_Object val; 376 register Lisp_Object val;
380 377
381 if (NULL (buffer)) 378 if (NILP (buffer))
382 buf = current_buffer; 379 buf = current_buffer;
383 else 380 else
384 { 381 {
@@ -433,7 +430,7 @@ No argument or nil as argument means use current buffer as BUFFER.")
433 register Lisp_Object buffer; 430 register Lisp_Object buffer;
434{ 431{
435 register struct buffer *buf; 432 register struct buffer *buf;
436 if (NULL (buffer)) 433 if (NILP (buffer))
437 buf = current_buffer; 434 buf = current_buffer;
438 else 435 else
439 { 436 {
@@ -459,17 +456,17 @@ A non-nil FLAG means mark the buffer modified.")
459 If buffer becoming unmodified, unlock the file. */ 456 If buffer becoming unmodified, unlock the file. */
460 457
461 fn = current_buffer->filename; 458 fn = current_buffer->filename;
462 if (!NULL (fn)) 459 if (!NILP (fn))
463 { 460 {
464 already = current_buffer->save_modified < MODIFF; 461 already = current_buffer->save_modified < MODIFF;
465 if (!already && !NULL (flag)) 462 if (!already && !NILP (flag))
466 lock_file (fn); 463 lock_file (fn);
467 else if (already && NULL (flag)) 464 else if (already && NILP (flag))
468 unlock_file (fn); 465 unlock_file (fn);
469 } 466 }
470#endif /* CLASH_DETECTION */ 467#endif /* CLASH_DETECTION */
471 468
472 current_buffer->save_modified = NULL (flag) ? MODIFF : 0; 469 current_buffer->save_modified = NILP (flag) ? MODIFF : 0;
473 update_mode_lines++; 470 update_mode_lines++;
474 return flag; 471 return flag;
475} 472}
@@ -484,7 +481,7 @@ No argument or nil as argument means use current buffer as BUFFER.")
484 register Lisp_Object buffer; 481 register Lisp_Object buffer;
485{ 482{
486 register struct buffer *buf; 483 register struct buffer *buf;
487 if (NULL (buffer)) 484 if (NILP (buffer))
488 buf = current_buffer; 485 buf = current_buffer;
489 else 486 else
490 { 487 {
@@ -513,9 +510,9 @@ This does not change the name of the visited file (if any).")
513 tem = Fget_buffer (name); 510 tem = Fget_buffer (name);
514 if (XBUFFER (tem) == current_buffer) 511 if (XBUFFER (tem) == current_buffer)
515 return current_buffer->name; 512 return current_buffer->name;
516 if (!NULL (tem)) 513 if (!NILP (tem))
517 { 514 {
518 if (!NULL (distinguish)) 515 if (!NILP (distinguish))
519 name = Fgenerate_new_buffer_name (name); 516 name = Fgenerate_new_buffer_name (name);
520 else 517 else
521 error ("Buffer name \"%s\" is in use", XSTRING (name)->data); 518 error ("Buffer name \"%s\" is in use", XSTRING (name)->data);
@@ -524,7 +521,7 @@ This does not change the name of the visited file (if any).")
524 current_buffer->name = name; 521 current_buffer->name = name;
525 XSET (buf, Lisp_Buffer, current_buffer); 522 XSET (buf, Lisp_Buffer, current_buffer);
526 Fsetcar (Frassq (buf, Vbuffer_alist), name); 523 Fsetcar (Frassq (buf, Vbuffer_alist), name);
527 if (NULL (current_buffer->filename) && !NULL (current_buffer->auto_save_file_name)) 524 if (NILP (current_buffer->filename) && !NILP (current_buffer->auto_save_file_name))
528 call0 (intern ("rename-auto-save-file")); 525 call0 (intern ("rename-auto-save-file"));
529 return name; 526 return name;
530} 527}
@@ -540,7 +537,7 @@ If BUFFER is omitted or nil, some interesting buffer is returned.")
540 register Lisp_Object tail, buf, notsogood, tem; 537 register Lisp_Object tail, buf, notsogood, tem;
541 notsogood = Qnil; 538 notsogood = Qnil;
542 539
543 for (tail = Vbuffer_alist; !NULL (tail); tail = Fcdr (tail)) 540 for (tail = Vbuffer_alist; !NILP (tail); tail = Fcdr (tail))
544 { 541 {
545 buf = Fcdr (Fcar (tail)); 542 buf = Fcdr (Fcar (tail));
546 if (EQ (buf, buffer)) 543 if (EQ (buf, buffer))
@@ -548,12 +545,12 @@ If BUFFER is omitted or nil, some interesting buffer is returned.")
548 if (XSTRING (XBUFFER (buf)->name)->data[0] == ' ') 545 if (XSTRING (XBUFFER (buf)->name)->data[0] == ' ')
549 continue; 546 continue;
550 tem = Fget_buffer_window (buf, Qnil); 547 tem = Fget_buffer_window (buf, Qnil);
551 if (NULL (tem)) 548 if (NILP (tem))
552 return buf; 549 return buf;
553 if (NULL (notsogood)) 550 if (NILP (notsogood))
554 notsogood = buf; 551 notsogood = buf;
555 } 552 }
556 if (!NULL (notsogood)) 553 if (!NILP (notsogood))
557 return notsogood; 554 return notsogood;
558 return Fget_buffer_create (build_string ("*scratch*")); 555 return Fget_buffer_create (build_string ("*scratch*"));
559} 556}
@@ -579,12 +576,12 @@ No argument or nil as argument means do this for the current buffer.")
579 register struct buffer *b; 576 register struct buffer *b;
580 register Lisp_Object buf1; 577 register Lisp_Object buf1;
581 578
582 if (NULL (buf)) 579 if (NILP (buf))
583 b = current_buffer; 580 b = current_buffer;
584 else 581 else
585 { 582 {
586 buf1 = Fget_buffer (buf); 583 buf1 = Fget_buffer (buf);
587 if (NULL (buf1)) nsberror (buf); 584 if (NILP (buf1)) nsberror (buf);
588 b = XBUFFER (buf1); 585 b = XBUFFER (buf1);
589 } 586 }
590 587
@@ -620,24 +617,24 @@ with `delete-process'.")
620 register struct Lisp_Marker *m; 617 register struct Lisp_Marker *m;
621 struct gcpro gcpro1, gcpro2; 618 struct gcpro gcpro1, gcpro2;
622 619
623 if (NULL (bufname)) 620 if (NILP (bufname))
624 buf = Fcurrent_buffer (); 621 buf = Fcurrent_buffer ();
625 else 622 else
626 buf = Fget_buffer (bufname); 623 buf = Fget_buffer (bufname);
627 if (NULL (buf)) 624 if (NILP (buf))
628 nsberror (bufname); 625 nsberror (bufname);
629 626
630 b = XBUFFER (buf); 627 b = XBUFFER (buf);
631 628
632 /* Query if the buffer is still modified. */ 629 /* Query if the buffer is still modified. */
633 if (INTERACTIVE && !NULL (b->filename) 630 if (INTERACTIVE && !NILP (b->filename)
634 && BUF_MODIFF (b) > b->save_modified) 631 && BUF_MODIFF (b) > b->save_modified)
635 { 632 {
636 GCPRO2 (buf, bufname); 633 GCPRO2 (buf, bufname);
637 tem = do_yes_or_no_p (format1 ("Buffer %s modified; kill anyway? ", 634 tem = do_yes_or_no_p (format1 ("Buffer %s modified; kill anyway? ",
638 XSTRING (b->name)->data)); 635 XSTRING (b->name)->data));
639 UNGCPRO; 636 UNGCPRO;
640 if (NULL (tem)) 637 if (NILP (tem))
641 return Qnil; 638 return Qnil;
642 } 639 }
643 640
@@ -660,7 +657,7 @@ with `delete-process'.")
660 if (EQ (buf, XWINDOW (minibuf_window)->buffer)) 657 if (EQ (buf, XWINDOW (minibuf_window)->buffer))
661 return Qnil; 658 return Qnil;
662 659
663 if (NULL (b->name)) 660 if (NILP (b->name))
664 return Qnil; 661 return Qnil;
665 662
666 /* Make this buffer not be current. 663 /* Make this buffer not be current.
@@ -696,7 +693,7 @@ with `delete-process'.")
696 { 693 {
697 Lisp_Object tem; 694 Lisp_Object tem;
698 tem = Fsymbol_value (intern ("delete-auto-save-files")); 695 tem = Fsymbol_value (intern ("delete-auto-save-files"));
699 if (! NULL (tem)) 696 if (! NILP (tem))
700 unlink (XSTRING (b->auto_save_file_name)->data); 697 unlink (XSTRING (b->auto_save_file_name)->data);
701 } 698 }
702 699
@@ -739,7 +736,7 @@ record_buffer (buf)
739 /* Effectively do Vbuffer_alist = Fdelq (link, Vbuffer_alist) 736 /* Effectively do Vbuffer_alist = Fdelq (link, Vbuffer_alist)
740 but cannot use Fdelq here it that allows quitting. */ 737 but cannot use Fdelq here it that allows quitting. */
741 738
742 if (NULL (prev)) 739 if (NILP (prev))
743 Vbuffer_alist = XCONS (Vbuffer_alist)->cdr; 740 Vbuffer_alist = XCONS (Vbuffer_alist)->cdr;
744 else 741 else
745 XCONS (prev)->cdr = XCONS (XCONS (prev)->cdr)->cdr; 742 XCONS (prev)->cdr = XCONS (XCONS (prev)->cdr)->cdr;
@@ -766,15 +763,15 @@ the window-buffer correspondences.")
766 if (EQ (minibuf_window, selected_window)) 763 if (EQ (minibuf_window, selected_window))
767 error ("Cannot switch buffers in minibuffer window"); 764 error ("Cannot switch buffers in minibuffer window");
768 tem = Fwindow_dedicated_p (selected_window); 765 tem = Fwindow_dedicated_p (selected_window);
769 if (!NULL (tem)) 766 if (!NILP (tem))
770 error ("Cannot switch buffers in a dedicated window"); 767 error ("Cannot switch buffers in a dedicated window");
771 768
772 if (NULL (bufname)) 769 if (NILP (bufname))
773 buf = Fother_buffer (Fcurrent_buffer ()); 770 buf = Fother_buffer (Fcurrent_buffer ());
774 else 771 else
775 buf = Fget_buffer_create (bufname); 772 buf = Fget_buffer_create (bufname);
776 Fset_buffer (buf); 773 Fset_buffer (buf);
777 if (NULL (norecord)) 774 if (NILP (norecord))
778 record_buffer (buf); 775 record_buffer (buf);
779 776
780 Fset_window_buffer (EQ (selected_window, minibuf_window) 777 Fset_window_buffer (EQ (selected_window, minibuf_window)
@@ -794,7 +791,7 @@ window even if BUFFER is already visible in the selected window.")
794 Lisp_Object bufname, other; 791 Lisp_Object bufname, other;
795{ 792{
796 register Lisp_Object buf; 793 register Lisp_Object buf;
797 if (NULL (bufname)) 794 if (NILP (bufname))
798 buf = Fother_buffer (Fcurrent_buffer ()); 795 buf = Fother_buffer (Fcurrent_buffer ());
799 else 796 else
800 buf = Fget_buffer_create (bufname); 797 buf = Fget_buffer_create (bufname);
@@ -834,7 +831,7 @@ set_buffer_internal (b)
834 /* Look down buffer's list of local Lisp variables 831 /* Look down buffer's list of local Lisp variables
835 to find and update any that forward into C variables. */ 832 to find and update any that forward into C variables. */
836 833
837 for (tail = b->local_var_alist; !NULL (tail); tail = XCONS (tail)->cdr) 834 for (tail = b->local_var_alist; !NILP (tail); tail = XCONS (tail)->cdr)
838 { 835 {
839 valcontents = XSYMBOL (XCONS (XCONS (tail)->car)->car)->value; 836 valcontents = XSYMBOL (XCONS (XCONS (tail)->car)->car)->value;
840 if ((XTYPE (valcontents) == Lisp_Buffer_Local_Value 837 if ((XTYPE (valcontents) == Lisp_Buffer_Local_Value
@@ -850,7 +847,7 @@ set_buffer_internal (b)
850 /* Do the same with any others that were local to the previous buffer */ 847 /* Do the same with any others that were local to the previous buffer */
851 848
852 if (old_buf) 849 if (old_buf)
853 for (tail = old_buf->local_var_alist; !NULL (tail); tail = XCONS (tail)->cdr) 850 for (tail = old_buf->local_var_alist; !NILP (tail); tail = XCONS (tail)->cdr)
854 { 851 {
855 valcontents = XSYMBOL (XCONS (XCONS (tail)->car)->car)->value; 852 valcontents = XSYMBOL (XCONS (XCONS (tail)->car)->car)->value;
856 if ((XTYPE (valcontents) == Lisp_Buffer_Local_Value 853 if ((XTYPE (valcontents) == Lisp_Buffer_Local_Value
@@ -876,9 +873,9 @@ Use `switch-to-buffer' or `pop-to-buffer' to switch buffers permanently.")
876{ 873{
877 register Lisp_Object buffer; 874 register Lisp_Object buffer;
878 buffer = Fget_buffer (bufname); 875 buffer = Fget_buffer (bufname);
879 if (NULL (buffer)) 876 if (NILP (buffer))
880 nsberror (bufname); 877 nsberror (bufname);
881 if (NULL (XBUFFER (buffer)->name)) 878 if (NILP (XBUFFER (buffer)->name))
882 error ("Selecting deleted buffer"); 879 error ("Selecting deleted buffer");
883 set_buffer_internal (XBUFFER (buffer)); 880 set_buffer_internal (XBUFFER (buffer));
884 return buffer; 881 return buffer;
@@ -889,7 +886,7 @@ DEFUN ("barf-if-buffer-read-only", Fbarf_if_buffer_read_only,
889 "Signal a `buffer-read-only' error if the current buffer is read-only.") 886 "Signal a `buffer-read-only' error if the current buffer is read-only.")
890 () 887 ()
891{ 888{
892 while (!NULL (current_buffer->read_only)) 889 while (!NILP (current_buffer->read_only))
893 Fsignal (Qbuffer_read_only, (Fcons (Fcurrent_buffer (), Qnil))); 890 Fsignal (Qbuffer_read_only, (Fcons (Fcurrent_buffer (), Qnil)));
894 return Qnil; 891 return Qnil;
895} 892}
@@ -903,7 +900,7 @@ thus, the least likely buffer for \\[switch-to-buffer] to select by default.")
903{ 900{
904 register Lisp_Object aelt, link; 901 register Lisp_Object aelt, link;
905 902
906 if (NULL (buf)) 903 if (NILP (buf))
907 { 904 {
908 XSET (buf, Lisp_Buffer, current_buffer); 905 XSET (buf, Lisp_Buffer, current_buffer);
909 Fswitch_to_buffer (Fother_buffer (buf), Qnil); 906 Fswitch_to_buffer (Fother_buffer (buf), Qnil);
@@ -913,7 +910,7 @@ thus, the least likely buffer for \\[switch-to-buffer] to select by default.")
913 Lisp_Object buf1; 910 Lisp_Object buf1;
914 911
915 buf1 = Fget_buffer (buf); 912 buf1 = Fget_buffer (buf);
916 if (NULL (buf1)) 913 if (NILP (buf1))
917 nsberror (buf); 914 nsberror (buf);
918 buf = buf1; 915 buf = buf1;
919 } 916 }
@@ -983,7 +980,7 @@ list_buffers_1 (files)
983 980
984 tail = intern ("Buffer-menu-mode"); 981 tail = intern ("Buffer-menu-mode");
985 if (!EQ (tail, current_buffer->major_mode) 982 if (!EQ (tail, current_buffer->major_mode)
986 && (tem = Ffboundp (tail), !NULL (tem))) 983 && (tem = Ffboundp (tail), !NILP (tem)))
987 call0 (tail); 984 call0 (tail);
988 Fbuffer_disable_undo (Vstandard_output); 985 Fbuffer_disable_undo (Vstandard_output);
989 current_buffer->read_only = Qnil; 986 current_buffer->read_only = Qnil;
@@ -992,7 +989,7 @@ list_buffers_1 (files)
992 MR Buffer Size Mode File\n\ 989 MR Buffer Size Mode File\n\
993 -- ------ ---- ---- ----\n", -1); 990 -- ------ ---- ---- ----\n", -1);
994 991
995 for (tail = Vbuffer_alist; !NULL (tail); tail = Fcdr (tail)) 992 for (tail = Vbuffer_alist; !NILP (tail); tail = Fcdr (tail))
996 { 993 {
997 buf = Fcdr (Fcar (tail)); 994 buf = Fcdr (Fcar (tail));
998 b = XBUFFER (buf); 995 b = XBUFFER (buf);
@@ -1000,7 +997,7 @@ list_buffers_1 (files)
1000 if (XSTRING (b->name)->data[0] == ' ') 997 if (XSTRING (b->name)->data[0] == ' ')
1001 continue; 998 continue;
1002 /* Optionally don't mention buffers that lack files. */ 999 /* Optionally don't mention buffers that lack files. */
1003 if (!NULL (files) && NULL (b->filename)) 1000 if (!NILP (files) && NILP (b->filename))
1004 continue; 1001 continue;
1005 /* Identify the current buffer. */ 1002 /* Identify the current buffer. */
1006 if (b == old) 1003 if (b == old)
@@ -1008,7 +1005,7 @@ list_buffers_1 (files)
1008 write_string (b == old ? "." : " ", -1); 1005 write_string (b == old ? "." : " ", -1);
1009 /* Identify modified buffers */ 1006 /* Identify modified buffers */
1010 write_string (BUF_MODIFF (b) > b->save_modified ? "*" : " ", -1); 1007 write_string (BUF_MODIFF (b) > b->save_modified ? "*" : " ", -1);
1011 write_string (NULL (b->read_only) ? " " : "% ", -1); 1008 write_string (NILP (b->read_only) ? " " : "% ", -1);
1012 Fprinc (b->name, Qnil); 1009 Fprinc (b->name, Qnil);
1013 Findent_to (col1, make_number (2)); 1010 Findent_to (col1, make_number (2));
1014 XFASTINT (tem) = BUF_Z (b) - BUF_BEG (b); 1011 XFASTINT (tem) = BUF_Z (b) - BUF_BEG (b);
@@ -1017,7 +1014,7 @@ list_buffers_1 (files)
1017 Fprinc (b->mode_name, Qnil); 1014 Fprinc (b->mode_name, Qnil);
1018 Findent_to (col3, minspace); 1015 Findent_to (col3, minspace);
1019 1016
1020 if (!NULL (b->filename)) 1017 if (!NILP (b->filename))
1021 Fprinc (b->filename, Qnil); 1018 Fprinc (b->filename, Qnil);
1022 else 1019 else
1023 { 1020 {
@@ -1025,7 +1022,7 @@ list_buffers_1 (files)
1025 Lisp_Object tem; 1022 Lisp_Object tem;
1026 set_buffer_internal (b); 1023 set_buffer_internal (b);
1027 tem = Fboundp (other_file_symbol); 1024 tem = Fboundp (other_file_symbol);
1028 if (!NULL (tem)) 1025 if (!NILP (tem))
1029 { 1026 {
1030 tem = Fsymbol_value (other_file_symbol); 1027 tem = Fsymbol_value (other_file_symbol);
1031 Fset_buffer (Vstandard_output); 1028 Fset_buffer (Vstandard_output);
@@ -1085,7 +1082,7 @@ a non-nil `permanent-local' property are not eliminated by this function.")
1085 /* Make sure no local variables remain set up with this buffer 1082 /* Make sure no local variables remain set up with this buffer
1086 for their current values. */ 1083 for their current values. */
1087 1084
1088 for (alist = oalist; !NULL (alist); alist = XCONS (alist)->cdr) 1085 for (alist = oalist; !NILP (alist); alist = XCONS (alist)->cdr)
1089 { 1086 {
1090 sym = XCONS (XCONS (alist)->car)->car; 1087 sym = XCONS (XCONS (alist)->car)->car;
1091 1088
@@ -1115,11 +1112,11 @@ a non-nil `permanent-local' property are not eliminated by this function.")
1115 /* Any which are supposed to be permanent, 1112 /* Any which are supposed to be permanent,
1116 make local again, with the same values they had. */ 1113 make local again, with the same values they had. */
1117 1114
1118 for (alist = oalist; !NULL (alist); alist = XCONS (alist)->cdr) 1115 for (alist = oalist; !NILP (alist); alist = XCONS (alist)->cdr)
1119 { 1116 {
1120 sym = XCONS (XCONS (alist)->car)->car; 1117 sym = XCONS (XCONS (alist)->car)->car;
1121 tem = Fget (sym, Qpermanent_local); 1118 tem = Fget (sym, Qpermanent_local);
1122 if (! NULL (tem)) 1119 if (! NILP (tem))
1123 { 1120 {
1124 Fmake_local_variable (sym); 1121 Fmake_local_variable (sym);
1125 Fset (sym, XCONS (XCONS (alist)->car)->cdr); 1122 Fset (sym, XCONS (XCONS (alist)->car)->cdr);
@@ -1146,7 +1143,7 @@ if any protected fields overlap this portion.")
1146 Lisp_Object fieldlist; 1143 Lisp_Object fieldlist;
1147 Lisp_Object collector; 1144 Lisp_Object collector;
1148 1145
1149 if (NULL (buffer)) 1146 if (NILP (buffer))
1150 fieldlist = current_buffer->fieldlist; 1147 fieldlist = current_buffer->fieldlist;
1151 else 1148 else
1152 { 1149 {
@@ -1174,9 +1171,9 @@ if any protected fields overlap this portion.")
1174 if ((start_loc < field_start && end_loc > field_start) 1171 if ((start_loc < field_start && end_loc > field_start)
1175 || (start_loc >= field_start && start_loc < field_end)) 1172 || (start_loc >= field_start && start_loc < field_end))
1176 { 1173 {
1177 if (!NULL (error_check)) 1174 if (!NILP (error_check))
1178 { 1175 {
1179 if (!NULL (FIELD_PROTECTED_FLAG (field))) 1176 if (!NILP (FIELD_PROTECTED_FLAG (field)))
1180 { 1177 {
1181 struct gcpro gcpro1; 1178 struct gcpro gcpro1;
1182 GCPRO1 (fieldlist); 1179 GCPRO1 (fieldlist);