From: René Scharfe Date: Tue, 31 Mar 2026 22:15:32 GMT Subject: Re: [PATCH 1/6] reftable/system: provide `REFTABLE_INLINE()` macro Message-ID: In-Reply-To: On 3/31/26 11:23 PM, Junio C Hamano wrote: > René Scharfe writes: > >> On 3/31/26 1:26 PM, Patrick Steinhardt wrote: >>> Not every compiler knows about the `inline` annotation for functions. >>> Consequently, Git knows to define `inline` as an empty macro in case >>> it's not available. >> >> Does it? Only in compat/regex/regex_internal.h, which does not leak >> to other code, no? > > As we also do > > ifneq (,$(INLINE)) > BASIC_CFLAGS += -Dinline=$(INLINE) > endif > > in the Makefile so we cannot tell what people do with their > config.mak ;-). Ah, missed that. So setting INLINE to an empty string does nothing. We do that for an ancient versions of HP-UX in config.mak.uname. When I set it to '', like we do in config.mak.uname for an ancient version of AIX, I get lots of warnings about unused functions and linking errors due to duplicate symbols. I can only hope that the pre-C99 compilers targeted by this measure can better deal with that issue somehow. > And obviously other projects do not share our Makefile, so it is not > too much of stretch to say Git "knows to define", even though it may > be more precise to say "knows to let users redefine", perhaps? Fair enough. René