diff options
author | Dylan Noblesmith <nobled@dreamwidth.org> | 2012-02-05 02:13:05 +0000 |
---|---|---|
committer | Dylan Noblesmith <nobled@dreamwidth.org> | 2012-02-05 02:13:05 +0000 |
commit | f7ccbad5d9949e7ddd1cbef43d482553b811e026 (patch) | |
tree | 1c2ab53fd417f5f54e55420b2807abacb972125b /lib/StaticAnalyzer/Core | |
parent | 6f42b62b6194f53bcbc349f5d17388e1936535d7 (diff) |
Basic: import SmallString<> into clang namespace
(I was going to fix the TODO about DenseMap too, but
that would break self-host right now. See PR11922.)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149799 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/StaticAnalyzer/Core')
-rw-r--r-- | lib/StaticAnalyzer/Core/BugReporter.cpp | 6 | ||||
-rw-r--r-- | lib/StaticAnalyzer/Core/BugReporterVisitors.cpp | 10 |
2 files changed, 8 insertions, 8 deletions
diff --git a/lib/StaticAnalyzer/Core/BugReporter.cpp b/lib/StaticAnalyzer/Core/BugReporter.cpp index 4eebdb7f8d..94368b5f4e 100644 --- a/lib/StaticAnalyzer/Core/BugReporter.cpp +++ b/lib/StaticAnalyzer/Core/BugReporter.cpp @@ -441,7 +441,7 @@ public: // Create the diagnostic. if (Loc::isLocType(VD->getType())) { - llvm::SmallString<64> buf; + SmallString<64> buf; llvm::raw_svector_ostream os(buf); os << '\'' << *VD << "' now aliases '" << *MostRecent << '\''; PathDiagnosticLocation L = @@ -1897,7 +1897,7 @@ void BugReporter::FlushReport(BugReportEquivClass& EQ) { StringRef desc = exampleReport->getShortDescription(); unsigned ErrorDiag; { - llvm::SmallString<512> TmpStr; + SmallString<512> TmpStr; llvm::raw_svector_ostream Out(TmpStr); for (StringRef::iterator I=desc.begin(), E=desc.end(); I!=E; ++I) if (*I == '%') @@ -1952,7 +1952,7 @@ void BugReporter::EmitBasicReport(StringRef name, BugType *BugReporter::getBugTypeForName(StringRef name, StringRef category) { - llvm::SmallString<136> fullDesc; + SmallString<136> fullDesc; llvm::raw_svector_ostream(fullDesc) << name << ":" << category; llvm::StringMapEntry<BugType *> & entry = StrBugTypes.GetOrCreateValue(fullDesc); diff --git a/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp b/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp index 4153d7820b..230e7c97eb 100644 --- a/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp +++ b/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp @@ -169,7 +169,7 @@ PathDiagnosticPiece *FindLastStoreBRVisitor::VisitNode(const ExplodedNode *N, return NULL; satisfied = true; - llvm::SmallString<256> sbuf; + SmallString<256> sbuf; llvm::raw_svector_ostream os(sbuf); if (const PostStmt *PS = N->getLocationAs<PostStmt>()) { @@ -599,7 +599,7 @@ ConditionBRVisitor::VisitTrueTest(const Expr *Cond, bool shouldInvert = false; - llvm::SmallString<128> LhsString, RhsString; + SmallString<128> LhsString, RhsString; { llvm::raw_svector_ostream OutLHS(LhsString), OutRHS(RhsString); const bool isVarLHS = patternMatch(BExpr->getLHS(), OutLHS, BRC); @@ -623,7 +623,7 @@ ConditionBRVisitor::VisitTrueTest(const Expr *Cond, return 0; // Should we invert the strings if the LHS is not a variable name? - llvm::SmallString<256> buf; + SmallString<256> buf; llvm::raw_svector_ostream Out(buf); Out << "Assuming " << (shouldInvert ? RhsString : LhsString) << " is "; @@ -673,7 +673,7 @@ ConditionBRVisitor::VisitConditionVariable(StringRef LhsString, const bool tookTrue, BugReporterContext &BRC, const LocationContext *LC) { - llvm::SmallString<256> buf; + SmallString<256> buf; llvm::raw_svector_ostream Out(buf); Out << "Assuming " << LhsString << " is "; @@ -705,7 +705,7 @@ ConditionBRVisitor::VisitTrueTest(const Expr *Cond, if (!VD) return 0; - llvm::SmallString<256> Buf; + SmallString<256> Buf; llvm::raw_svector_ostream Out(Buf); Out << "Assuming '"; |