git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "brian m. carlson" <sandals@crustytoothpaste.net>
To: "Carlo Marcelo Arenas Belón" <carenas@gmail.com>
Cc: "Han-Wen Nienhuys" <hanwen@google.com>,
	"Torsten Bögershausen" <tboegi@web.de>, git <git@vger.kernel.org>
Subject: Re: Compilation errors in git.pu/refs/reftable-backend.c
Date: Mon, 27 Apr 2020 23:26:29 +0000	[thread overview]
Message-ID: <20200427232629.GI6421@camp.crustytoothpaste.net> (raw)
In-Reply-To: <20200427131312.GB61348@Carlos-MBP>

[-- Attachment #1: Type: text/plain, Size: 1081 bytes --]

On 2020-04-27 at 13:13:12, Carlo Marcelo Arenas Belón wrote:
> On Mon, Apr 27, 2020 at 02:05:12PM +0200, Han-Wen Nienhuys wrote:
> > 
> > I don't understand why Git doesn't enforce this, though.  Couldn't
> > -Wdeclaration-after-statement be added to the Makefile if the compiler
> > supported it?
> 
> not sure if that flag will catch it, but from what I recall, that
> specific feature was only available in C99 while git's codebase
> targets C89 (need to build with --std=gnu89 as some GNU extensions
> are already needed).

I think we had chosen to preserve this behavior because MSVC didn't
support C99.  We may wish to change our approach now that MSVC supports
a reasonable subset of it and GCC and Clang are available for almost
every system out there.

I don't think it's unreasonable to expect folks to use a compiler
supporting a standard that is now more than two decades old.

Of course, that doesn't affect the present series, but it is a thing we
should consider.
-- 
brian m. carlson: Houston, Texas, US
OpenPGP: https://keybase.io/bk2204

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 263 bytes --]

      reply	other threads:[~2020-04-27 23:26 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-27  4:34 Compilation errors in git.pu/refs/reftable-backend.c Torsten Bögershausen
2020-04-27 12:05 ` Han-Wen Nienhuys
2020-04-27 12:13   ` Jeff King
2020-04-27 13:13   ` Carlo Marcelo Arenas Belón
2020-04-27 23:26     ` brian m. carlson [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=20200427232629.GI6421@camp.crustytoothpaste.net \
    --to=sandals@crustytoothpaste.net \
    --cc=carenas@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=hanwen@google.com \
    --cc=tboegi@web.de \
    /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).