This could conceivably cut down on state proliferation, although we don't
use BasicConstraintManager by default anymore. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156362
91177308-0d34-0410-b5e6-
96231b3b80d8
ProgramStateRef BasicConstraintManager::AddEQ(ProgramStateRef state,
SymbolRef sym,
const llvm::APSInt& V) {
- // Create a new state with the old binding replaced.
+ // Now that we have an actual value, we can throw out the NE-set.
+ // Create a new state with the old bindings replaced.
+ state = state->remove<ConstNotEq>(sym);
return state->set<ConstEq>(sym, &getBasicVals().getValue(V));
}