aboutsummaryrefslogtreecommitdiffstats
path: root/progs/tests/expression/boolean_ops_count.sy
blob: b4a43e92556f156ec440ea2c2b0268cf0fb00e88 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
start :: fn {
    ts := 0
    t :: fn -> bool {
        ts += 1
        ret true
    }

    fs := 0
    f :: fn -> bool {
        fs += 1
        ret false
    }

    i :: fn -> bool {
        <!>
        ret false
    }

    if f() && i() {
        <!>
    }

    if t() || i() {
        // This block is intentionally left blank
    } else {
        <!>
    }

    if f() && i() && i() {
        <!>
    }

    if t() || i() || i() {
        // This block is intentionally left blank
    } else {
        <!>
    }

    fs <=> 2
    ts <=> 2
}