All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Tokarev <mjt@tls.msk.ru>
To: qemu-devel@nongnu.org
Cc: Laurent Vivier <lvivier@redhat.com>,
	qemu-trivial@nongnu.org, Michael Tokarev <mjt@tls.msk.ru>
Subject: [Qemu-devel] [PULL 19/27] coccinelle: add a script to remove useless casts
Date: Wed, 14 Sep 2016 10:58:45 +0300	[thread overview]
Message-ID: <cbb46cc5e6f662d3896fcea39a74f37a2bdff091.1473839869.git.mjt@msgid.tls.msk.ru> (raw)
In-Reply-To: <cover.1473839869.git.mjt@msgid.tls.msk.ru>
In-Reply-To: <cover.1473839869.git.mjt@msgid.tls.msk.ru>

From: Laurent Vivier <lvivier@redhat.com>

Script from LKML.

Signed-off-by: Laurent Vivier <lvivier@redhat.com>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
---
 scripts/coccinelle/typecast.cocci | 7 +++++++
 1 file changed, 7 insertions(+)
 create mode 100644 scripts/coccinelle/typecast.cocci

diff --git a/scripts/coccinelle/typecast.cocci b/scripts/coccinelle/typecast.cocci
new file mode 100644
index 0000000..be2183e
--- /dev/null
+++ b/scripts/coccinelle/typecast.cocci
@@ -0,0 +1,7 @@
+// Remove useless casts
+@@
+type T;
+T v;
+@@
+-	(T *)&v
++	&v
-- 
2.1.4

  parent reply	other threads:[~2016-09-14  8:34 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-14  7:58 [Qemu-devel] [PULL 00/27] Trivial patches for 2016-09-14 Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 01/27] Remove remainders of HPPA backend Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 02/27] tcg: Remove duplicate header includes Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 03/27] ui/console: Fix non-working backspace key in monitor of gtk UI Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 04/27] MAINTAINERS: Add include/hw/unicore32/ to UniCore32 section Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 05/27] MAINTAINERS: Add include/hw/tricore/ to TriCore section Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 06/27] MAINTAINERS: Add include/hw/sh4/ to SH4 section Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 07/27] MAINTAINERS: Add include/sysemu/cpus.h Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 08/27] MAINTAINERS: Fix wildcard for scsi headers Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 09/27] MAINTAINERS: Add some header files to the PC chipset section Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 10/27] MAINTAINERS: Fix up F: entry bit rot Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 11/27] sh4: fix broken link to documentation Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 12/27] help: Update help to remove misleading display information Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 13/27] ivshmem: Delete duplicate debug message Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 14/27] timer: update comments Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 15/27] cpus: rename local variable to meaningful one Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 16/27] cpus: update comments Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 17/27] Remove unused function declarations Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 18/27] curl: Operate on zero-length file Michael Tokarev
2016-09-14  7:58 ` Michael Tokarev [this message]
2016-09-14  7:58 ` [Qemu-devel] [PULL 20/27] linux-user,s390x: remove useless cast Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 21/27] s390x: " Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 22/27] tricore: " Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 23/27] fw_cfg: remove useless casts Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 24/27] sheepdog: " Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 25/27] win32: don't run subprocess tests on Mingw32 platform Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 26/27] linux-user/qemu.h: change malloc to g_malloc, free to g_free Michael Tokarev
2016-09-14  7:58 ` [Qemu-devel] [PULL 27/27] mptsas: change .realize function name Michael Tokarev
2016-09-14 10:49 ` [Qemu-devel] [PULL 00/27] Trivial patches for 2016-09-14 no-reply

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=cbb46cc5e6f662d3896fcea39a74f37a2bdff091.1473839869.git.mjt@msgid.tls.msk.ru \
    --to=mjt@tls.msk.ru \
    --cc=lvivier@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@nongnu.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 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.