math: remove the get_implied_value_low_overhead() function
[smatch.git] / validation / sm_mtag4.c
blobddf72292fc394dba3c97a0e4314dc467eb41f6fd
1 #include <stdio.h>
2 #include "check_debug.h"
4 struct foo {
5 int a, b, c;
6 int (*func)(int *p);
7 void (*func2)(int a);
8 void *data;
9 };
11 static void frob_int1(int val)
13 __smatch_implied(val);
16 static void frob_int2(int val)
18 __smatch_implied(val);
21 static struct foo one_struct = {
22 .b = 41,
23 .func2 = frob_int1,
26 static struct foo two_struct = {
27 .b = 42,
28 .func2 = frob_int2,
31 struct foo *unknown(void);
32 struct foo *p;
34 int main(void)
36 int ret;
38 p = unknown();
39 p->func2(p->b);
41 return 0;
45 * check-name: smatch mtag #4
46 * check-command: validation/smatch_db_test.sh -I.. sm_mtag4.c
48 * check-output-start
49 sm_mtag4.c:13 frob_int1() implied: val = '41'
50 sm_mtag4.c:18 frob_int2() implied: val = '42'
51 * check-output-end