public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: jacopo <jacopo@jmondi.org>
To: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Cc: Arushi Singhal <arushisinghal19971997@gmail.com>,
	outreachy-kernel@googlegroups.com,
	Jonathan Cameron <jic23@kernel.org>,
	Hartmut Knaack <knaack.h@gmx.de>,
	Lars-Peter Clausen <lars@metafoo.de>,
	Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
	linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] iio: adc: replace comma with a semicolon
Date: Thu, 30 Mar 2017 20:06:18 +0200	[thread overview]
Message-ID: <20170330180618.GD7900@w540> (raw)
In-Reply-To: <20170330172312.ooxwqmkz6sw7smgd@piout.net>

Hi Alexandre
   hope you're doing good!

On Thu, Mar 30, 2017 at 07:23:12PM +0200, Alexandre Belloni wrote:
> On 30/03/2017 at 15:30:46 +0200, jacopo wrote:
> > Hi Arushi,
> >    thanks for your patch
> > 
> > On Thu, Mar 30, 2017 at 06:16:03PM +0530, Arushi Singhal wrote:
> > > Replace a comma between expression statements by a semicolon. This
> > > changes the semantics of the code, but given the current indentation
> > > appears to be what is intended.
> > > A simplified version of the Coccinelle semantic patch that performs this
> > > transformation is as follows:
> > > 
> > > // <smpl>
> > > @r@
> > > expression e1,e2;
> > > @@
> > > 
> > >  e1
> > > -,
> > > +;
> > >  e2;
> > > // </smpl>
> > > 
> > 
> > You can simply say that this fixes what appears to be a bug to me.
> > I wonder how this does even compile..
> > 
> 
> It is not a bug, it is perfectly valid and working as expected/intended.
> This is just a cosmetic change.
> 
> See https://en.wikipedia.org/wiki/Comma_operator if you want to
> understand.
> 

Thanks! That's valid and legal (I should have thought at multiple
expression in for(;;) as an example).
Ignore my comment then (I still don't think it was "intended" as it's
quite unusual to see commas there :)

Thanks
   j

> 
> -- 
> Alexandre Belloni, Free Electrons
> Embedded Linux and Kernel engineering
> http://free-electrons.com

  reply	other threads:[~2017-03-30 18:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-30 12:46 [PATCH] iio: adc: replace comma with a semicolon Arushi Singhal
2017-03-30 13:30 ` jacopo
2017-03-30 13:38   ` Peter Meerwald-Stadler
2017-04-01 10:00     ` Jonathan Cameron
2017-03-30 17:23   ` Alexandre Belloni
2017-03-30 18:06     ` jacopo [this message]
2017-03-30 18:22 ` [Outreachy kernel] " Alison Schofield

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=20170330180618.GD7900@w540 \
    --to=jacopo@jmondi.org \
    --cc=alexandre.belloni@free-electrons.com \
    --cc=arushisinghal19971997@gmail.com \
    --cc=jic23@kernel.org \
    --cc=knaack.h@gmx.de \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=outreachy-kernel@googlegroups.com \
    --cc=pmeerw@pmeerw.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox