Mercurial > emacs
comparison src/buffer.c @ 1909:ea6c75bc0d38
* buffer.c (Fswitch_to_buffer): Pass the correct number of
arguments to Fnext_window.
* buffer.c (Fbury_buffer): Pass the correct number of arguments to
Fother_buffer.
* buffer.c (buffer_slot_type_mismatch): Make symbol_name an
unsigned char *, to match the type of a string's data.
| author | Jim Blandy <jimb@redhat.com> |
|---|---|
| date | Mon, 22 Feb 1993 14:22:37 +0000 |
| parents | 0ddafa88e654 |
| children | b0ec61f76511 |
comparison
equal
deleted
inserted
replaced
| 1908:d649f2179d67 | 1909:ea6c75bc0d38 |
|---|---|
| 812 Fset_buffer (buf); | 812 Fset_buffer (buf); |
| 813 if (NILP (norecord)) | 813 if (NILP (norecord)) |
| 814 record_buffer (buf); | 814 record_buffer (buf); |
| 815 | 815 |
| 816 Fset_window_buffer (EQ (selected_window, minibuf_window) | 816 Fset_window_buffer (EQ (selected_window, minibuf_window) |
| 817 ? Fnext_window (minibuf_window, Qnil) : selected_window, | 817 ? Fnext_window (minibuf_window, Qnil, Qnil) |
| 818 : selected_window, | |
| 818 buf); | 819 buf); |
| 819 | 820 |
| 820 return Qnil; | 821 return Qnil; |
| 821 } | 822 } |
| 822 | 823 |
| 944 if (NILP (buf)) | 945 if (NILP (buf)) |
| 945 { | 946 { |
| 946 XSET (buf, Lisp_Buffer, current_buffer); | 947 XSET (buf, Lisp_Buffer, current_buffer); |
| 947 | 948 |
| 948 /* If we're burying the current buffer, unshow it. */ | 949 /* If we're burying the current buffer, unshow it. */ |
| 949 Fswitch_to_buffer (Fother_buffer (buf), Qnil); | 950 Fswitch_to_buffer (Fother_buffer (buf, Qnil), Qnil); |
| 950 } | 951 } |
| 951 else | 952 else |
| 952 { | 953 { |
| 953 Lisp_Object buf1; | 954 Lisp_Object buf1; |
| 954 | 955 |
| 1245 void | 1246 void |
| 1246 buffer_slot_type_mismatch (valcontents, newval) | 1247 buffer_slot_type_mismatch (valcontents, newval) |
| 1247 Lisp_Object valcontents, newval; | 1248 Lisp_Object valcontents, newval; |
| 1248 { | 1249 { |
| 1249 unsigned int offset = XUINT (valcontents); | 1250 unsigned int offset = XUINT (valcontents); |
| 1250 char *symbol_name = | 1251 unsigned char *symbol_name = |
| 1251 (XSYMBOL (*(Lisp_Object *)(offset + (char *)&buffer_local_symbols)) | 1252 (XSYMBOL (*(Lisp_Object *)(offset + (char *)&buffer_local_symbols)) |
| 1252 ->name->data); | 1253 ->name->data); |
| 1253 char *type_name; | 1254 char *type_name; |
| 1254 | 1255 |
| 1255 switch (XINT (*(Lisp_Object *)(offset + (char *)&buffer_local_types))) | 1256 switch (XINT (*(Lisp_Object *)(offset + (char *)&buffer_local_types))) |
| 1257 case Lisp_Int: type_name = "integers"; break; | 1258 case Lisp_Int: type_name = "integers"; break; |
| 1258 case Lisp_String: type_name = "strings"; break; | 1259 case Lisp_String: type_name = "strings"; break; |
| 1259 case Lisp_Marker: type_name = "markers"; break; | 1260 case Lisp_Marker: type_name = "markers"; break; |
| 1260 case Lisp_Symbol: type_name = "symbols"; break; | 1261 case Lisp_Symbol: type_name = "symbols"; break; |
| 1261 case Lisp_Cons: type_name = "lists"; break; | 1262 case Lisp_Cons: type_name = "lists"; break; |
| 1262 case Lisp_Vector: type_name = "vector"; break; | 1263 case Lisp_Vector: type_name = "vectors"; break; |
| 1263 default: | 1264 default: |
| 1264 abort (); | 1265 abort (); |
| 1265 } | 1266 } |
| 1266 | 1267 |
| 1267 error ("only %s should be stored in the buffer-local variable %s", | 1268 error ("only %s should be stored in the buffer-local variable %s", |
| 1622 Each window can have its own, overriding display table."); | 1623 Each window can have its own, overriding display table."); |
| 1623 | 1624 |
| 1624 DEFVAR_PER_BUFFER ("buffer-field-list", ¤t_buffer->fieldlist, Qnil, | 1625 DEFVAR_PER_BUFFER ("buffer-field-list", ¤t_buffer->fieldlist, Qnil, |
| 1625 "List of fields in the current buffer. See `add-field'."); | 1626 "List of fields in the current buffer. See `add-field'."); |
| 1626 | 1627 |
| 1627 DEFVAR_BOOL ("check-protected-fields", check_protected_fields, | 1628 DEFVAR_BOOL ("check-protected-fields", &check_protected_fields, |
| 1628 "Non-nil means don't allow modification of a protected field.\n\ | 1629 "Non-nil means don't allow modification of a protected field.\n\ |
| 1629 See `add-field'."); | 1630 See `add-field'."); |
| 1630 check_protected_fields = 0; | 1631 check_protected_fields = 0; |
| 1631 | 1632 |
| 1632 /*DEFVAR_LISP ("debug-check-symbol", &Vcheck_symbol, | 1633 /*DEFVAR_LISP ("debug-check-symbol", &Vcheck_symbol, |
