All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Jeff King <peff@peff.net>, git@vger.kernel.org
Subject: Re: [PATCH v2 5/5] CodingGuidelines: recommend against unportable C99 struct syntax
Date: Tue, 11 Oct 2022 10:30:34 +0200	[thread overview]
Message-ID: <221011.86bkqipxpv.gmgdl@evledraar.gmail.com> (raw)
In-Reply-To: <xmqqlepnxl1f.fsf@gitster.g>


On Mon, Oct 10 2022, Junio C Hamano wrote:

> Jeff King <peff@peff.net> writes:
>
>> On Mon, Oct 10, 2022 at 01:38:00PM -0700, Junio C Hamano wrote:
>>
>>> diff --git a/Documentation/CodingGuidelines b/Documentation/CodingGuidelines
>>> index 9598b45f7e..cbe0377699 100644
>>> --- a/Documentation/CodingGuidelines
>>> +++ b/Documentation/CodingGuidelines
>>> @@ -242,6 +242,10 @@ For C programs:
>>>       printf("%"PRIuMAX, (uintmax_t)v).  These days the MSVC version we
>>>       rely on supports %z, but the C library used by MinGW does not.
>>>  
>>> +   . Shorthand like ".a.b = *c" in struct assignments is known to trip
>>> +     up an older IBM XLC version, use ".a = { .b = *c }" instead. See
>>> +     the 33665d98e6b portability fix from mid-2022.
>>
>> FWIW, the use of the word "assignment" here left me scratching my head.
>> Reading 33665d98e6b, it is about struct initialization.
>
> Thanks, I missed that confusion in the new description.  Perhaps
> another round of reroll would make the series polished enough?

I could re-roll it, but I also see you extensively fixed it up v.s. my
version. I think a re-roll here would just be
s/assignments/initializations/, so if you wanted to squash that in to
your already extensive squashes...

...or I could also re-roll it, up to you. Just let me know what you'd
prefer, thanks!

  parent reply	other threads:[~2022-10-11  8:32 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-07  9:30 [PATCH 0/5] CodingGuidelines: various C99 updates Ævar Arnfjörð Bjarmason
2022-10-07  9:30 ` [PATCH 1/5] CodingGuidelines: update for C99 Ævar Arnfjörð Bjarmason
2022-10-07 18:08   ` Junio C Hamano
2022-10-07  9:30 ` [PATCH 2/5] CodingGuidelines: mention dynamic C99 initializer elements Ævar Arnfjörð Bjarmason
2022-10-07  9:30 ` [PATCH 3/5] CodingGuidelines: allow declaring variables in for loops Ævar Arnfjörð Bjarmason
2022-10-07 18:12   ` Junio C Hamano
2022-10-07  9:30 ` [PATCH 4/5] CodingGuidelines: mention C99 features we can't use Ævar Arnfjörð Bjarmason
2022-10-07 18:13   ` Junio C Hamano
2022-10-07  9:30 ` [PATCH 5/5] CodingGuidelines: recommend against unportable C99 struct syntax Ævar Arnfjörð Bjarmason
2022-10-07 17:54 ` [PATCH 0/5] CodingGuidelines: various C99 updates Junio C Hamano
2022-10-07 18:15   ` Junio C Hamano
2022-10-10 20:37 ` [PATCH v2 0/5] CodingGUidelines: " Junio C Hamano
2022-10-10 20:37   ` [PATCH v2 1/5] CodingGuidelines: update for C99 Junio C Hamano
2022-10-10 20:37   ` [PATCH v2 2/5] CodingGuidelines: mention dynamic C99 initializer elements Junio C Hamano
2022-10-10 20:37   ` [PATCH v2 3/5] CodingGuidelines: allow declaring variables in for loops Junio C Hamano
2022-10-10 20:37   ` [PATCH v2 4/5] CodingGuidelines: mention C99 features we can't use Junio C Hamano
2022-10-10 20:38   ` [PATCH v2 5/5] CodingGuidelines: recommend against unportable C99 struct syntax Junio C Hamano
2022-10-11  0:09     ` Jeff King
2022-10-11  0:26       ` Junio C Hamano
2022-10-11  0:39         ` Jeff King
2022-10-11  8:30         ` Ævar Arnfjörð Bjarmason [this message]
2022-10-11 15:01           ` Junio C Hamano

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=221011.86bkqipxpv.gmgdl@evledraar.gmail.com \
    --to=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.