Re: [PATCH 15/17] khash: rename oid helper functions

2019-06-23 Thread Jeff King
On Sun, Jun 23, 2019 at 06:00:50PM +0200, René Scharfe wrote: > > I do think if it took the more usual pass-by-const-pointer we'd probably > > still end up with the exact same code from an optimizing compiler, since > > all of the references and dereferences would cancel out once it was > > inline

Re: [PATCH 15/17] khash: rename oid helper functions

2019-06-23 Thread René Scharfe
Am 20.06.19 um 20:27 schrieb Jeff King: > On Thu, Jun 20, 2019 at 10:44:17AM -0700, Junio C Hamano wrote: > >> Jeff King writes: >> >>> For use in object_id hash tables, we have oid_hash() and oid_equal(). >>> But these are confusingly similar to the existing oideq() and the >>> oidhash() we plan

Re: [PATCH 15/17] khash: rename oid helper functions

2019-06-20 Thread Jeff King
On Thu, Jun 20, 2019 at 10:44:17AM -0700, Junio C Hamano wrote: > Jeff King writes: > > > For use in object_id hash tables, we have oid_hash() and oid_equal(). > > But these are confusingly similar to the existing oideq() and the > > oidhash() we plan to add to replace sha1hash(). > > > > The bi

Re: [PATCH 15/17] khash: rename oid helper functions

2019-06-20 Thread Junio C Hamano
Jeff King writes: > For use in object_id hash tables, we have oid_hash() and oid_equal(). > But these are confusingly similar to the existing oideq() and the > oidhash() we plan to add to replace sha1hash(). > > The big difference from those functions is that rather than accepting a > const point

[PATCH 15/17] khash: rename oid helper functions

2019-06-20 Thread Jeff King
For use in object_id hash tables, we have oid_hash() and oid_equal(). But these are confusingly similar to the existing oideq() and the oidhash() we plan to add to replace sha1hash(). The big difference from those functions is that rather than accepting a const pointer to the "struct object_id", w