Juergen Boemmels <[EMAIL PROTECTED]> wrote:

> Yes this is a problem. I did a little research how other libraries
> solve this problem. Oh man, there are many of them.

"little" :)

BTW, inside parrot:

$ find . -name '*.c' | xargs grep hash_get

and you'll see another hash implementation.

> void * hash_get(Interp * interpreter, HASH *hash, void *key);
> HASHBUCKET * hash_get_bucket(Interp * interpreter, HASH *hash, void *key);

That's ok for me. For all of the "normal" Hash usage, we don't have NULL
values, so there is no ambuigity for the return value.

> Some other note. Didn't we decided some time ago to use only ALLCAPS
> types in cases were they are abbreviations. So the name would better
> be Hash and HashBucket.

Yep.

>> Additionally the returned bucket has the key inside, which could be
>> useful.

> In cases where two keys compare equal but are not equal bitwise this
> is indeed nice.

Yes, you could have e.g. case-ignore compare/hash functions.

> bye
> boe

leo

Reply via email to