From: Joe Perches <joe@perches.com>
To: Julia Lawall <julia.lawall@lip6.fr>
Cc: Himangi Saraogi <himangi774@gmail.com>,
Stefan Achatz <erazor_de@users.sourceforge.net>,
Jiri Kosina <jkosina@suse.cz>,
linux-input@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] HID: roccat: Drop cast
Date: Thu, 26 Jun 2014 22:52:46 -0700 [thread overview]
Message-ID: <1403848366.7977.92.camel@joe-AO725> (raw)
In-Reply-To: <alpine.DEB.2.02.1406270729110.2016@localhost6.localdomain6>
On Fri, 2014-06-27 at 07:29 +0200, Julia Lawall wrote:
> On Thu, 26 Jun 2014, Joe Perches wrote:
> > The cast of a const void * to a void * was odd.
> >
> > Maybe a mechanism to verify appropriateness of
> > loss of constness for any pointer might be useful.
>
> I tried the following, but didn't find anything interesting:
>
> @disable drop_cast@
> type T;
> const T e;
> @@
>
> * (T)e
What code does this match?
Do you have an example match?
This doesn't find a cast of a void type like:
void func(const void * const p)
{
char *p2 = p;
p2[0] = 1;
}
next prev parent reply other threads:[~2014-06-27 5:52 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-26 17:28 [PATCH] HID: roccat: Drop cast Himangi Saraogi
2014-06-26 17:38 ` Joe Perches
2014-06-27 5:29 ` Julia Lawall
2014-06-27 5:52 ` Joe Perches [this message]
2014-06-27 7:59 ` Julia Lawall
2014-06-29 16:34 ` Julia Lawall
2014-06-29 18:25 ` Joe Perches
2014-06-30 9:08 ` Geert Uytterhoeven
2014-06-26 22:35 ` Jiri Kosina
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=1403848366.7977.92.camel@joe-AO725 \
--to=joe@perches.com \
--cc=erazor_de@users.sourceforge.net \
--cc=himangi774@gmail.com \
--cc=jkosina@suse.cz \
--cc=julia.lawall@lip6.fr \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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