Coccinelle release 1.0.0-rc4
[bpt/coccinelle.git] / tests / tyex.cocci
CommitLineData
951c7801
C
1@@
2@@
3
4typedef struct {
5 ...
6- char *name;
7 ...
8}
9- Location
10+ Point
11 ;
12+ typedef struct {
13+ char *name;
14+ Point p;
15+ } Location;
16
17@@
18typedef Location;
19Location some_location;
20identifier x;
21@@
22
23(
24 some_location.name
25|
26- some_location.x
27+ some_location.p.x
28)
29
30@@
31Location *some_location;
32identifier x;
33@@
34
35(
36 some_location->name
37|
38- some_location->x
39+ some_location->p.x
40)