From: Jeff King <peff@peff.net>
To: Felipe Contreras <felipe.contreras@gmail.com>
Cc: Git <git@vger.kernel.org>, Junio C Hamano <gitster@pobox.com>
Subject: Re: [PATCH 1/4] refspec: trivial cleanup
Date: Tue, 1 Dec 2020 21:01:14 -0500 [thread overview]
Message-ID: <X8b1au+GDihNvhIQ@coredump.intra.peff.net> (raw)
In-Reply-To: <CAMP44s3usd5EW4sA6_qapnDBVRAWg4nk5ZSxAPPQN1UygD=ctA@mail.gmail.com>
On Tue, Dec 01, 2020 at 05:25:53PM -0600, Felipe Contreras wrote:
> > I know your question was rhetorical, but a good reason not to do so in
> > general is that the existing pattern reveals some intent. E.g., it
> > sometimes is the case that with the _current_ code we can return early
> > from a function or loop, but that is not inherent to what the code is
> > doing, and the early return or continue makes it harder to understand
> > that.
>
> Yes, but even in those cases it arguably helps readability.
>
> Anyway, I prefer to argue on the tangible rather than hypotheticals
> because the hypotheticals are infinite.
>
> In this particular case there's no particular reason to just continue
> if there's no prefix.
Right, which I already agreed with.
I hesitated on responding at all, because you and I have not had a good
history of agreeing on commit messages. But my comment was primarily for
other readers on the list. I do not want people blindly applying a rule
like "less indentation is good" without thinking about the code overall
(I don't know whether you thought about it or not, but it was not
apparent from your commit message).
-Peff
next prev parent reply other threads:[~2020-12-02 2:02 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-01 0:46 [PATCH 0/4] Random cleanups Felipe Contreras
2020-12-01 0:46 ` [PATCH 1/4] refspec: trivial cleanup Felipe Contreras
2020-12-01 11:43 ` Jeff King
2020-12-01 18:29 ` Junio C Hamano
2020-12-01 23:25 ` Felipe Contreras
2020-12-02 2:01 ` Jeff King [this message]
2020-12-02 2:27 ` Felipe Contreras
2020-12-01 0:46 ` [PATCH 2/4] .gitignore: remove dangling file Felipe Contreras
2020-12-01 18:30 ` Junio C Hamano
2020-12-01 23:32 ` Felipe Contreras
2020-12-02 2:26 ` Jeff King
2020-12-02 3:30 ` Felipe Contreras
2020-12-02 11:46 ` [PATCH] gitignore: remove entry for git serve René Scharfe
2020-12-02 11:03 ` Johannes Schindelin
2020-12-02 12:48 ` Jeff King
2020-12-02 22:32 ` Junio C Hamano
2020-12-01 0:46 ` [PATCH 3/4] test: completion: fix typos Felipe Contreras
2020-12-01 0:46 ` [PATCH 4/4] tests: lib-functions: trivial style cleanups Felipe Contreras
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=X8b1au+GDihNvhIQ@coredump.intra.peff.net \
--to=peff@peff.net \
--cc=felipe.contreras@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).