From: a.hajda@samsung.com (Andrzej Hajda)
To: cocci@systeme.lip6.fr
Subject: [Cocci] [PATCH v6] coccinelle: tests: unsigned value cannot be lesser than zero
Date: Tue, 05 Jan 2016 15:29:27 +0100 [thread overview]
Message-ID: <568BD347.7010303@samsung.com> (raw)
In-Reply-To: <alpine.DEB.2.10.1601051512010.2521@hadrien>
On 01/05/2016 03:17 PM, Julia Lawall wrote:
>> + at script:python depends on org@
>> +p << r_cmp.p;
>> +e << r.e = "";
>> +@@
>> +
>> +msg = "WARNING: Unsigned expression compared with zero: %s" % (e)
>> +coccilib.org.print_todo(p[0], msg)
>> +
>> + at script:python depends on report@
>> +p << r_cmp.p;
>> +e << r.e = "";
>> +@@
>> +
>> +msg = "WARNING: Unsigned expression compared with zero: %s" % (e)
>> +if e:
>> + coccilib.report.print_report(p[0], msg)
> Is it intentional that these don't do the same thing? The report case has
> an if on e, while the org case does not. If you don't want a report when e
> doesn't have a value, you could just remove the = "" from the declaration of
> e. That is to give a default value of e, to allow the rule to be executed
> when e doesn't have a value.
>
> julia
>
>
No, I forgot to adjust it. I will fix it then, thanks.
Regards
Andrzej
WARNING: multiple messages have this Message-ID (diff)
From: Andrzej Hajda <a.hajda@samsung.com>
To: Julia Lawall <julia.lawall@lip6.fr>
Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>,
Marek Szyprowski <m.szyprowski@samsung.com>,
Gilles Muller <Gilles.Muller@lip6.fr>,
Nicolas Palix <nicolas.palix@imag.fr>,
Michal Marek <mmarek@suse.com>,
open list <linux-kernel@vger.kernel.org>,
"moderated list:COCCINELLE/Semantic Patches (SmPL)"
<cocci@systeme.lip6.fr>
Subject: Re: [PATCH v6] coccinelle: tests: unsigned value cannot be lesser than zero
Date: Tue, 05 Jan 2016 15:29:27 +0100 [thread overview]
Message-ID: <568BD347.7010303@samsung.com> (raw)
In-Reply-To: <alpine.DEB.2.10.1601051512010.2521@hadrien>
On 01/05/2016 03:17 PM, Julia Lawall wrote:
>> +@script:python depends on org@
>> +p << r_cmp.p;
>> +e << r.e = "";
>> +@@
>> +
>> +msg = "WARNING: Unsigned expression compared with zero: %s" % (e)
>> +coccilib.org.print_todo(p[0], msg)
>> +
>> +@script:python depends on report@
>> +p << r_cmp.p;
>> +e << r.e = "";
>> +@@
>> +
>> +msg = "WARNING: Unsigned expression compared with zero: %s" % (e)
>> +if e:
>> + coccilib.report.print_report(p[0], msg)
> Is it intentional that these don't do the same thing? The report case has
> an if on e, while the org case does not. If you don't want a report when e
> doesn't have a value, you could just remove the = "" from the declaration of
> e. That is to give a default value of e, to allow the rule to be executed
> when e doesn't have a value.
>
> julia
>
>
No, I forgot to adjust it. I will fix it then, thanks.
Regards
Andrzej
next prev parent reply other threads:[~2016-01-05 14:29 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-30 11:06 [Cocci] [PATCH v4] coccinelle: tests: unsigned value cannot be lesser than zero Andrzej Hajda
2015-12-30 11:06 ` Andrzej Hajda
2015-12-30 11:29 ` [Cocci] " Julia Lawall
2015-12-30 11:29 ` Julia Lawall
2015-12-30 12:33 ` [Cocci] " Andrzej Hajda
2015-12-30 12:33 ` Andrzej Hajda
2015-12-30 13:25 ` [Cocci] [PATCH v5] " Andrzej Hajda
2015-12-30 13:25 ` Andrzej Hajda
2015-12-30 14:06 ` [Cocci] " Julia Lawall
2015-12-30 14:06 ` Julia Lawall
2016-01-04 7:45 ` [Cocci] [PATCH v6] " Andrzej Hajda
2016-01-04 7:45 ` Andrzej Hajda
2016-01-05 12:59 ` [Cocci] " Geyslan G. Bem
2016-01-05 12:59 ` Geyslan G. Bem
2016-01-05 13:02 ` [Cocci] " Julia Lawall
2016-01-05 13:02 ` Julia Lawall
2016-01-05 14:10 ` [Cocci] " Geyslan G. Bem
2016-01-05 14:10 ` Geyslan G. Bem
2016-01-05 16:48 ` [Cocci] " Geyslan G. Bem
2016-01-05 16:48 ` Geyslan G. Bem
2016-01-05 13:49 ` [Cocci] " Andrzej Hajda
2016-01-05 13:49 ` Andrzej Hajda
2016-01-05 14:18 ` [Cocci] " Geyslan G. Bem
2016-01-05 14:18 ` Geyslan G. Bem
2016-01-05 14:17 ` [Cocci] " Julia Lawall
2016-01-05 14:17 ` Julia Lawall
2016-01-05 14:29 ` Andrzej Hajda [this message]
2016-01-05 14:29 ` Andrzej Hajda
2016-01-07 9:36 ` [Cocci] [PATCH v7] " Andrzej Hajda
2016-01-07 9:36 ` Andrzej Hajda
2016-01-07 11:35 ` [Cocci] " Julia Lawall
2016-01-07 11:35 ` Julia Lawall
2016-01-07 14:37 ` [Cocci] " Michal Marek
2016-01-07 14:37 ` Michal Marek
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=568BD347.7010303@samsung.com \
--to=a.hajda@samsung.com \
--cc=cocci@systeme.lip6.fr \
/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.