aboutsummaryrefslogtreecommitdiffstats
path: root/src/ChangeLog
diff options
context:
space:
mode:
Diffstat (limited to 'src/ChangeLog')
-rw-r--r--src/ChangeLog52
1 files changed, 29 insertions, 23 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 7eaa153f79a..2b9978f3d6a 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,32 @@
12011-04-21 Paul Eggert <eggert@cs.ucla.edu>
2
3 Make the Lisp reader and string-to-float more consistent.
4 * data.c (atof): Remove decl; no longer used or needed.
5 (digit_to_number): Move to lread.c.
6 (Fstring_to_number): Use new string_to_number function, to be
7 consistent with how the Lisp reader treats infinities and NaNs.
8 Do not assume that floating-point numbers represent EMACS_INT
9 without losing information; this is not true on most 64-bit hosts.
10 Avoid double-rounding errors, by insisting on integers when
11 parsing non-base-10 numbers, as the documentation specifies.
12 * lisp.h (string_to_number): New decl, replacing ...
13 (isfloat_string): Remove.
14 * lread.c (read1): Do not accept +. and -. as integers; this
15 appears to have been a coding error. Similarly, do not accept
16 strings like +-1e0 as floating point numbers. Do not report
17 overflow for integer overflows unless the base is not 10 which
18 means we have no simple and reliable way to continue.
19 Break out the floating-point parsing into a new
20 function string_to_number, so that Fstring_to_number parses
21 floating point numbers consistently with the Lisp reader.
22 (digit_to_number): Moved here from data.c. Make it static inline.
23 (E_CHAR, EXP_INT): Remove, replacing with ...
24 (E_EXP): New macro, to solve the "1.0e+" problem mentioned below.
25 (string_to_number): New function, replacing isfloat_string.
26 This function checks for valid syntax and produces the resulting
27 Lisp float number too. Rework it so that string-to-number
28 no longer mishandles examples like "1.0e+".
29
12011-04-20 Paul Eggert <eggert@cs.ucla.edu> 302011-04-20 Paul Eggert <eggert@cs.ucla.edu>
2 31
3 * textprop.c (set_text_properties_1): Rewrite for clarity, 32 * textprop.c (set_text_properties_1): Rewrite for clarity,
@@ -15,29 +44,6 @@
15 * alloc.c (overrun_check_malloc, overrun_check_realloc): Now static. 44 * alloc.c (overrun_check_malloc, overrun_check_realloc): Now static.
16 (overrun_check_free): Likewise. 45 (overrun_check_free): Likewise.
17 46
18 Make the Lisp reader and string-to-float more consistent.
19 * data.c (atof): Remove decl; no longer used or needed.
20 (Fstring_to_number): Use new string_to_float function, to be
21 consistent with how the Lisp reader treats infinities and NaNs.
22 Do not assume that floating-point numbers represent EMACS_INT
23 without losing information; this is not true on most 64-bit hosts.
24 Avoid double-rounding errors, by insisting on integers when
25 parsing non-base-10 numbers, as the documentation specifies.
26 Report integer overflow instead of silently converting to
27 integers.
28 * lisp.h (string_to_float): New decl, replacing ...
29 (isfloat_string): Remove.
30 * lread.c (read1): Do not accept +. and -. as integers; this
31 appears to have been a coding error. Similarly, do not accept
32 strings like +-1e0 as floating point numbers. Do not report
33 overflow for some integer overflows and not others; instead,
34 report them all. Break out the floating-point parsing into a new
35 function string_to_float, so that Fstring_to_number parses
36 floating point numbers consistently with the Lisp reader.
37 (string_to_float): New function, replacing isfloat_string.
38 This function checks for valid syntax and produces the resulting
39 Lisp float number too.
40
41 * alloc.c (SDATA_SIZE) [!GC_CHECK_STRING_BYTES]: Avoid runtime check 47 * alloc.c (SDATA_SIZE) [!GC_CHECK_STRING_BYTES]: Avoid runtime check
42 in the common case where SDATA_DATA_OFFSET is a multiple of Emacs 48 in the common case where SDATA_DATA_OFFSET is a multiple of Emacs
43 word size. 49 word size.