equiv: mark variables as equiv even when their types are different
commit227f2c43c7bd139bd9684db4419e24477eb1a31b
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 17 Nov 2015 08:54:55 +0000 (17 11:54 +0300)
committerDan Carpenter <dan.carpenter@oracle.com>
Tue, 17 Nov 2015 08:54:55 +0000 (17 11:54 +0300)
tree0740f2d7e9f208ef7c2b17ce35831274184adb77
parent57a73b207be38774053e8cddf64b6fe3d01313c3
equiv: mark variables as equiv even when their types are different

The old rule was that for variables to be equivalent then their types had
to be the same.  Now the rule is that the value inside the variable has
to fit into both variables for it to be equiv.

So say you have:  "x = y;" where x is an unsigned int and y is a signed
int.  If y can be negative then they are not equiv but if y is 0-4 then
they are equiv.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
smatch_equiv.c
smatch_estate.c
smatch_extra.c
smatch_extra.h