From: Harvey Harrison <harvey.harrison@gmail.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Christopher Li <sparse@chrisli.org>, Julia Lawall <julia@diku.dk>,
yi.zhu@intel.com, linux-wireless@vger.kernel.org,
ipw3945-devel@lists.sourceforge.net,
linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org,
Alexander Viro <viro@ftp.linux.org.uk>,
linux-sparse@vger.kernel.org,
Josh Triplett <josh@freedesktop.org>
Subject: Re: [PATCH 6/9] drivers/net/wireless/iwlwifi/iwl-4965.c: Correct use of ! and &
Date: Tue, 04 Mar 2008 23:09:55 -0800 [thread overview]
Message-ID: <1204700995.17484.7.camel@brick> (raw)
In-Reply-To: <20080305070201.GA32434@elte.hu>
On Wed, 2008-03-05 at 08:02 +0100, Ingo Molnar wrote:
> * Christopher Li <sparse@chrisli.org> wrote:
>
> > I think Al Viro has sent a patch to linux-sparse with subject "[PATCH
> > 3/3] catch !x & y brainos" does exactly that.
>
> ah - nice :-)
>
> /me checks the linux-sparse archive
>
> Al's patch is:
>
> + if (op == '&' && expr->left->type == EXPR_PREOP &&
> + expr->left->op == '!')
> + warning(expr->pos, "dubious: !x & y");
>
> i think there might be similar patterns: "x & !y", "!x | y", "x | !y" ?
>
Well, (!x & y) and (!x | y) are probably the two that might have been
intended otherwise. (x & !y), (x | !y) are probably ok.
Harvey
next prev parent reply other threads:[~2008-03-05 7:10 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-26 20:44 [PATCH 6/9] drivers/net/wireless/iwlwifi/iwl-4965.c: Correct use of ! and & Julia Lawall
2008-02-26 22:47 ` Tomas Winkler
2008-02-27 0:59 ` John W. Linville
2008-03-05 6:38 ` Ingo Molnar
2008-03-05 6:49 ` Christopher Li
2008-03-05 7:02 ` Ingo Molnar
2008-03-05 7:09 ` Harvey Harrison [this message]
2008-03-05 8:19 ` Ingo Molnar
2008-03-05 12:13 ` Derek M Jones
2008-03-05 8:55 ` Julia Lawall
2008-03-05 12:20 ` Ingo Molnar
2008-03-05 12:30 ` Bart Van Assche
2008-03-05 12:36 ` Ingo Molnar
2008-03-05 12:35 ` Julia Lawall
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=1204700995.17484.7.camel@brick \
--to=harvey.harrison@gmail.com \
--cc=ipw3945-devel@lists.sourceforge.net \
--cc=josh@freedesktop.org \
--cc=julia@diku.dk \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sparse@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=sparse@chrisli.org \
--cc=viro@ftp.linux.org.uk \
--cc=yi.zhu@intel.com \
/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).