Right!

Spatch is smart enough to recognize that "struct smth" is a type definition.

Thank you, works even better than I've expected now :)

18.12.18 18:18, Julia Lawall пишет:

You give information about metavariables in betwen the first two @@.  Not
down in the code matching part.

Here you want struct my_struct a; in the metavariable list, and then the
same pattern as before after the second @@.

You can also do

@@
{new_address,struct my_struct} a;
@@

a.
- len
+ length

julia

--
- Max Suraev <[email protected]>       http://www.sysmocom.de/
=======================================================================
* sysmocom - systems for mobile communications GmbH
* Alt-Moabit 93
* 10559 Berlin, Germany
* Sitz / Registered office: Berlin, HRB 134158 B
* Geschaeftsfuehrer / Managing Directors: Harald Welte

_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to