Re: [PATCH 0/11] annotating unused function parameters

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 8/20/2022 5:46 AM, Jeff King wrote:
> On Fri, Aug 19, 2022 at 10:58:08PM +0200, Ævar Arnfjörð Bjarmason wrote:
> 
>> Yes, I spoke too soon, sorry. We still need ((unused)). FWIW the below
>> on top of master and doing:
> 
> Right. Using ((deprecated)) is really just a substitute for the variable
> renaming part.
> 
> And I agree it works as advertised, though I think I prefer the
> variable-renaming version.
> 
> One, it feels like we're abusing the deprecated attribute here. The
> confusion in the compiler output I'm OK with, because we get a chance to
> put our own message there (so I agree the output is actually better than
> with my patch). But from time to time I've had to build with
> -Wno-deprecated-declarations to get around _actual_ deprecated warnings
> (e.g., compiling with OPENSSL_SHA1=Yes). And doing so would be cutting
> out half the protection of UNUSED() in that case.

The fact that we can't turn on -Wno-deprecated-declarations is enough
to convince me that we need to use the variable renaming trick.

Thanks,
-Stolee




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux