Fix 'or'ing states.
commita130602586c5517324238d99bd8174ac54326623
authorDan Carpenter <error27@gmail.com>
Tue, 3 Mar 2009 14:38:04 +0000 (3 17:38 +0300)
committerDan Carpenter <error27@gmail.com>
Tue, 3 Mar 2009 14:38:04 +0000 (3 17:38 +0300)
tree37e0376578e360281dd0f8e79ac911580738427c
parent2d1af6396199ab378ec6959300d0ee8a4ba557b9
Fix 'or'ing states.

With the implied states we set more states than the scripts by themselves
would.  For example:
frob() ; <- x is merged of assume_nonnull and nonnull.
if (foo || bar) {
foo implies x is nonnull.
if foo is null then x is assume_nonnull.
bar has no implications one way or the other.

When it comes to Oring the states the old method was to say that x was
undefined merged with nonnull which is undefined.

The new method takes into consideration that before the condition x was
either nonnull or assume_nonnull and we don't get an error.

Signed-off-by: Dan Carpenter <error27@gmail.com>
smatch_slist.c
smatch_slist.h
smatch_states.c