v2 / vlib / v / gen / c / testdata / use_flag_comptime_with_if.out
44 lines · 41 sloc · 1.46 KB · 78b77b9f14b44c7d4917c4ce0f336fde5fac513b
Raw
1>>>>> Should be compiled with: `./v -d ddd1=true -d ddd2=false`
2>>>>> Note that ddd3 is not passed *on purpose*, to test the default .
3===========================================================================
4$d(ddd1, false) : true
5$d(ddd1, true) : true
6------------------------------------------------------------
7Checking $if with default false:
81 ddd1 is true
9Checking $if with default true:
102 ddd1 is true
11------------------------------------------------------------
12Checking $if !$d(ddd1) with default false:
133 !ddd1 is false
14Checking $if !$d() with default true:
154 !ddd1 is false
16
17===========================================================================
18$d(ddd2, false) : false
19$d(ddd2, true) : false
20------------------------------------------------------------
21Checking $if with default false:
221 ddd2 is false
23Checking $if with default true:
242 ddd2 is false
25------------------------------------------------------------
26Checking $if !$d() with default false:
273 !ddd2 is true
28Checking $if !$d() with default true:
294 !ddd2 is true
30
31===========================================================================
32$d(ddd3, false) : false
33$d(ddd3, true) : true
34------------------------------------------------------------
35Checking $if with default false:
361 ddd3 is false
37Checking $if with default true:
382 ddd3 is true
39------------------------------------------------------------
40Checking $if !$d() with default false:
413 !ddd3 is true
42Checking $if !$d() with default true:
434 !ddd3 is false
44
45