diff options
author | Ted Kremenek <kremenek@apple.com> | 2009-03-06 23:58:11 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2009-03-06 23:58:11 +0000 |
commit | 1fbfd5b9b8b82aea084773b76dd1ec6796a7000c (patch) | |
tree | cd8e2f983c8ab1d321aa5f8b996d13e070f0f8ff /lib/Analysis/PathDiagnostic.cpp | |
parent | 177f708abadfca856b83f1c540c66667d167a4e8 (diff) |
Create PathDiagnosticPiece subclasses PathDiagnosticEventPiece and
PathDiagnosticControlFlowPiece to distinguish (in the class hierarchy) between
events and control-flow diagnostic pieces. Clients must now use these directly
when constructing PathDiagnosticPieces.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66310 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/PathDiagnostic.cpp')
-rw-r--r-- | lib/Analysis/PathDiagnostic.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Analysis/PathDiagnostic.cpp b/lib/Analysis/PathDiagnostic.cpp index 49af34dc1c..ae53ed9dbf 100644 --- a/lib/Analysis/PathDiagnostic.cpp +++ b/lib/Analysis/PathDiagnostic.cpp @@ -50,6 +50,8 @@ PathDiagnosticPiece::PathDiagnosticPiece(FullSourceLoc pos, } PathDiagnosticPiece::~PathDiagnosticPiece() {} +PathDiagnosticEventPiece::~PathDiagnosticEventPiece() {} +PathDiagnosticControlFlowPiece::~PathDiagnosticControlFlowPiece() {} PathDiagnosticMacroPiece::~PathDiagnosticMacroPiece() { for (iterator I = begin(), E = end(); I != E; ++I) delete *I; @@ -99,7 +101,7 @@ void PathDiagnosticClient::HandleDiagnostic(Diagnostic::Level DiagLevel, Info.FormatDiagnostic(StrC); PathDiagnosticPiece *P = - new PathDiagnosticPiece(Info.getLocation(), + new PathDiagnosticEventPiece(Info.getLocation(), std::string(StrC.begin(), StrC.end())); for (unsigned i = 0, e = Info.getNumRanges(); i != e; ++i) |