function_hooks/unwind: introduce return_implies_exact()
[smatch.git] / validation / sm_range1.c
blob39a8f8e7b3b4d7920662e81c7945e134415ada4b
1 struct ture {
2 int x;
3 };
5 struct ture *p;
6 struct ture *q;
7 int xxx;
9 int func (void)
12 for (xxx = 0; xxx < 10; xxx++) {
13 if (p && q)
14 break;
16 // this needs two pass processing to work.
17 // if (xxx == 5)
18 // q->x = 1;
19 if (xxx == 10)
20 return;
21 p->x = 1;
23 return 0;
27 * check-name: Implied Ranges #1
28 * check-command: smatch sm_range1.c