public inbox for git@vger.kernel.org
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Tian Yuchen <cat@malon.dev>
Cc: aum2357 <ahambrahmasmi2357@gmail.com>,  git@vger.kernel.org
Subject: Re: [PATCH GSOC] diff: use conventional comparison order
Date: Sat, 14 Mar 2026 05:27:36 -0700	[thread overview]
Message-ID: <xmqqbjgqy4sn.fsf@gitster.g> (raw)
In-Reply-To: <405c075b-731b-47e3-9e9c-70aaa0efe1cc@malon.dev> (Tian Yuchen's message of "Sat, 14 Mar 2026 11:59:43 +0800")

Tian Yuchen <cat@malon.dev> writes:
> However, in builtin/add.c before the patch, there isn't even a single 
> “>” symbol used for comparison. The “<” symbol is used throughout the 
> comparison sections.

Look a bit harder.  I think there is one comparison that uses a
comparison that does not follow "textual order reflects actual
order" convention.

	while (--i >= 0) {

> I find it quite strange because the author says:
>
>> to follow the common coding style
>
> This patch seems more like it breaks the common coding style.

To somebody who does not know both conventions and understand that
both are valid, the only one that is familiar to the person would be
the only common one.

      reply	other threads:[~2026-03-14 12:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-13 14:04 [PATCH GSOC] diff: use conventional comparison order aum2357
2026-03-13 17:59 ` Tian Yuchen
2026-03-13 20:18   ` Junio C Hamano
2026-03-14  3:59     ` Tian Yuchen
2026-03-14 12:27       ` Junio C Hamano [this message]

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=xmqqbjgqy4sn.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=ahambrahmasmi2357@gmail.com \
    --cc=cat@malon.dev \
    --cc=git@vger.kernel.org \
    /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