summaryrefslogtreecommitdiffstats
path: root/clang/lib/Analysis/SymbolManager.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/Analysis/SymbolManager.cpp')
-rw-r--r--clang/lib/Analysis/SymbolManager.cpp20
1 files changed, 17 insertions, 3 deletions
diff --git a/clang/lib/Analysis/SymbolManager.cpp b/clang/lib/Analysis/SymbolManager.cpp
index f1c1cc0a466..45e1aae23bc 100644
--- a/clang/lib/Analysis/SymbolManager.cpp
+++ b/clang/lib/Analysis/SymbolManager.cpp
@@ -18,8 +18,23 @@
using namespace clang;
-void SymbolRef::print(llvm::raw_ostream& os) const {
- os << getNumber();
+llvm::raw_ostream& llvm::operator<<(llvm::raw_ostream& os,
+ clang::SymbolRef sym) {
+ if (sym.isValid())
+ os << sym.getNumber();
+ else
+ os << "(Invalid)";
+
+ return os;
+}
+
+std::ostream& std::operator<<(std::ostream& os, clang::SymbolRef sym) {
+ if (sym.isValid())
+ os << sym.getNumber();
+ else
+ os << "(Invalid)";
+
+ return os;
}
SymbolRef SymbolManager::getRegionRValueSymbol(const MemRegion* R) {
@@ -35,7 +50,6 @@ SymbolRef SymbolManager::getRegionRValueSymbol(const MemRegion* R) {
DataSet.InsertNode(SD, InsertPos);
DataMap[SymbolCounter] = SD;
return SymbolCounter++;
-
}
SymbolRef SymbolManager::getConjuredSymbol(Stmt* E, QualType T, unsigned Count){
OpenPOWER on IntegriCloud