On 29.10.2014 12:25, Jean-Sébastien Pédron wrote:
>> Sorry, typo here. It should be func@p(...) { ... }
>
> You're right, it's working now! Thank you :)
Here's the complete working semantic patch:
---8<---
@r@
identifier func;
@@
#define func BAR(func)
@s1@
identifier r.func;
position p;
@@
func@p(...) {...}
@@
identifier func;
position p != s1.p;
@@
+#define func BAR(func)
func@p(...) { ... }
@s2@
type ret;
identifier r.func;
position p;
@@
ret func@p(...);
@@
type ret;
identifier func;
position p != s2.p;
@@
+#define func BAR(func)
ret func@p(...);
---8<---
Thank you very much for your help!
--
Jean-Sébastien Pédron
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Cocci mailing list [email protected] https://systeme.lip6.fr/mailman/listinfo/cocci
