git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Jeff King <peff@peff.net>
Cc: Alexander Kuleshov <kuleshovmail@gmail.com>,
	"git\@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: [PATCH] init-db: remove unused #includes
Date: Thu, 15 Jan 2015 15:40:04 -0800	[thread overview]
Message-ID: <xmqqlhl34nqj.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <20150115223112.GB19021@peff.net> (Jeff King's message of "Thu, 15 Jan 2015 17:31:12 -0500")

Jeff King <peff@peff.net> writes:

> On Thu, Jan 15, 2015 at 12:36:00PM -0800, Junio C Hamano wrote:
>
>> Jeff King <peff@peff.net> writes:
>> 
>> > FWIW, the full set of CFLAGS I use (which I specify in config.mak) is:
>> >
>> >     CFLAGS += -Wall -Werror
>> >     CFLAGS += -Wno-format-zero-length
>> >     CFLAGS += -Wdeclaration-after-statement
>> >     CFLAGS += -Wpointer-arith
>> >     CFLAGS += -Wstrict-prototypes
>> >     CFLAGS += -Wold-style-declaration
>> 
>> I think I have no-pointer-to-int-cast, old-style-definition and vla
>> in addition to the above.
>
> Thanks, I added the latter two to my setup. But what is the purpose of
> turning off pointer-to-int warnings? It seems like those are a good
> indication of a sloppy construct (and AFAICT, we do not have any code
> which triggers on it).

It probably a remnant from olden days; perhaps we used to have a
code that stuffs a pointer value to an int field used as a hash key
or something.  As you said, there is no need for disabling that
check in today's code.

Thanks for catching.

      reply	other threads:[~2015-01-15 23:40 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-14 17:59 [PATCH] init-db: remove unused #includes Alexander Kuleshov
2015-01-14 19:09 ` Junio C Hamano
2015-01-14 20:14   ` Junio C Hamano
2015-01-15 10:13     ` Alexander Kuleshov
2015-01-15 10:55       ` Jeff King
2015-01-15 20:36         ` Junio C Hamano
2015-01-15 22:31           ` Jeff King
2015-01-15 23:40             ` Junio C Hamano [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=xmqqlhl34nqj.fsf@gitster.dls.corp.google.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=kuleshovmail@gmail.com \
    --cc=peff@peff.net \
    /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).