Re: [PATCH] compat/posix.h: enable UNUSED warning messages for Clang
- From
- Dominik Loidolt <dominik.loidolt@univie.ac.at>
- Date
- Jun 5, 2026, 08:44 UTC
- Message-ID
- <aiKMeHXOCulPAaXq@four.local>
- In-Reply-To
- <xmqqqznsossj.fsf@gitster.g>
On Mon, May 04, 2026 at 10:41:16AM +0900, Junio C Hamano wrote:
Show 8 quoted lines
> > Does this "drop support" because you force _all_ versions of Clang > > to use the "deprecated" attribute, even though you _know_ some older > > versions do not understand it? Don't these versions identify > > themselves so that you can do > > > > #if defined(__clang__) && CLANG_VERSION >= 2.9 > > IOW, something like this, perhaps?
Yes, you're right. My original patch breaks older Clang versions for no good reason.
I'll send a v2 with an explicit Clang version check, as you suggested.
Thanks, Dominik