minor api cleanup for ghash/edgehash
- use single inlined lookup function. - move comments into source. - pack iterator vars more efficiently.
This commit is contained in:
@@ -46,8 +46,8 @@ typedef struct GHash GHash;
|
||||
|
||||
typedef struct GHashIterator {
|
||||
GHash *gh;
|
||||
unsigned int curBucket;
|
||||
struct Entry *curEntry;
|
||||
unsigned int curBucket;
|
||||
} GHashIterator;
|
||||
|
||||
enum {
|
||||
@@ -60,6 +60,7 @@ GHash *BLI_ghash_new(GHashHashFP hashfp, GHashCmpFP cmpfp, const char *info);
|
||||
void BLI_ghash_free(GHash *gh, GHashKeyFreeFP keyfreefp, GHashValFreeFP valfreefp);
|
||||
void BLI_ghash_insert(GHash *gh, void *key, void *val);
|
||||
void *BLI_ghash_lookup(GHash *gh, const void *key);
|
||||
void **BLI_ghash_lookup_p(GHash *gh, const void *key);
|
||||
bool BLI_ghash_remove(GHash *gh, void *key, GHashKeyFreeFP keyfreefp, GHashValFreeFP valfreefp);
|
||||
void BLI_ghash_clear(GHash *gh, GHashKeyFreeFP keyfreefp, GHashValFreeFP valfreefp);
|
||||
void *BLI_ghash_pop(GHash *gh, void *key, GHashKeyFreeFP keyfreefp);
|
||||
|
Reference in New Issue
Block a user