Re: GHashTable suggestions



Darin Adler <darin eazel com> writes: 
> I don't see that this makes g_hash_table_insert more difficult to explain
> than it already is. This is 100% consistent with how it is now, and it's not
> so complicated to explain:
> 
>     Creates a new hash table entry with the passed key and value. If there's
> already a hash table entry, destroys the passed key, and replaces the old
> value with the new one, destroying the old value.
>

I thought the proposal was to have _insert() destroy the existing
key. You're right, if it destroys the passed key then things aren't
more complicated. That seems OK.

Havoc

 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]