From: Josh Triplett <josh@freedesktop.org>
To: Al Viro <viro@ftp.linux.org.uk>
Cc: linux-sparse@vger.kernel.org
Subject: Re: [PATCH] fix the comma handling in integer constant expressions
Date: Sun, 08 Jul 2007 18:50:35 -0700 [thread overview]
Message-ID: <4691946B.8030709@freedesktop.org> (raw)
In-Reply-To: <20070701074848.GA1101@ftp.linux.org.uk>
[-- Attachment #1: Type: text/plain, Size: 1235 bytes --]
Al Viro wrote:
> [my apologies to the folks on Cc, original mails got the list address
> buggered in To:, thus the resend of the entire series just to the list]
>
> On Wed, Jun 27, 2007 at 04:54:25PM +0100, Al Viro wrote:
>> ... or it could be done simpler, if we keep the current logics for
>> Int_const_expr flag at parse time and add a 'const expression' one
>> with rules as above. Anyway, I'm going to get some sleep before
>> dealing with that crap.
>
> From: Al Viro <viro@zeniv.linux.org.uk>
> Date: Sun, 1 Jul 2007 02:28:10 -0400
> Subject: [PATCH] fix the comma handling in integer constant expressions
>
> Treat it as normal binary operation, taint the value, check the taint.
> We can do other kind of value tainting with the same infrastructure
> as well...
>
> Review and testing would be welcome; AFAICS, it works, but...
Seems to work for me. Applied.
I did notice one thing:
$ ./sparse /dev/stdin <<<"int x; struct { unsigned int i:x; };"
/dev/stdin:1:32: error: bad constant expression
/dev/stdin:1:33: error: invalid named zero-width bitfield `i'
That seems like double-warning for the same error. Probably a pain to
suppress the second error, though.
- Josh Triplett
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 252 bytes --]
prev parent reply other threads:[~2007-07-09 1:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-01 7:48 [PATCH] fix the comma handling in integer constant expressions Al Viro
2007-07-09 1:50 ` Josh Triplett [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=4691946B.8030709@freedesktop.org \
--to=josh@freedesktop.org \
--cc=linux-sparse@vger.kernel.org \
--cc=viro@ftp.linux.org.uk \
/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).