Re: [PREVIEW v3 0/9] Preview of "Peace with CRLF" rerolled
- From
Jeff King <peff@peff.net>
- Date
- Jan 14, 2016, 10:23 UTC
- Message-ID
- <20160114102326.GE30772@sigill.intra.peff.net>
- In-Reply-To
- <1452740590-16827-1-git-send-email-gitster@pobox.com>
On Wed, Jan 13, 2016 at 07:03:00PM -0800, Junio C Hamano wrote:
Show 15 quoted lines
> Continued from > > http://thread.gmane.org/gmane.comp.version-control.git/282614 > > Here is only the preparatory part that > > - introduces strbuf_getline_lf() and strbuf_getine_nul() and > converts existing callers to strbut_getline() to use them; > > - retires strbuf_getline() that takes an arbitrary line terminator > and demotes it to strbuf_getdelim() that is merely an > implementation detail inside strbuf.c; and > > - gives the short-and-sweet name strbuf_getline() to the most > "text friendly" strbuf_getline_crlf().
With the exception of a few minor nits (some of which are even just cleanups we _could_ do while in the area), this looks like a good approach to me.
I'm happy that the more-immediate endgame will keep many callers with the short "strbuf_getline" (and that its invocation is now even shorter and more readable than before, with the '\n' noise gone).
-Peff