diff options
| author | Francesco Potortì | 2002-12-25 23:27:27 +0000 |
|---|---|---|
| committer | Francesco Potortì | 2002-12-25 23:27:27 +0000 |
| commit | bfb96cb7fa8e843124a186ca004de245c1c84d6f (patch) | |
| tree | 050326f3a9fd6044ab80423d55c2a88adc7310f8 /src/data.c | |
| parent | 2308af15ff3805deedcddd972d96364c9638e2e4 (diff) | |
| download | emacs-bfb96cb7fa8e843124a186ca004de245c1c84d6f.tar.gz emacs-bfb96cb7fa8e843124a186ca004de245c1c84d6f.zip | |
(Fmakunbound, Ffmakunbound, Fmake_variable_buffer_local)
(Fsetq_default, Fmake_local_variable, Fkill_local_variable)
(Fmake_variable_frame_local, Faset, Fnumber_to_string)
(Fstring_to_number, Fminus): Mention the returned value in the doc
strings.
Diffstat (limited to 'src/data.c')
| -rw-r--r-- | src/data.c | 50 |
1 files changed, 26 insertions, 24 deletions
diff --git a/src/data.c b/src/data.c index bde8ec3c831..5ccc3194b29 100644 --- a/src/data.c +++ b/src/data.c | |||
| @@ -628,7 +628,8 @@ DEFUN ("fboundp", Ffboundp, Sfboundp, 1, 1, 0, | |||
| 628 | } | 628 | } |
| 629 | 629 | ||
| 630 | DEFUN ("makunbound", Fmakunbound, Smakunbound, 1, 1, 0, | 630 | DEFUN ("makunbound", Fmakunbound, Smakunbound, 1, 1, 0, |
| 631 | doc: /* Make SYMBOL's value be void. */) | 631 | doc: /* Make SYMBOL's value be void. |
| 632 | Return SYMBOL. */) | ||
| 632 | (symbol) | 633 | (symbol) |
| 633 | register Lisp_Object symbol; | 634 | register Lisp_Object symbol; |
| 634 | { | 635 | { |
| @@ -640,7 +641,8 @@ DEFUN ("makunbound", Fmakunbound, Smakunbound, 1, 1, 0, | |||
| 640 | } | 641 | } |
| 641 | 642 | ||
| 642 | DEFUN ("fmakunbound", Ffmakunbound, Sfmakunbound, 1, 1, 0, | 643 | DEFUN ("fmakunbound", Ffmakunbound, Sfmakunbound, 1, 1, 0, |
| 643 | doc: /* Make SYMBOL's function definition be void. */) | 644 | doc: /* Make SYMBOL's function definition be void. |
| 645 | Return SYMBOL. */) | ||
| 644 | (symbol) | 646 | (symbol) |
| 645 | register Lisp_Object symbol; | 647 | register Lisp_Object symbol; |
| 646 | { | 648 | { |
| @@ -793,7 +795,7 @@ indirect_variable (symbol) | |||
| 793 | hare = XSYMBOL (hare)->value; | 795 | hare = XSYMBOL (hare)->value; |
| 794 | if (!XSYMBOL (hare)->indirect_variable) | 796 | if (!XSYMBOL (hare)->indirect_variable) |
| 795 | break; | 797 | break; |
| 796 | 798 | ||
| 797 | hare = XSYMBOL (hare)->value; | 799 | hare = XSYMBOL (hare)->value; |
| 798 | tortoise = XSYMBOL (tortoise)->value; | 800 | tortoise = XSYMBOL (tortoise)->value; |
| 799 | 801 | ||
| @@ -941,7 +943,7 @@ swap_in_global_binding (symbol) | |||
| 941 | Lisp_Object symbol; | 943 | Lisp_Object symbol; |
| 942 | { | 944 | { |
| 943 | Lisp_Object valcontents, cdr; | 945 | Lisp_Object valcontents, cdr; |
| 944 | 946 | ||
| 945 | valcontents = SYMBOL_VALUE (symbol); | 947 | valcontents = SYMBOL_VALUE (symbol); |
| 946 | if (!BUFFER_LOCAL_VALUEP (valcontents) | 948 | if (!BUFFER_LOCAL_VALUEP (valcontents) |
| 947 | && !SOME_BUFFER_LOCAL_VALUEP (valcontents)) | 949 | && !SOME_BUFFER_LOCAL_VALUEP (valcontents)) |
| @@ -951,7 +953,7 @@ swap_in_global_binding (symbol) | |||
| 951 | /* Unload the previously loaded binding. */ | 953 | /* Unload the previously loaded binding. */ |
| 952 | Fsetcdr (XCAR (cdr), | 954 | Fsetcdr (XCAR (cdr), |
| 953 | do_symval_forwarding (XBUFFER_LOCAL_VALUE (valcontents)->realvalue)); | 955 | do_symval_forwarding (XBUFFER_LOCAL_VALUE (valcontents)->realvalue)); |
| 954 | 956 | ||
| 955 | /* Select the global binding in the symbol. */ | 957 | /* Select the global binding in the symbol. */ |
| 956 | XSETCAR (cdr, cdr); | 958 | XSETCAR (cdr, cdr); |
| 957 | store_symval_forwarding (symbol, valcontents, XCDR (cdr), NULL); | 959 | store_symval_forwarding (symbol, valcontents, XCDR (cdr), NULL); |
| @@ -975,7 +977,7 @@ swap_in_symval_forwarding (symbol, valcontents) | |||
| 975 | Lisp_Object symbol, valcontents; | 977 | Lisp_Object symbol, valcontents; |
| 976 | { | 978 | { |
| 977 | register Lisp_Object tem1; | 979 | register Lisp_Object tem1; |
| 978 | 980 | ||
| 979 | tem1 = XBUFFER_LOCAL_VALUE (valcontents)->buffer; | 981 | tem1 = XBUFFER_LOCAL_VALUE (valcontents)->buffer; |
| 980 | 982 | ||
| 981 | if (NILP (tem1) | 983 | if (NILP (tem1) |
| @@ -985,7 +987,7 @@ swap_in_symval_forwarding (symbol, valcontents) | |||
| 985 | { | 987 | { |
| 986 | if (XSYMBOL (symbol)->indirect_variable) | 988 | if (XSYMBOL (symbol)->indirect_variable) |
| 987 | symbol = indirect_variable (symbol); | 989 | symbol = indirect_variable (symbol); |
| 988 | 990 | ||
| 989 | /* Unload the previously loaded binding. */ | 991 | /* Unload the previously loaded binding. */ |
| 990 | tem1 = XCAR (XBUFFER_LOCAL_VALUE (valcontents)->cdr); | 992 | tem1 = XCAR (XBUFFER_LOCAL_VALUE (valcontents)->cdr); |
| 991 | Fsetcdr (tem1, | 993 | Fsetcdr (tem1, |
| @@ -1029,7 +1031,7 @@ find_symbol_value (symbol) | |||
| 1029 | { | 1031 | { |
| 1030 | register Lisp_Object valcontents; | 1032 | register Lisp_Object valcontents; |
| 1031 | register Lisp_Object val; | 1033 | register Lisp_Object val; |
| 1032 | 1034 | ||
| 1033 | CHECK_SYMBOL (symbol); | 1035 | CHECK_SYMBOL (symbol); |
| 1034 | valcontents = SYMBOL_VALUE (symbol); | 1036 | valcontents = SYMBOL_VALUE (symbol); |
| 1035 | 1037 | ||
| @@ -1142,7 +1144,7 @@ set_internal (symbol, newval, buf, bindflag) | |||
| 1142 | return Fsignal (Qsetting_constant, Fcons (symbol, Qnil)); | 1144 | return Fsignal (Qsetting_constant, Fcons (symbol, Qnil)); |
| 1143 | 1145 | ||
| 1144 | innercontents = valcontents = SYMBOL_VALUE (symbol); | 1146 | innercontents = valcontents = SYMBOL_VALUE (symbol); |
| 1145 | 1147 | ||
| 1146 | if (BUFFER_OBJFWDP (valcontents)) | 1148 | if (BUFFER_OBJFWDP (valcontents)) |
| 1147 | { | 1149 | { |
| 1148 | int offset = XBUFFER_OBJFWD (valcontents)->offset; | 1150 | int offset = XBUFFER_OBJFWD (valcontents)->offset; |
| @@ -1365,7 +1367,7 @@ for this variable. */) | |||
| 1365 | if (idx > 0) | 1367 | if (idx > 0) |
| 1366 | { | 1368 | { |
| 1367 | struct buffer *b; | 1369 | struct buffer *b; |
| 1368 | 1370 | ||
| 1369 | for (b = all_buffers; b; b = b->next) | 1371 | for (b = all_buffers; b; b = b->next) |
| 1370 | if (!PER_BUFFER_VALUE_P (b, idx)) | 1372 | if (!PER_BUFFER_VALUE_P (b, idx)) |
| 1371 | PER_BUFFER_VALUE (b, offset) = value; | 1373 | PER_BUFFER_VALUE (b, offset) = value; |
| @@ -1395,7 +1397,7 @@ for this variable. */) | |||
| 1395 | DEFUN ("setq-default", Fsetq_default, Ssetq_default, 2, UNEVALLED, 0, | 1397 | DEFUN ("setq-default", Fsetq_default, Ssetq_default, 2, UNEVALLED, 0, |
| 1396 | doc: /* Set the default value of variable VAR to VALUE. | 1398 | doc: /* Set the default value of variable VAR to VALUE. |
| 1397 | VAR, the variable name, is literal (not evaluated); | 1399 | VAR, the variable name, is literal (not evaluated); |
| 1398 | VALUE is an expression and it is evaluated. | 1400 | VALUE is an expression: it is evaluated and its value returned. |
| 1399 | The default value of a variable is seen in buffers | 1401 | The default value of a variable is seen in buffers |
| 1400 | that do not have their own values for the variable. | 1402 | that do not have their own values for the variable. |
| 1401 | 1403 | ||
| @@ -1441,7 +1443,7 @@ unless the variable has never been set in this buffer, | |||
| 1441 | in which case the default value is in effect. | 1443 | in which case the default value is in effect. |
| 1442 | Note that binding the variable with `let', or setting it while | 1444 | Note that binding the variable with `let', or setting it while |
| 1443 | a `let'-style binding made in this buffer is in effect, | 1445 | a `let'-style binding made in this buffer is in effect, |
| 1444 | does not make the variable buffer-local. | 1446 | does not make the variable buffer-local. Return VARIABLE. |
| 1445 | 1447 | ||
| 1446 | The function `default-value' gets the default value and `set-default' sets it. */) | 1448 | The function `default-value' gets the default value and `set-default' sets it. */) |
| 1447 | (variable) | 1449 | (variable) |
| @@ -1485,7 +1487,7 @@ DEFUN ("make-local-variable", Fmake_local_variable, Smake_local_variable, | |||
| 1485 | Other buffers will continue to share a common default value. | 1487 | Other buffers will continue to share a common default value. |
| 1486 | \(The buffer-local value of VARIABLE starts out as the same value | 1488 | \(The buffer-local value of VARIABLE starts out as the same value |
| 1487 | VARIABLE previously had. If VARIABLE was void, it remains void.\) | 1489 | VARIABLE previously had. If VARIABLE was void, it remains void.\) |
| 1488 | See also `make-variable-buffer-local'. | 1490 | See also `make-variable-buffer-local'. Return VARIABLE. |
| 1489 | 1491 | ||
| 1490 | If the variable is already arranged to become local when set, | 1492 | If the variable is already arranged to become local when set, |
| 1491 | this function causes a local value to exist for this buffer, | 1493 | this function causes a local value to exist for this buffer, |
| @@ -1575,7 +1577,7 @@ Instead, use `add-hook' and specify t for the LOCAL argument. */) | |||
| 1575 | DEFUN ("kill-local-variable", Fkill_local_variable, Skill_local_variable, | 1577 | DEFUN ("kill-local-variable", Fkill_local_variable, Skill_local_variable, |
| 1576 | 1, 1, "vKill Local Variable: ", | 1578 | 1, 1, "vKill Local Variable: ", |
| 1577 | doc: /* Make VARIABLE no longer have a separate value in the current buffer. | 1579 | doc: /* Make VARIABLE no longer have a separate value in the current buffer. |
| 1578 | From now on the default value will apply in this buffer. */) | 1580 | From now on the default value will apply in this buffer. Return VARIABLE. */) |
| 1579 | (variable) | 1581 | (variable) |
| 1580 | register Lisp_Object variable; | 1582 | register Lisp_Object variable; |
| 1581 | { | 1583 | { |
| @@ -1636,8 +1638,8 @@ DEFUN ("make-variable-frame-local", Fmake_variable_frame_local, Smake_variable_f | |||
| 1636 | When a frame-local binding exists in the current frame, | 1638 | When a frame-local binding exists in the current frame, |
| 1637 | it is in effect whenever the current buffer has no buffer-local binding. | 1639 | it is in effect whenever the current buffer has no buffer-local binding. |
| 1638 | A frame-local binding is actually a frame parameter value; | 1640 | A frame-local binding is actually a frame parameter value; |
| 1639 | thus, any given frame has a local binding for VARIABLE | 1641 | thus, any given frame has a local binding for VARIABLE if it has |
| 1640 | if it has a value for the frame parameter named VARIABLE. | 1642 | a value for the frame parameter named VARIABLE. Return VARIABLE. |
| 1641 | See `modify-frame-parameters' for how to set frame parameters. */) | 1643 | See `modify-frame-parameters' for how to set frame parameters. */) |
| 1642 | (variable) | 1644 | (variable) |
| 1643 | register Lisp_Object variable; | 1645 | register Lisp_Object variable; |
| @@ -1950,8 +1952,8 @@ or a byte-code object. IDX starts at 0. */) | |||
| 1950 | 1952 | ||
| 1951 | DEFUN ("aset", Faset, Saset, 3, 3, 0, | 1953 | DEFUN ("aset", Faset, Saset, 3, 3, 0, |
| 1952 | doc: /* Store into the element of ARRAY at index IDX the value NEWELT. | 1954 | doc: /* Store into the element of ARRAY at index IDX the value NEWELT. |
| 1953 | ARRAY may be a vector, a string, a char-table or a bool-vector. | 1955 | Return NEWELT. ARRAY may be a vector, a string, a char-table or a |
| 1954 | IDX starts at 0. */) | 1956 | bool-vector. IDX starts at 0. */) |
| 1955 | (array, idx, newelt) | 1957 | (array, idx, newelt) |
| 1956 | register Lisp_Object array; | 1958 | register Lisp_Object array; |
| 1957 | Lisp_Object idx, newelt; | 1959 | Lisp_Object idx, newelt; |
| @@ -2267,7 +2269,7 @@ cons_to_long (c) | |||
| 2267 | } | 2269 | } |
| 2268 | 2270 | ||
| 2269 | DEFUN ("number-to-string", Fnumber_to_string, Snumber_to_string, 1, 1, 0, | 2271 | DEFUN ("number-to-string", Fnumber_to_string, Snumber_to_string, 1, 1, 0, |
| 2270 | doc: /* Convert NUMBER to a string by printing it in decimal. | 2272 | doc: /* Return the decimal representation of NUMBER as a string. |
| 2271 | Uses a minus sign if negative. | 2273 | Uses a minus sign if negative. |
| 2272 | NUMBER may be an integer or a floating point number. */) | 2274 | NUMBER may be an integer or a floating point number. */) |
| 2273 | (number) | 2275 | (number) |
| @@ -2313,10 +2315,10 @@ digit_to_number (character, base) | |||
| 2313 | return -1; | 2315 | return -1; |
| 2314 | else | 2316 | else |
| 2315 | return digit; | 2317 | return digit; |
| 2316 | } | 2318 | } |
| 2317 | 2319 | ||
| 2318 | DEFUN ("string-to-number", Fstring_to_number, Sstring_to_number, 1, 2, 0, | 2320 | DEFUN ("string-to-number", Fstring_to_number, Sstring_to_number, 1, 2, 0, |
| 2319 | doc: /* Convert STRING to a number by parsing it as a decimal number. | 2321 | doc: /* Return a number obtained by parsing STRING as a decimal number. |
| 2320 | This parses both integers and floating point numbers. | 2322 | This parses both integers and floating point numbers. |
| 2321 | It ignores leading spaces and tabs. | 2323 | It ignores leading spaces and tabs. |
| 2322 | 2324 | ||
| @@ -2356,7 +2358,7 @@ If the base used is not 10, floating point is not recognized. */) | |||
| 2356 | } | 2358 | } |
| 2357 | else if (*p == '+') | 2359 | else if (*p == '+') |
| 2358 | p++; | 2360 | p++; |
| 2359 | 2361 | ||
| 2360 | if (isfloat_string (p) && b == 10) | 2362 | if (isfloat_string (p) && b == 10) |
| 2361 | val = make_float (sign * atof (p)); | 2363 | val = make_float (sign * atof (p)); |
| 2362 | else | 2364 | else |
| @@ -2559,7 +2561,7 @@ usage: (+ &rest NUMBERS-OR-MARKERS) */) | |||
| 2559 | } | 2561 | } |
| 2560 | 2562 | ||
| 2561 | DEFUN ("-", Fminus, Sminus, 0, MANY, 0, | 2563 | DEFUN ("-", Fminus, Sminus, 0, MANY, 0, |
| 2562 | doc: /* Negate number or subtract numbers or markers. | 2564 | doc: /* Negate number or subtract numbers or markers, returns the result. |
| 2563 | With one arg, negates it. With more than one arg, | 2565 | With one arg, negates it. With more than one arg, |
| 2564 | subtracts all but the first from the first. | 2566 | subtracts all but the first from the first. |
| 2565 | usage: (- &optional NUMBER-OR-MARKER &rest MORE-NUMBERS-OR-MARKERS) */) | 2567 | usage: (- &optional NUMBER-OR-MARKER &rest MORE-NUMBERS-OR-MARKERS) */) |
| @@ -3212,7 +3214,7 @@ syms_of_data () | |||
| 3212 | DEFVAR_LISP ("most-positive-fixnum", &Vmost_positive_fixnum, | 3214 | DEFVAR_LISP ("most-positive-fixnum", &Vmost_positive_fixnum, |
| 3213 | doc: /* The largest value that is representable in a Lisp integer. */); | 3215 | doc: /* The largest value that is representable in a Lisp integer. */); |
| 3214 | Vmost_positive_fixnum = make_number (MOST_POSITIVE_FIXNUM); | 3216 | Vmost_positive_fixnum = make_number (MOST_POSITIVE_FIXNUM); |
| 3215 | 3217 | ||
| 3216 | DEFVAR_LISP ("most-negative-fixnum", &Vmost_negative_fixnum, | 3218 | DEFVAR_LISP ("most-negative-fixnum", &Vmost_negative_fixnum, |
| 3217 | doc: /* The smallest value that is representable in a Lisp integer. */); | 3219 | doc: /* The smallest value that is representable in a Lisp integer. */); |
| 3218 | Vmost_negative_fixnum = make_number (MOST_NEGATIVE_FIXNUM); | 3220 | Vmost_negative_fixnum = make_number (MOST_NEGATIVE_FIXNUM); |