Re: [RFC PATCH 1/3] strbuf: make add_lines() public

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

 



Junio C Hamano <gitster@xxxxxxxxx> writes:

> Jonathan Tan <jonathantanmy@xxxxxxxxxx> writes:
>
>> Subsequent patches will require the ability to add different prefixes
>> to different lines (depending on their contents), so make this
>> functionality available from outside strbuf.c.
>
> I do not think it is a good idea to force almost everybody to repeat
> themselves.  As we can see here, all but just a single caller of
> strbuf_add_lines() with this patch pass the same prefix for both
> parameters.  If we need to make the current strbuf.c:add_lines()
> also available to some specific callers, that is fine, but let's
> keep the simpler version that almost everybody uses as-is, and give
> the more complex and featureful one that is used only by selected
> callers a longer and more cumbersome name.
>
> Thanks.

Another practical downside of this patch is that it breaks other
in-flight topics that adds new users of strbuf_add_lines(), and that
breakage is totally unnecessary.






[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