Re: [PATCH 1/3] add merge.renamelimit config option

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

 



On Sat, May 03, 2008 at 01:15:06PM -0700, Junio C Hamano wrote:

> >  	opts.detect_rename = DIFF_DETECT_RENAME;
> > -	opts.rename_limit = rename_limit;
> > +	opts.rename_limit = merge_rename_limit >= 0 ? merge_rename_limit :
> > +			    diff_rename_limit >= 0 ? diff_rename_limit :
> > +			    100;
> >  	opts.output_format = DIFF_FORMAT_NO_OUTPUT;
> >  	if (diff_setup_done(&opts) < 0)
> >  		die("diff setup failed");
> 
> Makes one wonder where the magic 100 comes from.  Wouldn't this
> 
> 	opts.rename_limit = (merge_rename_limit >= 0)
>         		  ? merge_rename_limit
>                           : diff_rename_limit;
> 
> be easier to maintain, with the same semantics?

Yes, though I was being a little sneaky in perparation for 2/3, which
changes the defaults differently for diff versus merge. I could maybe
have put that particular change into 2/3, but it looks like you have
applied this to next as-is already.

-Peff
--
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]

  Powered by Linux