Re: [PATCH] reftable: make REFTABLE_UNUSED C99 compatible
- From
Patrick Steinhardt <ps@pks.im>
- Date
- May 30, 2025, 08:47 UTC
- Message-ID
- <aDlwsM_18nYB2MOr@pks.im>
- In-Reply-To
- <20250530062533.GA1321283@coredump.intra.peff.net>
On Fri, May 30, 2025 at 02:25:33AM -0400, Jeff King wrote:
Show 8 quoted lines
> On Fri, May 30, 2025 at 07:35:49AM +0200, Patrick Steinhardt wrote: > > > What I don't understand though: we have a `MAYBE_UNUSED` macro that has > > the exact same definition in "git-compat-util.h". Why does the macro > > cause issues in the reftable library, but not over there? > > We turn __attribute__() into a noop for some platforms earlier in > git-compat-util.h. So it doesn't need a separate #ifdef.
Ah, that's something I missed when introducing `REFTABLE_UNUSED`. With that added context the patch looks sensible to me. Thanks!
Patrick