diff options
| author | Erik Naggum | 1996-01-09 00:30:29 +0000 |
|---|---|---|
| committer | Erik Naggum | 1996-01-09 00:30:29 +0000 |
| commit | a2428fa2a27155a5f4c75105d2b3975d2af5f0f7 (patch) | |
| tree | 887840e23760fa9da440c0d263b0f44c2d8b4b4b /src/buffer.c | |
| parent | 78ce396ad19963920ae3b5544474760e581996d5 (diff) | |
| download | emacs-a2428fa2a27155a5f4c75105d2b3975d2af5f0f7.tar.gz emacs-a2428fa2a27155a5f4c75105d2b3975d2af5f0f7.zip | |
(Fmake_indirect_buffer, Fset_buffer_major_mode, Fpop_to_buffer,
Fbury_buffer, Foverlay_get): Harmonize arguments with documentation.
Diffstat (limited to 'src/buffer.c')
| -rw-r--r-- | src/buffer.c | 41 |
1 files changed, 20 insertions, 21 deletions
diff --git a/src/buffer.c b/src/buffer.c index b1005afe24d..6c2c7e8bd30 100644 --- a/src/buffer.c +++ b/src/buffer.c | |||
| @@ -336,11 +336,10 @@ The value is never nil.") | |||
| 336 | return buf; | 336 | return buf; |
| 337 | } | 337 | } |
| 338 | 338 | ||
| 339 | DEFUN ("make-indirect-buffer", | 339 | DEFUN ("make-indirect-buffer", Fmake_indirect_buffer, Smake_indirect_buffer, 2, 2, |
| 340 | Fmake_indirect_buffer, Smake_indirect_buffer, 2, 2, | ||
| 341 | "bMake indirect buffer (to buffer): \nBName of indirect buffer: ", | 340 | "bMake indirect buffer (to buffer): \nBName of indirect buffer: ", |
| 342 | "Create and return an indirect buffer for buffer BASE, named NAME.\n\ | 341 | "Create and return an indirect buffer for buffer BASE-BUFFER, named NAME.\n\ |
| 343 | BASE should be an existing buffer (or buffer name).\n\ | 342 | BASE-BUFFER should be an existing buffer (or buffer name).\n\ |
| 344 | NAME should be a string which is not the name of an existing buffer.") | 343 | NAME should be a string which is not the name of an existing buffer.") |
| 345 | (base_buffer, name) | 344 | (base_buffer, name) |
| 346 | register Lisp_Object base_buffer, name; | 345 | register Lisp_Object base_buffer, name; |
| @@ -1136,8 +1135,8 @@ DEFUN ("set-buffer-major-mode", Fset_buffer_major_mode, Sset_buffer_major_mode, | |||
| 1136 | "Set an appropriate major mode for BUFFER, according to `default-major-mode'.\n\ | 1135 | "Set an appropriate major mode for BUFFER, according to `default-major-mode'.\n\ |
| 1137 | Use this function before selecting the buffer, since it may need to inspect\n\ | 1136 | Use this function before selecting the buffer, since it may need to inspect\n\ |
| 1138 | the current buffer's major mode.") | 1137 | the current buffer's major mode.") |
| 1139 | (buf) | 1138 | (buffer) |
| 1140 | Lisp_Object buf; | 1139 | Lisp_Object buffer; |
| 1141 | { | 1140 | { |
| 1142 | int count; | 1141 | int count; |
| 1143 | Lisp_Object function; | 1142 | Lisp_Object function; |
| @@ -1156,7 +1155,7 @@ the current buffer's major mode.") | |||
| 1156 | 1155 | ||
| 1157 | record_unwind_protect (save_excursion_restore, save_excursion_save ()); | 1156 | record_unwind_protect (save_excursion_restore, save_excursion_save ()); |
| 1158 | 1157 | ||
| 1159 | Fset_buffer (buf); | 1158 | Fset_buffer (buffer); |
| 1160 | call0 (function); | 1159 | call0 (function); |
| 1161 | 1160 | ||
| 1162 | return unbind_to (count, Qnil); | 1161 | return unbind_to (count, Qnil); |
| @@ -1212,8 +1211,8 @@ If BUFFER is nil, then some other buffer is chosen.\n\ | |||
| 1212 | If `pop-up-windows' is non-nil, windows can be split to do this.\n\ | 1211 | If `pop-up-windows' is non-nil, windows can be split to do this.\n\ |
| 1213 | If optional second arg OTHER-WINDOW is non-nil, insist on finding another\n\ | 1212 | If optional second arg OTHER-WINDOW is non-nil, insist on finding another\n\ |
| 1214 | window even if BUFFER is already visible in the selected window.") | 1213 | window even if BUFFER is already visible in the selected window.") |
| 1215 | (buffer, other) | 1214 | (buffer, other_window) |
| 1216 | Lisp_Object buffer, other; | 1215 | Lisp_Object buffer, other_window; |
| 1217 | { | 1216 | { |
| 1218 | register Lisp_Object buf; | 1217 | register Lisp_Object buf; |
| 1219 | if (NILP (buffer)) | 1218 | if (NILP (buffer)) |
| @@ -1229,7 +1228,7 @@ window even if BUFFER is already visible in the selected window.") | |||
| 1229 | } | 1228 | } |
| 1230 | Fset_buffer (buf); | 1229 | Fset_buffer (buf); |
| 1231 | record_buffer (buf); | 1230 | record_buffer (buf); |
| 1232 | Fselect_window (Fdisplay_buffer (buf, other)); | 1231 | Fselect_window (Fdisplay_buffer (buf, other_window)); |
| 1233 | return buf; | 1232 | return buf; |
| 1234 | } | 1233 | } |
| 1235 | 1234 | ||
| @@ -1438,32 +1437,32 @@ thus, the least likely buffer for \\[switch-to-buffer] to select by default.\n\ | |||
| 1438 | If BUFFER is nil or omitted, bury the current buffer.\n\ | 1437 | If BUFFER is nil or omitted, bury the current buffer.\n\ |
| 1439 | Also, if BUFFER is nil or omitted, remove the current buffer from the\n\ | 1438 | Also, if BUFFER is nil or omitted, remove the current buffer from the\n\ |
| 1440 | selected window if it is displayed there.") | 1439 | selected window if it is displayed there.") |
| 1441 | (buf) | 1440 | (buffer) |
| 1442 | register Lisp_Object buf; | 1441 | register Lisp_Object buffer; |
| 1443 | { | 1442 | { |
| 1444 | /* Figure out what buffer we're going to bury. */ | 1443 | /* Figure out what buffer we're going to bury. */ |
| 1445 | if (NILP (buf)) | 1444 | if (NILP (buffer)) |
| 1446 | { | 1445 | { |
| 1447 | XSETBUFFER (buf, current_buffer); | 1446 | XSETBUFFER (buffer, current_buffer); |
| 1448 | 1447 | ||
| 1449 | /* If we're burying the current buffer, unshow it. */ | 1448 | /* If we're burying the current buffer, unshow it. */ |
| 1450 | Fswitch_to_buffer (Fother_buffer (buf, Qnil), Qnil); | 1449 | Fswitch_to_buffer (Fother_buffer (buffer, Qnil), Qnil); |
| 1451 | } | 1450 | } |
| 1452 | else | 1451 | else |
| 1453 | { | 1452 | { |
| 1454 | Lisp_Object buf1; | 1453 | Lisp_Object buf1; |
| 1455 | 1454 | ||
| 1456 | buf1 = Fget_buffer (buf); | 1455 | buf1 = Fget_buffer (buffer); |
| 1457 | if (NILP (buf1)) | 1456 | if (NILP (buf1)) |
| 1458 | nsberror (buf); | 1457 | nsberror (buffer); |
| 1459 | buf = buf1; | 1458 | buffer = buf1; |
| 1460 | } | 1459 | } |
| 1461 | 1460 | ||
| 1462 | /* Move buf to the end of the buffer list. */ | 1461 | /* Move buffer to the end of the buffer list. */ |
| 1463 | { | 1462 | { |
| 1464 | register Lisp_Object aelt, link; | 1463 | register Lisp_Object aelt, link; |
| 1465 | 1464 | ||
| 1466 | aelt = Frassq (buf, Vbuffer_alist); | 1465 | aelt = Frassq (buffer, Vbuffer_alist); |
| 1467 | link = Fmemq (aelt, Vbuffer_alist); | 1466 | link = Fmemq (aelt, Vbuffer_alist); |
| 1468 | Vbuffer_alist = Fdelq (aelt, Vbuffer_alist); | 1467 | Vbuffer_alist = Fdelq (aelt, Vbuffer_alist); |
| 1469 | XCONS (link)->cdr = Qnil; | 1468 | XCONS (link)->cdr = Qnil; |
| @@ -2932,7 +2931,7 @@ DEFUN ("overlay-recenter", Foverlay_recenter, Soverlay_recenter, 1, 1, 0, | |||
| 2932 | } | 2931 | } |
| 2933 | 2932 | ||
| 2934 | DEFUN ("overlay-get", Foverlay_get, Soverlay_get, 2, 2, 0, | 2933 | DEFUN ("overlay-get", Foverlay_get, Soverlay_get, 2, 2, 0, |
| 2935 | "Get the property of overlay OVERLAY with property name NAME.") | 2934 | "Get the property of overlay OVERLAY with property name PROP.") |
| 2936 | (overlay, prop) | 2935 | (overlay, prop) |
| 2937 | Lisp_Object overlay, prop; | 2936 | Lisp_Object overlay, prop; |
| 2938 | { | 2937 | { |