aboutsummaryrefslogtreecommitdiff
path: root/src/hashtable.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/hashtable.h')
-rw-r--r--src/hashtable.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/hashtable.h b/src/hashtable.h
index 8f73066..f593432 100644
--- a/src/hashtable.h
+++ b/src/hashtable.h
@@ -33,9 +33,7 @@ void *table_reset(struct table *table, int *count);
#include <stdlib.h>
#include <string.h>
-#define internal static
-
-internal struct bucket *
+static struct bucket *
table_new_bucket(void *key, void *value)
{
struct bucket *bucket = malloc(sizeof(struct bucket));
@@ -45,7 +43,7 @@ table_new_bucket(void *key, void *value)
return bucket;
}
-internal struct bucket **
+static struct bucket **
table_get_bucket(struct table *table, void *key)
{
struct bucket **bucket = table->buckets + (table->hash(key) % table->capacity);
@@ -58,8 +56,6 @@ table_get_bucket(struct table *table, void *key)
return bucket;
}
-#undef internal
-
void table_init(struct table *table, int capacity, table_hash_func hash, table_compare_func compare)
{
table->count = 0;