Prototyped support in the BugReporter to emit diagnostics of the form "p now aliases q".

llvm-svn: 51453
This commit is contained in:
Ted Kremenek
2008-05-22 23:45:19 +00:00
parent 8830714bff
commit b91ef1b62b
2 changed files with 171 additions and 2 deletions

View File

@@ -2017,6 +2017,10 @@ GetAllocationSite(ExplodedNode<ValueState>* N, SymbolID Sym) {
PathDiagnosticPiece* CFRefReport::getEndPath(BugReporter& BR,
ExplodedNode<ValueState>* EndN) {
// Tell the BugReporter to report cases when the tracked symbol is
// assigned to different variables, etc.
BR.addNotableSymbol(Sym);
if (!getBugType().isLeak())
return RangedBugReport::getEndPath(BR, EndN);