From: Junio C Hamano <gitster@pobox.com>
To: Mike Hommey <mh@glandium.org>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 3/4] Fix comma warnings with clang on Windows
Date: Tue, 03 Jun 2025 16:51:38 -0700 [thread overview]
Message-ID: <xmqqplfkfkol.fsf@gitster.g> (raw)
In-Reply-To: <20250603230646.2322671-3-mh@glandium.org> (Mike Hommey's message of "Wed, 4 Jun 2025 08:06:45 +0900")
Mike Hommey <mh@glandium.org> writes:
> Subject: Re: [PATCH 3/4] Fix comma warnings with clang on Windows
Common to all four patches, as "Fix" does not quite tell the story,
please choose more appropriate verb. For example, judging from how
this was rewritten ...
> - if ((oflags & ~O_CREAT) != (O_WRONLY | O_APPEND))
> - return errno = ENOSYS, -1;
> + if ((oflags & ~O_CREAT) != (O_WRONLY | O_APPEND)) {
> + errno = ENOSYS;
> + return -1;
> + }
... the warning is a false positive (i.e. the code does what the
author intended it to do), so this is more like "squelching" the
warning.
I obviously like the style after this patch. I just thought that
the proposed log message, especially its title, were not clear
enough to tell which ones are real fixes and which ones are
workarounds.
Thanks.
next prev parent reply other threads:[~2025-06-03 23:51 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-03 23:06 [PATCH 1/4] Fix maybe-uninitialized warning with GCC at -O3 Mike Hommey
2025-06-03 23:06 ` [PATCH 2/4] Fix use-after-free " Mike Hommey
2025-06-03 23:47 ` Junio C Hamano
2025-06-04 7:36 ` Patrick Steinhardt
2025-06-03 23:06 ` [PATCH 3/4] Fix comma warnings with clang on Windows Mike Hommey
2025-06-03 23:51 ` Junio C Hamano [this message]
2025-06-03 23:06 ` [PATCH 4/4] Fix unreachable-code warning " Mike Hommey
2025-06-04 7:36 ` Patrick Steinhardt
2025-06-04 15:50 ` Junio C Hamano
2025-06-04 7:36 ` [PATCH 1/4] Fix maybe-uninitialized warning with GCC at -O3 Patrick Steinhardt
2025-06-06 0:23 ` Jeff King
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=xmqqplfkfkol.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=mh@glandium.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;
as well as URLs for NNTP newsgroup(s).