permit multiline comments and strings in macros
[bpt/coccinelle.git] / tests / gcc_min_max.cocci
CommitLineData
1b9ae606
C
1// Deprecated min/max http://gcc.gnu.org/onlinedocs/gcc-4.0.1/gcc/Deprecated-Features.html
2// Only works if "algorithm" is allready included
3// This spatch is on hold until coccinelle is extended to support >?,<?,>?=,<?=
4@@
5expression x,y;
6@@
7- x <?= y;
8+ x = min(x,y);
9@@
10expression x,y;
11@@
12- x <? y
13+ min(x,y)
14@@
15expression x,y;
16@@
17- x >?= y;
18+ x = max(x,y);
19@@
20expression x,y;
21@@
22- x >? y
23+ max(x,y)