Add "category" to BugTypes, allowing bugs to be grouped.
Changed casing of many bug names. The convention will be to have bug names (mostly) lower cased, and categories use some capitalization.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56385 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/CheckDeadStores.cpp b/lib/Analysis/CheckDeadStores.cpp
index 73cb3f7..d87bfb1 100644
--- a/lib/Analysis/CheckDeadStores.cpp
+++ b/lib/Analysis/CheckDeadStores.cpp
@@ -59,19 +59,19 @@
case DeadIncrement:
BugType = "dead increment";
case Standard:
- if (!BugType) BugType = "dead store";
+ if (!BugType) BugType = "dead assignment";
msg = "Value stored to '" + name + "' is never read";
break;
case Enclosing:
- BugType = "dead store";
+ BugType = "dead nested assignment";
msg = "Although the value stored to '" + name +
"' is used in the enclosing expression, the value is never actually"
" read from '" + name + "'";
break;
}
- BR.EmitBasicReport(BugType, msg.c_str(), L, R);
+ BR.EmitBasicReport(BugType, "Dead Store", msg.c_str(), L, R);
}
void CheckVarDecl(VarDecl* VD, Expr* Ex, Expr* Val,