DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Morten Brørup" <mb@smartsharesystems.com>
To: "Stephen Hemminger" <stephen@networkplumber.org>
Cc: <dev@dpdk.org>
Subject: RE: [PATCH v2 0/6] Enable warnings about use of comma operator
Date: Fri, 15 Aug 2025 08:40:58 +0200	[thread overview]
Message-ID: <98CBD80474FA8B44BF855DF32C47DC35E9FE37@smartserver.smartshare.dk> (raw)
In-Reply-To: <20250814212901.88863-1-stephen@networkplumber.org>

> From: Stephen Hemminger [mailto:stephen@networkplumber.org]
> Sent: Thursday, 14 August 2025 23.29
> 
> This series was motivated by recent thread on netdev
> about build with -Wcomma in clang. This warning catches code
> that uses comma where a semi-colon is a better choice.

Overall, I agree that using semicolon is better for consistency is most places, but using commas in some loops - e.g. "for (dst=,src=; condition; dst+=, src+=)" - might be more readable than the alternative.

Stephen, I'm interested in the discussion about this, can you please post a link to the thread on the netdev mailing list?


      parent reply	other threads:[~2025-08-15  6:41 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-12 23:26 [RFC 0/7] avoid unnecessary use of comma op Stephen Hemminger
2025-03-12 23:26 ` [RFC 1/7] eal: replace unnecessary comma operator Stephen Hemminger
2025-03-12 23:26 ` [RFC 2/7] ipsec: " Stephen Hemminger
2025-03-12 23:27 ` [RFC 3/7] graph: " Stephen Hemminger
2025-03-12 23:27 ` [RFC 4/7] net/mlx4: replace unnecessary comma operators Stephen Hemminger
2025-03-12 23:27 ` [RFC 5/7] net/mlx5: " Stephen Hemminger
2025-03-12 23:27 ` [RFC 6/7] test: " Stephen Hemminger
2025-03-12 23:27 ` [RFC 7/7] app/testpmd: replace comma operator with bracket Stephen Hemminger
2025-08-14 21:28 ` [PATCH v2 0/6] Enable warnings about use of comma operator Stephen Hemminger
2025-08-14 21:28   ` [PATCH v2 1/6] eal: replace unnecessary " Stephen Hemminger
2025-08-14 21:28   ` [PATCH v2 2/6] ipsec: " Stephen Hemminger
2025-08-14 21:28   ` [PATCH v2 3/6] graph: " Stephen Hemminger
2025-08-14 21:28   ` [PATCH v2 4/6] test: replace unnecessary comma operators Stephen Hemminger
2025-08-14 21:28   ` [PATCH v2 5/6] app/testpmd: replace comma operator with bracket Stephen Hemminger
2025-08-14 21:28   ` [PATCH v2 6/6] config: enable comma warnings Stephen Hemminger
2025-08-15  0:30   ` [PATCH v2 0/6] Enable warnings about use of comma operator fengchengwen
2025-08-15  6:40   ` Morten Brørup [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=98CBD80474FA8B44BF855DF32C47DC35E9FE37@smartserver.smartshare.dk \
    --to=mb@smartsharesystems.com \
    --cc=dev@dpdk.org \
    --cc=stephen@networkplumber.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).