diff for duplicates of <20100219200841.GF17130@bicker> diff --git a/a/1.txt b/N1/1.txt index 36a2783..95058e4 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -3,10 +3,10 @@ On Fri, Feb 19, 2010 at 06:24:10PM +0100, Clemens Ladisch wrote: > > On Fre, 2010-02-19 at 14:29 +0300, Dan Carpenter wrote: > > > On Fri, Feb 19, 2010 at 11:33:30AM +0100, Bernd Petrovitsch wrote: > > > Basically often when people write: -> > > if (!foo == bar) { ... +> > > if (!foo = bar) { ... > > > > > > What they mean is: -> > > if (!(foo == bar)) { ... +> > > if (!(foo = bar)) { ... > > But there are also cases where they mean what they've written. > @@ -19,13 +19,13 @@ On Fri, Feb 19, 2010 at 06:24:10PM +0100, Clemens Ladisch wrote: > > > > But if they really do mean the original code they could just write > > > this so it's clear to everyone: -> > > if ((!foo) == bar) { ... +> > > if ((!foo) = bar) { ... > > This is unnatural (especially in a simple example like this) because > the parens haven't been needed at all before smatch. > > -> !foo==bar is always identical to !(foo==bar) for boolean values; to +> !foo=bar is always identical to !(foo=bar) for boolean values; to > avoid false positives, you could output the warning only when the code > is trying to manipulate non-boolean values. IMO the message would be > justified if it said "using suspicious boolean operations on non-boolean diff --git a/a/content_digest b/N1/content_digest index 30f96b5..b906478 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -6,7 +6,7 @@ "ref\04B7EC93A.5010304@ladisch.de\0" "From\0Dan Carpenter <error27@gmail.com>\0" "Subject\0Re: [patch] oxygen: clean up. make precedence explicit\0" - "Date\0Fri, 19 Feb 2010 23:08:41 +0300\0" + "Date\0Fri, 19 Feb 2010 20:08:41 +0000\0" "To\0Clemens Ladisch <clemens@ladisch.de>\0" "Cc\0Bernd Petrovitsch <bernd@petrovitsch.priv.at>" alsa-devel@alsa-project.org @@ -18,10 +18,10 @@ "> > On Fre, 2010-02-19 at 14:29 +0300, Dan Carpenter wrote:\n" "> > > On Fri, Feb 19, 2010 at 11:33:30AM +0100, Bernd Petrovitsch wrote:\n" "> > > Basically often when people write:\n" - "> > > \tif (!foo == bar) { ...\n" + "> > > \tif (!foo = bar) { ...\n" "> > > \n" "> > > What they mean is:\n" - "> > > \tif (!(foo == bar)) { ...\n" + "> > > \tif (!(foo = bar)) { ...\n" "> \n" "> But there are also cases where they mean what they've written.\n" "> \n" @@ -34,13 +34,13 @@ "> \n" "> > > But if they really do mean the original code they could just write \n" "> > > this so it's clear to everyone: \n" - "> > > \tif ((!foo) == bar) { ...\n" + "> > > \tif ((!foo) = bar) { ...\n" "> \n" "> This is unnatural (especially in a simple example like this) because\n" "> the parens haven't been needed at all before smatch.\n" "> \n" "> \n" - "> !foo==bar is always identical to !(foo==bar) for boolean values; to\n" + "> !foo=bar is always identical to !(foo=bar) for boolean values; to\n" "> avoid false positives, you could output the warning only when the code\n" "> is trying to manipulate non-boolean values. IMO the message would be\n" "> justified if it said \"using suspicious boolean operations on non-boolean\n" @@ -58,4 +58,4 @@ "> Regards,\n" > Clemens -0e8d26045cded24b040bf52c1976634b026eee1c5ec65d043da73cf5605cb966 +e06f1834d1cce8e5ab0164bec1d6cdd31ea7f7614d4062694e927918ef8bab42
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.