Re: [PATCH 3/3] shorten_unambiguous_ref(): tighten up pointer arithmetic

2014-01-10 Thread Michael Haggerty
On 01/10/2014 12:01 AM, Junio C Hamano wrote: Michael Haggerty mhag...@alum.mit.edu writes: As long as we're being pathologically stingy with mallocs, we might as well do the math right and save 6 (!) bytes. Signed-off-by: Michael Haggerty mhag...@alum.mit.edu --- It is left to the reader

Re: [PATCH 3/3] shorten_unambiguous_ref(): tighten up pointer arithmetic

2014-01-10 Thread Junio C Hamano
Michael Haggerty mhag...@alum.mit.edu writes: As for removing the third argument of refname_match(): although all callers pass it ref_ref_parse_rules, that array is sometimes passed to the function via the alias ref_fetch_rules. So I suppose somebody wanted to leave the way open to make

[PATCH 3/3] shorten_unambiguous_ref(): tighten up pointer arithmetic

2014-01-08 Thread Michael Haggerty
As long as we're being pathologically stingy with mallocs, we might as well do the math right and save 6 (!) bytes. Signed-off-by: Michael Haggerty mhag...@alum.mit.edu --- It is left to the reader to show how another 7 bytes could be saved (11 bytes on a 64-bit architecture!) It probably