Added string "[CHECKER]" to the output diagnostics produced by the GRSimpleVals analysis.

llvm-svn: 47678
This commit is contained in:
Ted Kremenek 2008-02-27 17:56:16 +00:00
parent 3df31ba41b
commit fd8352c2b9
1 changed files with 5 additions and 0 deletions

View File

@ -16,6 +16,7 @@
#include "GRSimpleVals.h"
#include "clang/Analysis/PathSensitive/ValueState.h"
#include "clang/Basic/Diagnostic.h"
#include <sstream>
using namespace clang;
@ -25,6 +26,10 @@ template <typename ITERATOR>
static void EmitWarning(Diagnostic& Diag, SourceManager& SrcMgr,
ITERATOR I, ITERATOR E, const char* msg) {
std::ostringstream Out;
Out << "[CHECKER] " << msg;
msg = Out.str().c_str();
bool isFirst;
unsigned ErrorDiag;