OSDN Git Service

Fix the new print functions to call print instead of dump.
authorDan Gohman <gohman@apple.com>
Fri, 7 May 2010 16:17:22 +0000 (16:17 +0000)
committerDan Gohman <gohman@apple.com>
Fri, 7 May 2010 16:17:22 +0000 (16:17 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@103261 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Analysis/DebugInfo.cpp

index e423354..aa562cf 100644 (file)
@@ -501,7 +501,7 @@ void DIType::print(raw_ostream &OS) const {
   OS << " [" << dwarf::TagString(Tag) << "] ";
 
   // TODO : Print context
-  getCompileUnit().dump();
+  getCompileUnit().print(OS);
   OS << " ["
          << getLineNumber() << ", "
          << getSizeInBits() << ", "
@@ -518,11 +518,11 @@ void DIType::print(raw_ostream &OS) const {
     OS << " [fwd] ";
 
   if (isBasicType())
-    DIBasicType(DbgNode).dump();
+    DIBasicType(DbgNode).print(OS);
   else if (isDerivedType())
-    DIDerivedType(DbgNode).dump();
+    DIDerivedType(DbgNode).print(OS);
   else if (isCompositeType())
-    DICompositeType(DbgNode).dump();
+    DICompositeType(DbgNode).print(OS);
   else {
     OS << "Invalid DIType\n";
     return;
@@ -538,7 +538,7 @@ void DIBasicType::print(raw_ostream &OS) const {
 
 /// print - Print derived type.
 void DIDerivedType::print(raw_ostream &OS) const {
-  OS << "\n\t Derived From: "; getTypeDerivedFrom().dump();
+  OS << "\n\t Derived From: "; getTypeDerivedFrom().print(OS);
 }
 
 /// print - Print composite type.
@@ -557,7 +557,7 @@ void DIGlobal::print(raw_ostream &OS) const {
   OS << " [" << dwarf::TagString(Tag) << "] ";
 
   // TODO : Print context
-  getCompileUnit().dump();
+  getCompileUnit().print(OS);
   OS << " [" << getLineNumber() << "] ";
 
   if (isLocalToUnit())
@@ -567,7 +567,7 @@ void DIGlobal::print(raw_ostream &OS) const {
     OS << " [def] ";
 
   if (isGlobalVariable())
-    DIGlobalVariable(DbgNode).dump();
+    DIGlobalVariable(DbgNode).print(OS);
 
   OS << "\n";
 }
@@ -582,7 +582,7 @@ void DISubprogram::print(raw_ostream &OS) const {
   OS << " [" << dwarf::TagString(Tag) << "] ";
 
   // TODO : Print context
-  getCompileUnit().dump();
+  getCompileUnit().print(OS);
   OS << " [" << getLineNumber() << "] ";
 
   if (isLocalToUnit())
@@ -597,7 +597,7 @@ void DISubprogram::print(raw_ostream &OS) const {
 /// print - Print global variable.
 void DIGlobalVariable::print(raw_ostream &OS) const {
   OS << " [";
-  getGlobal()->dump();
+  getGlobal()->print(OS);
   OS << "] ";
 }
 
@@ -607,9 +607,9 @@ void DIVariable::print(raw_ostream &OS) const {
   if (!Res.empty())
     OS << " [" << Res << "] ";
 
-  getCompileUnit().dump();
+  getCompileUnit().print(OS);
   OS << " [" << getLineNumber() << "] ";
-  getType().dump();
+  getType().print(OS);
   OS << "\n";
 
   // FIXME: Dump complex addresses