Commit | Line | Data |
---|---|---|
5ec82e96 KR |
1 | 2004-08-02 Kevin Ryde <user42@zip.com.au> |
2 | ||
3 | * __scm.h (SCM_DEFER_INTS, SCM_ALLOW_INTS): Add comments about past | |
4 | and current usage and migration. | |
5 | ||
58f28989 KR |
6 | 2004-07-31 Kevin Ryde <user42@zip.com.au> |
7 | ||
8 | * error.c (scm_strerror): Use scm_i_misc_mutex around strerror since | |
9 | it's not thread safe. | |
10 | (scm_syserror): Use scm_strerror rather than SCM_I_STRERROR, to take | |
11 | advantage of this. | |
12 | * fports.c (scm_open_file): Use scm_strerror likewise. | |
13 | * filesys.c (scm_stat, scm_lstat): Ditto. | |
14 | ||
15 | * filesys.c (scm_copy_file): Avoid fd leak when destination file | |
16 | cannot be opened. | |
17 | ||
18 | * symbols.c (scm_gensym): Use scm_i_misc_mutex around gensym_counter | |
19 | update, for thread safety. | |
20 | (gensym_counter): Move into scm_gensym which is its only user. | |
21 | (scm_init_symbols): No need to explicitly initialize gensym_counter. | |
22 | ||
03696aab MV |
23 | 2004-07-29 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
24 | ||
51fdb325 MV |
25 | * numbers.h (scm_to_schar, scm_to_uchar, scm_to_char, |
26 | scm_to_short, scm_to_ushort, scm_to_int, scm_to_uint, scm_to_long, | |
27 | scm_to_ulong, scm_to_long_long, scm_to_ulong_long, scm_to_intmax, | |
28 | scm_to_uintmax, scm_to_size_t, scm_to_ssize_t scm_from_schar, | |
29 | scm_from_uchar, scm_from_char, scm_from_short, scm_from_ushort, | |
30 | scm_from_int, scm_from_uint, scm_from_long, scm_from_ulong, | |
31 | scm_from_long_long, scm_from_ulong_long, scm_from_intmax, | |
32 | scm_from_uintmax, scm_from_size_t, scm_from_ssize_t): No longer | |
33 | defined in terms of scm_to_signed_integer, etc, but in terms of | |
34 | scm_to_int8, etc. | |
35 | ||
36 | * gen-scmconfig.c (SCM_SIZEOF_INTMAX, SCM_SIZEOF_SIZE_T): New. | |
37 | ||
03696aab MV |
38 | * gen-scmconfig.h.in: Removed SCM_I_GSC_*_LIMITS macros, they are |
39 | no longer used. | |
40 | ||
41 | * __scm.h (SCM_I_UTYPE_MAX, SCM_I_TYPE_MAX, SCM_I_TYPE_MIN, | |
42 | SCM_I_SIZE_MAX, SCM_I_SSIZE_MIN, SCM_I_SSIZE_MAX): New. | |
43 | ||
44 | * __scm.h, gen-scmconfig.c (SCM_I_LLONG_MAX, SCM_I_LLONG_MIN, | |
45 | SCM_I_ULLONG_MAX, SCM_T_INT8_MIN, SCM_T_INT8_MAX, SCM_T_UINT8_MAX, | |
46 | SCM_T_INT16_MIN, SCM_T_INT16_MAX, SCM_T_UINT16_MAX, | |
47 | SCM_T_INT32_MIN, SCM_T_INT32_MAX, SCM_T_UINT32_MAX, | |
48 | SCM_T_INT64_MIN, SCM_T_INT64_MAX, SCM_T_UINT64_MAX, | |
49 | SCM_T_INTMAX_MIN, SCM_T_INTMAX_MAX, SCM_T_UINTMAX_MAX): Moved | |
50 | definition into __scm.h, using new SCM_I_TYPE_MIN, etc. | |
51 | ||
52 | * conv-integer.i.c, conv-uinteger.i.c: New files, used to generate | |
53 | the functions below. | |
54 | ||
55 | * Makefile.am (noinst_HEADERS): Added conv-integer.i.c and | |
56 | conv-uinteger.i.c. | |
57 | ||
58 | * numbers.c, numbers.h (scm_to_int8, scm_to_uint8, scm_to_int16, | |
59 | scm_to_uint16, scm_to_int32, scm_to_uint32, scm_to_int64, | |
60 | scm_to_uint64, scm_from_int8, scm_from_uint8, scm_from_int16, | |
61 | scm_from_uint16, scm_from_int32, scm_from_uint32, scm_from_int64, | |
62 | scm_from_uint64): Turned from macros into proper functions. | |
63 | (scm_to_signed_integer, scm_to_unsigned_integer, | |
64 | scm_from_signed_integer, scm_from_unsigned_integer): Generate via | |
65 | conv-integer.i.c and conv-uinteger.i.c, as well. | |
66 | ||
67 | * number.h (scm_to_ssize_t, scm_to_size_t): Use the new | |
68 | SCM_I_SSIZE_MIN, SCM_I_SSIZE_MAX, and SCM_I_SIZE_MAX macros for | |
69 | the limits. Those are always defined. | |
70 | ||
1f15779e KR |
71 | 2004-07-29 Kevin Ryde <user42@zip.com.au> |
72 | ||
73 | * posix.c (scm_ttyname): Use scm_i_misc_mutex for thread safety. | |
74 | ||
48360eb3 KR |
75 | 2004-07-28 Kevin Ryde <user42@zip.com.au> |
76 | ||
77 | * posix.c (scm_ctermid): Use an L_ctermid buf on the stack, for thread | |
78 | safety. | |
79 | ||
c3f3c841 KR |
80 | * unif.c (scm_array_set_x): For svect, use scm_num2short for |
81 | consistency with other vector types and to get arg and func name into | |
82 | error message. | |
83 | ||
c82f8ed6 MV |
84 | 2004-07-27 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
85 | ||
86 | * deprecated.h (SCM_FALSEP, SCM_NFALSEP, SCM_BOOLP, SCM_BOOL): | |
87 | Reimplement using scm_is_false, scm_is_true, scm_is_bool, and | |
88 | scm_from_bool, respectively. | |
89 | (SCM_NINUMP): Added. | |
90 | ||
91 | * tags.h, deprecated.h (SCM_EQ_P): Deprecated by moving it into | |
92 | deprecated.h. Replaced all uses with scm_is_eq. | |
93 | ||
317b4c4a KR |
94 | 2004-07-24 Kevin Ryde <user42@zip.com.au> |
95 | ||
96 | * threads.c, threads.h (scm_i_misc_mutex): New SCM_GLOBAL_MUTEX. | |
97 | * posix.c (scm_crypt): Use it to protect static data in crypt(). | |
98 | ||
e11e83f3 MV |
99 | 2004-07-23 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
100 | ||
101 | * deprecated.h, deprecated.c, numbers.h (SCM_INUMP, SCM_NINUMP, | |
c82f8ed6 | 102 | SCM_INUM): Deprecated by renaming them to SCM_I_INUMP, |
e11e83f3 MV |
103 | SCM_I_NINUMP and SCM_I_INUM, respectively and adding deprecated |
104 | versions to deprecated.h and deprecated.c. Changed all uses to | |
105 | either use the SCM_I_ variants or scm_is_*, scm_to_*, or | |
106 | scm_from_*, as appropriate. | |
107 | ||
108 | * dynwind.c (scm_i_dowinds): Removed unused code that would call | |
109 | the unexisting scm_cross_dynwind_binding_scope for inums on the | |
110 | windlist. | |
111 | ||
a55c2b68 MV |
112 | 2004-07-10 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
113 | ||
114 | * socket.c (ipv6_net_to_num, scm_from_ipv6): Renamed | |
e11e83f3 | 115 | ipv6_net_to_num to scm_from_ipv6, for converting from an IPv6 |
a55c2b68 MV |
116 | byte-wise address to a SCM integer. Changed all uses. |
117 | (ipv6_num_to_net, scm_to_ipv6): Renamed ipv6_num_to_net to | |
118 | scm_to_ipv6 and added type and range checking, for converting from | |
119 | an IPv& byte-wise address to a SCM integer. Changed all uses. | |
120 | (bignum_in_ipv6_range_p, VALIDATE_INET6): Removed, their function | |
121 | is now done by scm_to_ipv6. | |
122 | ||
123 | * numbers.c (scm_to_signed_integer, scm_to_unsigned_integer): dot | |
124 | not accept inexact integers. | |
125 | ||
126 | * validate.h, deprecated.h (SCM_VALIDATE_INUM, | |
127 | SCM_VALIDATE_INUM_COPY, SCM_VALIDATE_BIGINT, | |
128 | SCM_VALIDATE_INUM_MIN, SCM_VALIDATE_INUM_MIN_COPY, | |
129 | SCM_VALIDATE_INUM_MIN_DEF_COPY,SCM_VALIDATE_INUM_DEF, | |
130 | SCM_VALIDATE_INUM_DEF_COPY, SCM_VALIDATE_INUM_RANGE, | |
131 | SCM_VALIDATE_INUM_RANGE_COPY): Deprecated because they make the | |
132 | fixnum/bignum distinction visible. Changed all uses to | |
133 | scm_to_size_t or similar. | |
134 | ||
135 | 2004-07-09 Marius Vollmer <marius.vollmer@uni-dortmund.de> | |
136 | ||
137 | * cpp_cnvt.awk: Use scm_from_int instead of SCM_MAKINUM. | |
138 | ||
48a06bd5 KR |
139 | 2004-07-10 Kevin Ryde <user42@zip.com.au> |
140 | ||
141 | * hash.c (scm_hashq, scm_hashv, scm_hash): Restrict to size>=1 rather | |
142 | than size>=0, since 0<=hash<size cannot be satisfied for size==0, and | |
143 | such a size causes divide-by-zeros in scm_hasher. | |
144 | ||
052fbfd9 KR |
145 | * regex-posix.c (scm_make_regexp): Free rx on error, to avoid memory |
146 | leak. | |
147 | ||
43240c9c MV |
148 | 2004-07-08 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
149 | ||
150 | * numbers.c (scm_is_signed_integer, scm_is_unsigned_integer): | |
151 | Rewritten using the same logic as scm_to_signed_integer and | |
152 | scm_to_unsigned_integer, respectively, which is better(tm). Also, | |
153 | use CHAR_BIT instead of hardcoding 8. | |
154 | (LLONG_MIN, LLONG_MAX, ULLONG_MAX): Removed and used | |
155 | SCM_I_LLONG_MIN etc. instead. | |
156 | ||
157 | * numbers.h (SCM_MAKINUM, SCM_I_MAKINUM): Renamed SCM_MAKINUM to | |
158 | SCM_I_MAKINUM and changed all uses. | |
159 | * deprecated.h, deprecated.c (SCM_MAKINUM): Newly deprecated. | |
160 | ||
a3de8e7b MV |
161 | * gen-scmconfig.c (SCM_I_LLONG_MIN, SCM_I_LLONG_MAX, |
162 | SCM_I_ULLONG_MAX): Instead of hard-coding the numbers, compute | |
43240c9c MV |
163 | them by assuming twos-complement. |
164 | ||
c9eb03bb MV |
165 | 2004-07-07 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
166 | ||
167 | * gen-scmconfig.h.in: Added all the new SCM_I_GSC_*_LIMITS that | |
168 | configure now produces. | |
169 | * gen-scmconfig.c: Use them to output SCM_T_INT8_MIN, etc | |
170 | definitions, giving the limits of the integer types defined by | |
171 | Guile. Also, output a hard coded SCM_I_LLONG_MIN, etc since | |
172 | LLONG_MIN or LONG_LONG_MIN is hard to get at. | |
173 | ||
174 | * numbers.h (scm_to_short, scm_to_ushort): It's SHRT_MIN, etc, not | |
175 | SHORT_MIN. | |
176 | (scm_to_size_t): Use SIZE_MAX instead of cooking our own. | |
177 | (scm_to_long_long, scm_to_ulong_long, scm_to_int8, scm_to_uint8, | |
178 | scm_to_int16, scm_to_uint16, scm_to_int32, scm_to_uint32, | |
179 | scm_to_int64, scm_to_uint64, scm_to_intmax, scm_to_uintmax, | |
180 | scm_from_long_long, scm_from_ulong_long, scm_from_int8, | |
181 | scm_from_uint8, scm_from_int16, scm_from_uint16, scm_from_int32, | |
182 | scm_from_uint32, scm_from_int64, scm_from_uint64, scm_from_intmax, | |
183 | scm_from_uintmax): New. | |
184 | ||
7888309b MV |
185 | 2004-07-06 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
186 | ||
187 | * tags.h (scm_is_eq): New. | |
188 | ||
189 | * deprecated.h, boolean.h (SCM_FALSEP, SCM_NFALSEP, SCM_BOOL, | |
190 | SCM_NEGATE_BOOL, SCM_BOOLP): Deprecated by moving into | |
191 | "deprecated.h". Replaced all uses with scm_is_false, scm_is_true, | |
192 | scm_from_bool, and scm_is_bool, respectively. | |
193 | ||
194 | * boolean.h (scm_is_bool): Fix bug in prototype. | |
195 | (scm_from_bool): The argument is "x" not "f", stupid. | |
196 | ||
197 | * boolean.c (scm_is_bool): Fix typo. | |
198 | ||
199 | * numbers.h, numbers.c (scm_is_integer, scm_is_signed_integer, | |
200 | scm_is_unsigned_integer, scm_to_signed_integer, | |
201 | scm_to_unsigned_integer, scm_to_schar, scm_to_uchar, scm_to_char, | |
202 | scm_to_short, scm_to_ushort, scm_to_long, scm_to_ulong, | |
203 | scm_to_size_t, scm_to_ssize_t, scm_from_schar, scm_from_uchar, | |
204 | scm_from_char, scm_from_short, scm_from_ushort, scm_from_int, | |
205 | scm_from_uint, scm_from_long, scm_from_ulong, scm_from_size_t, | |
206 | scm_from_ssize_t, scm_is_real, scm_to_double, scm_from_double): | |
207 | New. | |
208 | ||
800570a6 MV |
209 | 2004-07-05 Marius Vollmer <marius.vollmer@uni-dortmund.de> |
210 | ||
211 | * boolean.h, boolean.c (scm_is_true, scm_is_false, scm_from_bool, | |
212 | scm_to_bool): New. | |
213 | ||
9fcf3cbb DH |
214 | 2004-06-27 Dirk Herrmann <dirk@dirk-herrmanns-seiten.de> |
215 | ||
216 | * backtrace.c (display_expression, display_frame): Call | |
217 | scm_i_unmemoize_expr for unmemoizing a memoized object holding a | |
218 | single memoized expression. | |
219 | ||
220 | * debug.c (memoized_print): Don't try to unmemoize the memoized | |
221 | object, since we can't know whether it holds a single expression | |
222 | or a body. | |
223 | ||
224 | (scm_mem_to_proc): Removed check for lambda expression, since it | |
225 | was moot anyway. Whoever uses these functions for debugging | |
226 | purposes should know what they do: Creating invalid memoized code | |
227 | will cause crashes, independent of whether this check is present | |
228 | or not. | |
229 | ||
230 | (scm_proc_to_mem): Take the closure's code as it is and don't | |
231 | append a SCM_IM_LAMBDA isym. To allow easier debugging, the | |
232 | memoized code should not be modified. | |
233 | ||
234 | * debug.[ch] (scm_unmemoize, scm_i_unmemoize_expr): Removed | |
235 | scm_unmemoize from public use, but made scm_i_unmemoize_expr | |
236 | available as a guile internal function instead. However, | |
237 | scm_i_unmemoize_expr will only work on memoized objects that hold | |
238 | a single memoized expression. It won't work with bodies. | |
239 | ||
240 | * debug.c (scm_procedure_source), macros.c (macro_print), print.c | |
241 | (scm_iprin1): Call scm_i_unmemocopy_body for unmemoizing a body, | |
242 | i. e. a list of expressions. | |
243 | ||
244 | * eval.c (unmemoize_exprs): Drop internal body markers from the | |
245 | output during unmemoization. | |
246 | ||
247 | * eval.[ch] (scm_unmemocopy, scm_i_unmemocopy_expr, | |
248 | scm_i_unmemocopy_body): Removed scm_unmemocopy from public use, | |
249 | but made scm_i_unmemocopy_expr and scm_i_unmemocopy_body available | |
250 | as guile internal functions instead. scm_i_unmemoize_expr will | |
251 | only work on a single memoized expression, while | |
252 | scm_i_unmemocopy_body will only work on bodies. | |
253 | ||
90df793f DH |
254 | 2004-06-21 Dirk Herrmann <dirk@dirk-herrmanns-seiten.de> |
255 | ||
256 | * eval.c (unmemoize_exprs): Handle semi-memoized code. | |
257 | ||
258 | (scm_cons_source, scm_primitive_eval): Prefer higher level | |
259 | predicate SCM_FALSEP over SCM_IMP. | |
260 | ||
8048c00b RB |
261 | 2004-06-15 Rob Browning <rlb@defaultvalue.org> |
262 | ||
263 | * script.c (scm_shell_usage): minor phrasing change. | |
264 | ||
265 | * gc_os_dep.c: update ifdefery for macosx. | |
266 | (scm_get_stack_base): separate result initialization from | |
267 | declaration to slience warnings with macosx and hp-ux using gcc | |
268 |