45 return (
const char *)&
this[1];
int u_hashset_erase_str(struct u_hashset *hs, const char *str, size_t length)
Definition: u_hashset.cpp:94
A embeddable hashset item, note that the string directly follows the u_hashset_item.
Definition: u_hashset.h:36
void u_hashset_clear_and_call_for_each(struct u_hashset *hs, u_hashset_callback cb, void *priv)
First clear the hashset and then call the given callback with each item that was in the hashset...
Definition: u_hashset.cpp:109
Kind of bespoke hashset implementation, where the user is responsible for allocating and freeing the ...
Definition: u_hashset.cpp:24
int u_hashset_create(struct u_hashset **out_hashset)
Definition: u_hashset.cpp:37
int u_hashset_erase_item(struct u_hashset *hs, struct u_hashset_item *item)
Definition: u_hashset.cpp:86
int u_hashset_insert_item(struct u_hashset *hs, struct u_hashset_item *item)
Definition: u_hashset.cpp:78
int u_hashset_find_c_str(struct u_hashset *hs, const char *c_str, struct u_hashset_item **out_item)
Definition: u_hashset.cpp:69
void(* u_hashset_callback)(struct u_hashset_item *item, void *priv)
Definition: u_hashset.h:52
int u_hashset_find_str(struct u_hashset *hs, const char *str, size_t length, struct u_hashset_item **out_item)
Definition: u_hashset.cpp:53
size_t length
Definition: u_hashset.h:39
int u_hashset_destroy(struct u_hashset **hs)
Definition: u_hashset.cpp:45
Header holding common defines.
size_t hash
Definition: u_hashset.h:38
int u_hashset_erase_c_str(struct u_hashset *hs, const char *c_str)
Definition: u_hashset.cpp:102
const char c_str[]
Definition: u_hashset.h:48