Release coccinelle-0.1
[bpt/coccinelle.git] / tests / three_types.cocci
1 @ non_delayed_fn disable all @
2 type local_type;
3 local_type *device;
4 identifier fld, fn;
5 @@
6
7 INIT_WORK(&device->fld,
8 - fn, device
9 + fn
10 );
11
12 @ rule7a disable all @
13 identifier dataq, non_delayed_fn.fn, non_delayed_fn.fld;
14 type non_delayed_fn.local_type;
15 @@
16
17 fn (
18 - void *dataq
19 + struct work_struct *workq
20 ) {
21 <...
22 - dataq
23 + container_of(workq,local_type,fld)
24 ...>
25 }