On Thu, 26 Jul 2018, Timur Tabi wrote:
> Also, while I have you attention, is this correct?
>
> @rule1@
> expression x;
> expression list y;
> @@
> -DBG_PRINTF(x, y);
> +NV_PRINTF(y);
>
> @depends on rule1@
> @@
> -DBG_LEVEL_ERRORS
> +LEVEL_ERROR
>
> This appears to work, but I think the "depends on" is just saying that
> if rule1 succeeds, then go ahead and replace all DBG_LEVEL_ERRORS with
> LEVEL_ERROR. However, I really only want that to happen inside an
> NV_PRINTF. I tried doing this:
>
> @depends on rule1@
> @@
> NV_PRINTF(
> -DBG_LEVEL_ERRORS
> +LEVEL_ERROR
> );
>
> That that doesn't do anything.
I don't know what the NV_PRINTF call looks like. You can say
NV_PRINTF(...,
- DBG_LEVEL_ERRORS,
+ LEVEL_ERROR,
...);
If DBG_LEVEL_ERRORS can come at an unknown argument position.
julia
> _______________________________________________
> Cocci mailing list
> [email protected]
> https://systeme.lip6.fr/mailman/listinfo/cocci
>
_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci