mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-17 01:00:20 +02:00
* coop-threads.c: Remove K&R function headers.
* scm_validate.h: Added SCM_VALIDATE_THREAD. * *.c: Remove SCM_NIMP(X) when it is an extraneous pre-test given that SCM_FOOP macros all now include SCM_NIMP in their expansion. This simplifies lots of code, making it far more readable.
This commit is contained in:
parent
9c24ff3e6c
commit
0c95b57d77
50 changed files with 324 additions and 384 deletions
|
@ -61,7 +61,7 @@ scm_hash_fn_get_handle (SCM table,SCM obj,unsigned int (*hash_fn)(),SCM (*assoc_
|
|||
unsigned int k;
|
||||
SCM h;
|
||||
|
||||
SCM_ASSERT (SCM_NIMP (table) && SCM_VECTORP (table), table, SCM_ARG1, "hash_fn_get_handle");
|
||||
SCM_ASSERT (SCM_VECTORP (table), table, SCM_ARG1, "hash_fn_get_handle");
|
||||
if (SCM_LENGTH (table) == 0)
|
||||
return SCM_EOL;
|
||||
k = hash_fn (obj, SCM_LENGTH (table), closure);
|
||||
|
@ -82,7 +82,7 @@ scm_hash_fn_create_handle_x (SCM table,SCM obj,SCM init,unsigned int (*hash_fn)(
|
|||
unsigned int k;
|
||||
SCM it;
|
||||
|
||||
SCM_ASSERT (SCM_NIMP (table) && SCM_VECTORP (table), table, SCM_ARG1, "hash_fn_create_handle_x");
|
||||
SCM_ASSERT (SCM_VECTORP (table), table, SCM_ARG1, "hash_fn_create_handle_x");
|
||||
if (SCM_LENGTH (table) == 0)
|
||||
return SCM_EOL;
|
||||
k = hash_fn (obj, SCM_LENGTH (table), closure);
|
||||
|
@ -148,7 +148,7 @@ scm_hash_fn_remove_x (SCM table,SCM obj,unsigned int (*hash_fn)(),SCM (*assoc_fn
|
|||
unsigned int k;
|
||||
SCM h;
|
||||
|
||||
SCM_ASSERT (SCM_NIMP (table) && SCM_VECTORP (table), table, SCM_ARG1, "hash_fn_remove_x");
|
||||
SCM_ASSERT (SCM_VECTORP (table), table, SCM_ARG1, "hash_fn_remove_x");
|
||||
if (SCM_LENGTH (table) == 0)
|
||||
return SCM_EOL;
|
||||
k = hash_fn (obj, SCM_LENGTH (table), closure);
|
||||
|
@ -510,10 +510,10 @@ scm_internal_hash_fold (SCM (*fn) (), void *closure, SCM init, SCM table)
|
|||
SCM ls = SCM_VELTS (table)[i], handle;
|
||||
while (SCM_NNULLP (ls))
|
||||
{
|
||||
SCM_ASSERT (SCM_NIMP (ls) && SCM_CONSP (ls),
|
||||
SCM_ASSERT (SCM_CONSP (ls),
|
||||
table, SCM_ARG1, s_scm_hash_fold);
|
||||
handle = SCM_CAR (ls);
|
||||
SCM_ASSERT (SCM_NIMP (handle) && SCM_CONSP (handle),
|
||||
SCM_ASSERT (SCM_CONSP (handle),
|
||||
table, SCM_ARG1, s_scm_hash_fold);
|
||||
result = fn (closure, SCM_CAR (handle), SCM_CDR (handle), result);
|
||||
ls = SCM_CDR (ls);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue