blob: 48b25a776f2e788a1128b3547acfe454304b8bb3 (
plain)
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
|
static long foo(long a, long b, long c)
{
return a? b:c;
}
static long foo_bool(_Bool a, long b, long c)
{
return a? b:c;
}
static long bar(long a, long b, long c)
{
if (a)
return b;
else
return b + c;
}
static long bar_bool(_Bool a, long b, long c)
{
if (a)
return b;
else
return b + c;
}
/*
* check-name: Non-bool condition values in branch/select
* check-command: ./sparsec -c $file -o tmp.o
*/
|