diff options
| author | Paul Eggert | 2014-01-26 11:44:23 -0800 |
|---|---|---|
| committer | Paul Eggert | 2014-01-26 11:44:23 -0800 |
| commit | 12cb2b063b93f17c8eed86cbf01f9df73e210626 (patch) | |
| tree | a1232d5ef5792057b79316401513ed096abf8118 | |
| parent | 748650f08713a4ad2c130e39d672ba64bcab4f24 (diff) | |
| download | emacs-12cb2b063b93f17c8eed86cbf01f9df73e210626.tar.gz emacs-12cb2b063b93f17c8eed86cbf01f9df73e210626.zip | |
* data.c (Fstring_to_number): Document results if unparsable.
Fixes: debbugs:16551
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/data.c | 6 |
2 files changed, 8 insertions, 3 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 4ed9ef9d2cf..4fa19d98f7f 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2014-01-26 Paul Eggert <eggert@cs.ucla.edu> | ||
| 2 | |||
| 3 | * data.c (Fstring_to_number): Document results if unparsable | ||
| 4 | (Bug#16551). | ||
| 5 | |||
| 1 | 2014-01-26 Jan Djärv <jan.h.d@swipnet.se> | 6 | 2014-01-26 Jan Djärv <jan.h.d@swipnet.se> |
| 2 | 7 | ||
| 3 | * xterm.c (x_focus_changed): Check for non-X terminal-frame (Bug#16540) | 8 | * xterm.c (x_focus_changed): Check for non-X terminal-frame (Bug#16540) |
diff --git a/src/data.c b/src/data.c index 2a64c1bbf82..91a1d8b75fb 100644 --- a/src/data.c +++ b/src/data.c | |||
| @@ -2523,12 +2523,12 @@ NUMBER may be an integer or a floating point number. */) | |||
| 2523 | 2523 | ||
| 2524 | DEFUN ("string-to-number", Fstring_to_number, Sstring_to_number, 1, 2, 0, | 2524 | DEFUN ("string-to-number", Fstring_to_number, Sstring_to_number, 1, 2, 0, |
| 2525 | doc: /* Parse STRING as a decimal number and return the number. | 2525 | doc: /* Parse STRING as a decimal number and return the number. |
| 2526 | This parses both integers and floating point numbers. | 2526 | Ignore leading spaces and tabs, and all trailing chars. Return 0 if |
| 2527 | It ignores leading spaces and tabs, and all trailing chars. | 2527 | STRING cannot be parsed as an integer or floating point number. |
| 2528 | 2528 | ||
| 2529 | If BASE, interpret STRING as a number in that base. If BASE isn't | 2529 | If BASE, interpret STRING as a number in that base. If BASE isn't |
| 2530 | present, base 10 is used. BASE must be between 2 and 16 (inclusive). | 2530 | present, base 10 is used. BASE must be between 2 and 16 (inclusive). |
| 2531 | If the base used is not 10, STRING is always parsed as integer. */) | 2531 | If the base used is not 10, STRING is always parsed as an integer. */) |
| 2532 | (register Lisp_Object string, Lisp_Object base) | 2532 | (register Lisp_Object string, Lisp_Object base) |
| 2533 | { | 2533 | { |
| 2534 | register char *p; | 2534 | register char *p; |