Hi list, what I want to do is simply:

@@
expression E;
@@
-spin_lock(E);
+prefix_spin_lock(E);

But I need to add a same prefix to more than 10 functions, so I'd
prefer to do something like:

@@
expression E;
identifier func ~= "^\(foo\|bar\|blah\)$";
@@
-func(E);
+prefix_$(func)(E);

So as not to duplicate the same patch for each such function, but I
couldn't figure out how to do it. Any suggestions?

Thanks,
Isaac
_______________________________________________
Cocci mailing list
[email protected]
http://lists.diku.dk/mailman/listinfo/cocci
(Web access from inside DIKUs LAN only)

Reply via email to