Re: [PATCH 0/3] add: use advise_if_enabled

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

 



On Fri, Mar 29, 2024 at 10:28:34AM -0700, Junio C Hamano wrote:
> Rubén Justo <rjusto@xxxxxxxxx> writes:
> 
> > This series is a simple change, in builtin/add.c, from:
> >
> > 	if (advice_enabled(XXX))
> > 		advise(MMM)
> 
> I wonder if a coccinelle rule can automatically identify and rewrite
> these ...
> 
> >
> > to the newer:
> >
> > 	advise_if_enabled(XXX, MMM)
> 
> ... to this form automatically.

I don't have a solid opinion on that but, after a cursory review, I have
doubts a simple rule could catch enough cases to make it worth the
effort.

And, let's hope that the new code will utilize the new API for its
convenience.




[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