implied: handle &undefined better
commit603bfed3bfd3f5057860b4b805431600c739850f
authorDan Carpenter <error27@gmail.com>
Tue, 17 Mar 2009 08:03:25 +0000 (17 11:03 +0300)
committerDan Carpenter <error27@gmail.com>
Tue, 17 Mar 2009 08:03:25 +0000 (17 11:03 +0300)
treed2fd685fbb1d4af264e16e3503f0f23cbc05299b
parent860e1068328490a518e054e59c84e0dfc034ff8e
implied:  handle &undefined better

foo = NULL;
x = 0;
if (bar) {
    foo = frob();
    x = 1;
}
Setting foo = frob() makes it &undefined but we still know that when foo is
non zero x == 1.

Also set things in smatch_extra to be &undefined earlier.  This is not a
complete solution because it doesn't deal with globals or members of
structures passed as arguments.  The way to deal with that is to set those
paths retroactively to &undefined in merge_slist().

Signed-off-by: Dan Carpenter <error27@gmail.com>
smatch_extra.c
smatch_implied.c