diff options
author | Carl Worth <cworth@cworth.org> | 2013-10-24 15:02:49 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2013-10-25 14:59:28 -0700 |
commit | 52a81b7ef561b064f0157af8cf8eeca29b3ec639 (patch) | |
tree | bbecd8495443894ff3554b7168e940e2d30a8aed | |
parent | ae79c77c2d18214a6680623bdadbb566c4c7adfd (diff) |
Whitespace cleanup for header files.
It's so much easier to find function names in the header file when
they are in column 0 where they belong.
-rw-r--r-- | hash_table.h | 31 | ||||
-rw-r--r-- | set.h | 31 |
2 files changed, 39 insertions, 23 deletions
diff --git a/hash_table.h b/hash_table.h index d8296f6..4e7ea81 100644 --- a/hash_table.h +++ b/hash_table.h @@ -48,19 +48,28 @@ struct hash_table { uint32_t deleted_entries; }; -struct hash_table *hash_table_create(int (*key_equals_function)(const void *a, - const void *b)); -void hash_table_destroy(struct hash_table *ht, - void (*delete_function)(struct hash_entry *entry)); +struct hash_table * +hash_table_create(int (*key_equals_function)(const void *a, + const void *b)); +void +hash_table_destroy(struct hash_table *ht, + void (*delete_function)(struct hash_entry *entry)); -struct hash_entry *hash_table_insert(struct hash_table *ht, uint32_t hash, - const void *key, void *data); -struct hash_entry *hash_table_search(struct hash_table *ht, uint32_t hash, - const void *key); -void hash_table_remove(struct hash_table *ht, struct hash_entry *entry); +struct hash_entry * +hash_table_insert(struct hash_table *ht, uint32_t hash, + const void *key, void *data); + +struct hash_entry * +hash_table_search(struct hash_table *ht, uint32_t hash, + const void *key); + +void +hash_table_remove(struct hash_table *ht, struct hash_entry *entry); + +struct hash_entry * +hash_table_next_entry(struct hash_table *ht, + struct hash_entry *entry); -struct hash_entry *hash_table_next_entry(struct hash_table *ht, - struct hash_entry *entry); struct hash_entry * hash_table_random_entry(struct hash_table *ht, int (*predicate)(struct hash_entry *entry)); @@ -43,18 +43,25 @@ struct set { uint32_t deleted_entries; }; -struct set *set_create(int (*key_equals_function)(const void *a, - const void *b)); -void set_destroy(struct set *set, - void (*delete_function)(struct set_entry *entry)); - -struct set_entry *set_add(struct set *set, uint32_t hash, const void *key); -struct set_entry *set_search(struct set *set, uint32_t hash, - const void *key); -void set_remove(struct set *set, struct set_entry *entry); - -struct set_entry *set_next_entry(struct set *set, - struct set_entry *entry); +struct set * +set_create(int (*key_equals_function)(const void *a, + const void *b)); +void +set_destroy(struct set *set, + void (*delete_function)(struct set_entry *entry)); + +struct set_entry * +set_add(struct set *set, uint32_t hash, const void *key); + +struct set_entry * +set_search(struct set *set, uint32_t hash, const void *key); + +void +set_remove(struct set *set, struct set_entry *entry); + +struct set_entry * +set_next_entry(struct set *set, struct set_entry *entry); + struct set_entry * set_random_entry(struct set *set, int (*predicate)(struct set_entry *entry)); |