All of lore.kernel.org
 help / color / mirror / Atom feed
From: Giuseppe Scrivano <gscrivano@gnu.org>
To: Nicolas Pitre <nico@fluxnic.net>
Cc: Jeff King <peff@peff.net>,
	git@vger.kernel.org,
	Johannes Schindelin <Johannes.Schindelin@gmx.de>,
	Sverre Rabbelier <srabbelier@gmail.com>
Subject: Re: [PATCH] Remove various dead assignments and dead increments found by the clang static analyzer
Date: Sun, 27 Sep 2009 10:21:17 +0200	[thread overview]
Message-ID: <874oqokdc2.fsf@master.homenet> (raw)
In-Reply-To: <alpine.LFD.2.00.0909262038470.4997@xanadu.home> (Nicolas Pitre's message of "Sat, 26 Sep 2009 20:41:35 -0400 (EDT)")

Nicolas Pitre <nico@fluxnic.net> writes:

> And the compiler (at least gcc) is indeed smart enough to realize that 
> nothing uses the result from the last statement, and does optimize away 
> the code associated to it already.  So this patch is unlikely to change 
> anything to the compiled result.

Right, and gcc can do many other amazing things.  But still it is used a
variable that is never accessed, removing it can make the code slightly
more readable.

Cheers,
Giuseppe

      reply	other threads:[~2009-09-27  8:24 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-26 14:46 [PATCH] Remove various dead assignments and dead increments found by the clang static analyzer Giuseppe Scrivano
2009-09-26 15:58 ` Johannes Schindelin
2009-09-26 18:21   ` Giuseppe Scrivano
2009-09-26 18:34     ` Sverre Rabbelier
2009-09-26 18:46       ` Giuseppe Scrivano
2009-09-26 19:15       ` Giuseppe Scrivano
2009-09-26 19:28         ` René Scharfe
2009-09-26 20:39         ` Johannes Schindelin
2009-09-26 20:46         ` Jeff King
2009-09-26 21:03           ` Reece Dunn
2009-09-26 21:12             ` Jeff King
2009-09-26 21:20               ` Reece Dunn
2009-09-26 21:36                 ` Jeff King
2009-09-26 21:46                   ` Reece Dunn
2009-09-26 21:42                 ` Giuseppe Scrivano
2009-09-27  0:41           ` Nicolas Pitre
2009-09-27  8:21             ` Giuseppe Scrivano [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=874oqokdc2.fsf@master.homenet \
    --to=gscrivano@gnu.org \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=nico@fluxnic.net \
    --cc=peff@peff.net \
    --cc=srabbelier@gmail.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 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.