Hello

Is something like the following possible.

Original code :

...
// some comment
foo(x,y);

.....

foo(x,y)

The code should be transformed after applying a patch
such that only the occurrence of foo(...) with the comment
above it should be transformed, i.e

The code after the transformation should look like

...
// some comment
bar(x,y,z)
...

foo(x,y)

The second call to foo(..) should remain untouched.

If possible, how should a patch be specified to handle this case.

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

Reply via email to