Re: [PATCH] config.mak.dev: enable -Wpedantic in clang

2018-11-28 Thread Junio C Hamano
Eric Sunshine writes: > Playing Devi's Advocate, what if Apple's clang "8" was, in reality, > real-world clang 3? Then this condition would incorrectly enable the > compiler option on Apple for a (real) clang version below 4. For this > reason, it seems we shouldn't be trusting only the clang ver

Re: [PATCH] config.mak.dev: enable -Wpedantic in clang

2018-11-27 Thread Eric Sunshine
On Tue, Nov 27, 2018 at 10:48 AM Carlo Arenas wrote: > On Tue, Nov 27, 2018 at 2:53 AM Eric Sunshine wrote: > > On Tue, Nov 27, 2018 at 5:06 AM Carlo Marcelo Arenas Belón > > > +ifneq ($(filter clang10,$(COMPILER_FEATURES)),) > > > +CFLAGS += -Wpedantic > > > +endif > > > > Should this condition

Re: [PATCH] config.mak.dev: enable -Wpedantic in clang

2018-11-27 Thread Carlo Arenas
On Tue, Nov 27, 2018 at 2:53 AM Eric Sunshine wrote: > On Tue, Nov 27, 2018 at 5:06 AM Carlo Marcelo Arenas Belón > > +ifneq ($(filter clang10,$(COMPILER_FEATURES)),) > > +CFLAGS += -Wpedantic > > +endif > > Should this condition be tightened to match only for OSX since there > is no such clang ve

Re: [PATCH] config.mak.dev: enable -Wpedantic in clang

2018-11-27 Thread Eric Sunshine
On Tue, Nov 27, 2018 at 5:06 AM Carlo Marcelo Arenas Belón wrote: > [...] > -Wpedantic is only enabled for clang 10 or higher (only available in macOS > with latest Xcode) but this restriction should be relaxed further as more > environments are tested We know from [1] that the clang version numb

[PATCH] config.mak.dev: enable -Wpedantic in clang

2018-11-27 Thread Carlo Marcelo Arenas Belón
DEVOPTS=pedantic adds -pedantic to the compiler flags, but misses on some diagnostics when using clang, and that are only enabled with -Wpedantic 46c0eb5843 ("files-backend.c: fix build error on Solaris", 2018-11-25) fixes an issue that was visible also with gcc but not clang so correct that with