summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2009-10-26 23:38:13 +0100
committerLudovic Courtès <ludo@gnu.org>2009-10-27 00:24:09 +0100
commitf044da55c5b0c0cf444a25e5bd9a76fea5a95f2d (patch)
treeb0e495931dbc2d23791553d025c62e0e1465bc09
parentf916cbc4b17165491e7bfe64be4b56913fdacce6 (diff)
downloadguile-f044da55c5b0c0cf444a25e5bd9a76fea5a95f2d.tar.gz
Use proper assoc/hash function types in `hashtab.c'.
This is a followup to d587c9e8b27219e68f8813fb648fc6913c93be0f ("Use proper types for hash/assoc functions in `hashtab.h'."). * libguile/hashtab.c (scm_i_rehash, scm_hash_fn_create_handle_x, scm_hash_fn_ref, scm_hash_fn_set_x, scm_hash_fn_remove_x): Use `scm_t_hash_fn' and `scm_t_assoc_fn' as appropriate.
-rw-r--r--libguile/hashtab.c25
1 files changed, 14 insertions, 11 deletions
diff --git a/libguile/hashtab.c b/libguile/hashtab.c
index 69d604a08..511197781 100644
--- a/libguile/hashtab.c
+++ b/libguile/hashtab.c
@@ -207,7 +207,7 @@ make_hash_table (int flags, unsigned long k, const char *func_name)
void
scm_i_rehash (SCM table,
- unsigned long (*hash_fn)(),
+ scm_t_hash_fn hash_fn,
void *closure,
const char* func_name)
{
@@ -472,8 +472,9 @@ scm_hash_fn_get_handle (SCM table, SCM obj,
SCM
-scm_hash_fn_create_handle_x (SCM table, SCM obj, SCM init, unsigned long (*hash_fn)(),
- SCM (*assoc_fn)(), void * closure)
+scm_hash_fn_create_handle_x (SCM table, SCM obj, SCM init,
+ scm_t_hash_fn hash_fn, scm_t_assoc_fn assoc_fn,
+ void * closure)
#define FUNC_NAME "scm_hash_fn_create_handle_x"
{
int weak = 0;
@@ -563,9 +564,10 @@ scm_hash_fn_create_handle_x (SCM table, SCM obj, SCM init, unsigned long (*hash_
#undef FUNC_NAME
-SCM
-scm_hash_fn_ref (SCM table, SCM obj, SCM dflt, unsigned long (*hash_fn)(),
- SCM (*assoc_fn)(), void * closure)
+SCM
+scm_hash_fn_ref (SCM table, SCM obj, SCM dflt,
+ scm_t_hash_fn hash_fn, scm_t_assoc_fn assoc_fn,
+ void *closure)
{
SCM it = scm_hash_fn_get_handle (table, obj, hash_fn, assoc_fn, closure);
if (scm_is_pair (it))
@@ -577,9 +579,10 @@ scm_hash_fn_ref (SCM table, SCM obj, SCM dflt, unsigned long (*hash_fn)(),
-SCM
-scm_hash_fn_set_x (SCM table, SCM obj, SCM val, unsigned long (*hash_fn)(),
- SCM (*assoc_fn)(), void * closure)
+SCM
+scm_hash_fn_set_x (SCM table, SCM obj, SCM val,
+ scm_t_hash_fn hash_fn, scm_t_assoc_fn assoc_fn,
+ void *closure)
{
SCM it;
@@ -591,8 +594,8 @@ scm_hash_fn_set_x (SCM table, SCM obj, SCM val, unsigned long (*hash_fn)(),
SCM
scm_hash_fn_remove_x (SCM table, SCM obj,
- unsigned long (*hash_fn)(),
- SCM (*assoc_fn)(),
+ scm_t_hash_fn hash_fn,
+ scm_t_assoc_fn assoc_fn,
void *closure)
{
int weak = 0;