#include <stdio.h>
-#if defined (__GNUC__) || (defined (__STDC__) && __STDC__)
-#define __P(args) args
-#else
-#define __P(args) ()
-#endif /* GCC. */
-
-typedef unsigned long (*hash_func_t) __P((void const *key));
-typedef int (*hash_cmp_func_t) __P((void const *x, void const *y));
-typedef void (*hash_map_func_t) __P((void const *item));
+#ifndef PARAMS
+# if defined PROTOTYPES || defined __STDC__
+# define PARAMS(Args) Args
+# else
+# define PARAMS(Args) ()
+# endif
+#endif
+
+typedef unsigned long (*hash_func_t) PARAMS((void const *key));
+typedef int (*hash_cmp_func_t) PARAMS((void const *x, void const *y));
+typedef void (*hash_map_func_t) PARAMS((void const *item));
struct hash_table
{
hash_cmp_func_t ht_compare; /* comparison function */
};
-typedef int (*qsort_cmp_t) __P((void const *, void const *));
-
-void hash_init __P((struct hash_table *ht, unsigned long size,
- hash_func_t hash_1, hash_func_t hash_2, hash_cmp_func_t hash_cmp));
-void hash_load __P((struct hash_table *ht, void *item_table,
- unsigned long cardinality, unsigned long size));
-void **hash_find_slot __P((struct hash_table *ht, void const *key));
-void *hash_find_item __P((struct hash_table *ht, void const *key));
-const void *hash_insert __P((struct hash_table *ht, void *item));
-const void *hash_insert_at __P((struct hash_table *ht, void *item, void const *slot));
-const void *hash_delete __P((struct hash_table *ht, void const *item));
-const void *hash_delete_at __P((struct hash_table *ht, void const *slot));
-void hash_delete_items __P((struct hash_table *ht));
-void hash_free_items __P((struct hash_table *ht));
-void hash_free __P((struct hash_table *ht, int free_items));
-void hash_map __P((struct hash_table *ht, hash_map_func_t map));
-void hash_print_stats __P((struct hash_table *ht, FILE *out_FILE));
-void **hash_dump __P((struct hash_table *ht, void **vector_0, qsort_cmp_t compare));
+typedef int (*qsort_cmp_t) PARAMS((void const *, void const *));
+
+void hash_init PARAMS((struct hash_table *ht, unsigned long size,
+ hash_func_t hash_1, hash_func_t hash_2, hash_cmp_func_t hash_cmp));
+void hash_load PARAMS((struct hash_table *ht, void *item_table,
+ unsigned long cardinality, unsigned long size));
+void **hash_find_slot PARAMS((struct hash_table *ht, void const *key));
+void *hash_find_item PARAMS((struct hash_table *ht, void const *key));
+const void *hash_insert PARAMS((struct hash_table *ht, void *item));
+const void *hash_insert_at PARAMS((struct hash_table *ht, void *item, void const *slot));
+const void *hash_delete PARAMS((struct hash_table *ht, void const *item));
+const void *hash_delete_at PARAMS((struct hash_table *ht, void const *slot));
+void hash_delete_items PARAMS((struct hash_table *ht));
+void hash_free_items PARAMS((struct hash_table *ht));
+void hash_free PARAMS((struct hash_table *ht, int free_items));
+void hash_map PARAMS((struct hash_table *ht, hash_map_func_t map));
+void hash_print_stats PARAMS((struct hash_table *ht, FILE *out_FILE));
+void **hash_dump PARAMS((struct hash_table *ht, void **vector_0, qsort_cmp_t compare));
extern void *hash_deleted_item;
#define HASH_VACANT(item) \