permit multiline comments and strings in macros
[bpt/coccinelle.git] / demos / virt.cocci
1 // Illustrate the use of virtual rules
2 //
3 // Confidence: High
4 // Copyright: (C) Gilles Muller, Julia Lawall, INRIA, DIKU. GPLv2.
5 // Options: some permutation of -D/U p1 -D/U p2
6
7 virtual p1, p2
8
9 @script:python depends on p1@
10 @@
11
12 print "p1"
13
14 @script:python depends on p2@
15 @@
16
17 print "p2"
18
19 @script:python depends on p1 && !p2@
20 @@
21
22 print "only p1"
23
24 @script:python depends on p2 && !p1@
25 @@
26
27 print "only p2"