Re: [PATCH/WIP v3 1/4] for-each-ref: extract helper functions out of grab_single_ref()

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

 



Karthik Nayak <karthik.188@xxxxxxxxx> writes:

> This is a preperatory patch for restructuring 'for-each-ref' and
> evntually moving most of it to 'ref-filter' to provide the

s/evntually/eventually/

The patch looks much nicer now.

> -	int cnt;
> [...]
> +	REALLOC_ARRAY(cb->grab_array, cb->grab_cnt + 1);
> +	cb->grab_array[cb->grab_cnt++] = ref;
>  
> -	cnt = cb->grab_cnt;
> -	REALLOC_ARRAY(cb->grab_array, cnt + 1);
> -	cb->grab_array[cnt++] = ref;
> -	cb->grab_cnt = cnt;

This hunk is not advertized in the commit message, and I had to fight a
bit to understand what it does with "we're extracting helper functions"
in mind. It would have been much easier to review in a separate patch
entitled "for-each-ref: simplify code" for example.

But I agree that your version is simpler indeed.

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]