On Fri, 12 May 2017, Arend van Spriel wrote:
> I have the following rule in my cocci script. Actually, want to apply the
> patch conditionally, ie. when type S matches one or more structure
> definitions. Initially I had 'struct Foo *drvr, ...' but that did not work for
> me. Any hints are appreciated.
>
> Regards,
> Arend
>
> @@
> identifier func;
> identifier drvr;
> type T;
> expression list es;
> type S;
> @@
> T func(S *drvr, ...)
struct i *drvr, where i is an identifier metavariable? I'm not sure what
you mean by one or more. Do you want to match more than the first
argument?
julia
> {
> <...
> - brcmf_err(es);
> + brcmf_derr(drvr, es);
> ...>
> }
> _______________________________________________
> Cocci mailing list
> [email protected]
> https://systeme.lip6.fr/mailman/listinfo/cocci
>
_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci