Reapply "[analyzer] Remove constraints on dead symbols as part of removeDeadBindings."
authorJordan Rose <jordan_rose@apple.com>
Tue, 25 Sep 2012 19:03:06 +0000 (19:03 +0000)
committerJordan Rose <jordan_rose@apple.com>
Tue, 25 Sep 2012 19:03:06 +0000 (19:03 +0000)
commitdb72e2fc3737465b26b92dddc3f6124c0fd8e929
treed64fc7779685f7f15c231f6a757293e9f3621dc0
parent60d704ab4a019dda8630f85a12f52ac826732e77
Reapply "[analyzer] Remove constraints on dead symbols as part of removeDeadBindings."

Previously, we'd just keep constraints around forever, which means we'd
never be able to merge paths that differed only in constraints on dead
symbols.

Because we now allow constraints on symbolic expressions, not just single
symbols, this requires changing SymExpr::symbol_iterator to include
intermediate symbol nodes in its traversal, not just the SymbolData leaf
nodes.

This depends on the previous commit to be correct. Originally applied in
r163444, reverted in r164275, now being re-applied.

llvm-svn: 164622
clang/lib/StaticAnalyzer/Core/ProgramState.cpp
clang/lib/StaticAnalyzer/Core/SymbolManager.cpp
clang/test/Analysis/traversal-path-unification.c [new file with mode: 0644]